Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 185121 Details for
Bug 127852
[UX][Help] Help button should be a toggle
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Fix
patch.txt (text/plain), 3.32 KB, created by
Markus Keller
on 2010-12-14 06:11:56 EST
(
hide
)
Description:
Fix
Filename:
MIME Type:
Creator:
Markus Keller
Created:
2010-12-14 06:11:56 EST
Size:
3.32 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jface >Index: src/org/eclipse/jface/dialogs/TrayDialog.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jface/src/org/eclipse/jface/dialogs/TrayDialog.java,v >retrieving revision 1.11 >diff -u -r1.11 TrayDialog.java >--- src/org/eclipse/jface/dialogs/TrayDialog.java 11 Nov 2008 14:57:36 -0000 1.11 >+++ src/org/eclipse/jface/dialogs/TrayDialog.java 14 Dec 2010 11:03:00 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2005, 2008 IBM Corporation and others. >+ * Copyright (c) 2005, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -120,6 +120,8 @@ > > private ControlAdapter resizeListener; > >+ private ToolItem fHelpButton; >+ > /** > * Creates a tray dialog instance. Note that the window will have no visual > * representation (no widgets) until it is told to open. >@@ -163,6 +165,9 @@ > sash = null; > Rectangle bounds = shell.getBounds(); > shell.setBounds(bounds.x + ((getDefaultOrientation() == SWT.RIGHT_TO_LEFT) ? trayWidth : 0), bounds.y, bounds.width - trayWidth, bounds.height); >+ if (fHelpButton != null) { >+ fHelpButton.setSelection(false); >+ } > } > > /* (non-Javadoc) >@@ -238,10 +243,10 @@ > cursor.dispose(); > } > }); >- ToolItem item = new ToolItem(toolBar, SWT.NONE); >- item.setImage(image); >- item.setToolTipText(JFaceResources.getString("helpToolTip")); //$NON-NLS-1$ >- item.addSelectionListener(new SelectionAdapter() { >+ fHelpButton = new ToolItem(toolBar, SWT.CHECK); >+ fHelpButton.setImage(image); >+ fHelpButton.setToolTipText(JFaceResources.getString("helpToolTip")); //$NON-NLS-1$ >+ fHelpButton.addSelectionListener(new SelectionAdapter() { > public void widgetSelected(SelectionEvent e) { > helpPressed(); > } >@@ -328,21 +333,26 @@ > * then invokes a help event on that widget. > */ > private void helpPressed() { >- if (getShell() != null) { >- Control c = getShell().getDisplay().getFocusControl(); >- while (c != null) { >- if (c.isListening(SWT.Help)) { >- c.notifyListeners(SWT.Help, new Event()); >- break; >- } >- c = c.getParent(); >- } >- } >+ if (getTray() == null) { >+ if (getShell() != null) { >+ Control c = getShell().getDisplay().getFocusControl(); >+ while (c != null) { >+ if (c.isListening(SWT.Help)) { >+ c.notifyListeners(SWT.Help, new Event()); >+ break; >+ } >+ c = c.getParent(); >+ } >+ } >+ >+ } else { >+ closeTray(); >+ } > } > > /** > * Constructs the tray's widgets and displays the tray in this dialog. The >- * dialog's size will be adjusted to accomodate the tray. >+ * dialog's size will be adjusted to accommodate the tray. > * > * @param tray the tray to show in this dialog > * @throws IllegalStateException if the dialog already has a tray open >@@ -392,6 +402,9 @@ > shell.addControlListener (resizeListener); > > this.tray = tray; >+ if (fHelpButton != null) { >+ fHelpButton.setSelection(true); >+ } > } > > /**
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 127852
:
185121
|
185330