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 193955 Details for
Bug 342771
Support "image+label" hint for when actions are presented in a toolbar
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]
Patch attempt #1
bug342771_patch_1.txt (text/plain), 21.41 KB, created by
Greg Amerson
on 2011-04-23 08:59:50 EDT
(
hide
)
Description:
Patch attempt #1
Filename:
MIME Type:
Creator:
Greg Amerson
Created:
2011-04-23 08:59:50 EDT
Size:
21.41 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.sapphire.samples >Index: META-INF/sapphire-extension.xml >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.samples/META-INF/sapphire-extension.xml,v >retrieving revision 1.2 >diff -u -r1.2 sapphire-extension.xml >--- META-INF/sapphire-extension.xml 4 Jan 2011 20:38:44 -0000 1.2 >+++ META-INF/sapphire-extension.xml 23 Apr 2011 12:45:28 -0000 >@@ -14,6 +14,24 @@ > --> > > <extension xmlns="http://www.eclipse.org/sapphire/xmlns/extension" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> >+ <action> >+ <id>Sapphire.Gallery.Open.Homepage</id> >+ <label>Sapphire Project</label> >+ <image>images/web.png</image> >+ <description>Open Sapphire project homepage</description> >+ <context>Sapphire.EditorPage</context> >+ <condition>org.eclipse.sapphire.samples.gallery.ui.OpenHomepageCondition</condition> >+ <hint> >+ <name>action.style</name> >+ <value>image+label</value> >+ </hint> >+ </action> >+ <action-handler> >+ <action>Sapphire.Gallery.Open.Homepage</action> >+ <id>Sapphire.Gallery.Open.Homepage</id> >+ <label>Sapphire Project</label> >+ <impl>org.eclipse.sapphire.samples.gallery.ui.OpenHomepageActionHandler</impl> >+ </action-handler> > <value-serialization-service> > <type>org.eclipse.sapphire.samples.gallery.Circle</type> > <impl>org.eclipse.sapphire.samples.gallery.internal.CircleSerializationService</impl> >Index: src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageActionHandler.java >=================================================================== >RCS file: src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageActionHandler.java >diff -N src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageActionHandler.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageActionHandler.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,39 @@ >+package org.eclipse.sapphire.samples.gallery.ui; >+ >+import java.net.URL; >+ >+import org.eclipse.sapphire.ui.SapphireActionHandler; >+import org.eclipse.sapphire.ui.SapphireRenderingContext; >+import org.eclipse.swt.widgets.Display; >+import org.eclipse.ui.PlatformUI; >+import org.eclipse.ui.browser.IWebBrowser; >+import org.eclipse.ui.browser.IWorkbenchBrowserSupport; >+ >+ >+public class OpenHomepageActionHandler extends SapphireActionHandler { >+ >+ @Override >+ protected Object run(SapphireRenderingContext context) { >+ >+ Display.getDefault().asyncExec(new Runnable() { >+ >+ public void run() { >+ try { >+ IWorkbenchBrowserSupport browserSupport = PlatformUI.getWorkbench().getBrowserSupport(); >+ >+ IWebBrowser browser = >+ browserSupport.createBrowser(IWorkbenchBrowserSupport.LOCATION_BAR | >+ IWorkbenchBrowserSupport.NAVIGATION_BAR, null, "Sapphire Project", null); >+ >+ browser.openURL(new URL("http://www.eclipse.org/sapphire/")); >+ } >+ catch (Exception e) { >+ // ignore >+ } >+ } >+ }); >+ >+ return null; >+ } >+ >+} >Index: src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageCondition.java >=================================================================== >RCS file: src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageCondition.java >diff -N src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageCondition.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/sapphire/samples/gallery/ui/OpenHomepageCondition.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,24 @@ >+package org.eclipse.sapphire.samples.gallery.ui; >+ >+import org.eclipse.sapphire.ui.ISapphirePart; >+import org.eclipse.sapphire.ui.SapphireCondition; >+ >+ >+public class OpenHomepageCondition extends SapphireCondition { >+ >+ @Override >+ protected boolean evaluate() { >+ ISapphirePart part = this.getPart(); >+ >+ while (part != null) { >+ if (part instanceof SapphireGallerySampleEditor) { >+ return true; >+ } >+ >+ part = part.getParentPart(); >+ } >+ >+ return false; >+ } >+ >+} >#P org.eclipse.sapphire.sdk >Index: sdef/SapphireEditorCommon.sdef >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.sdk/sdef/SapphireEditorCommon.sdef,v >retrieving revision 1.2 >diff -u -r1.2 SapphireEditorCommon.sdef >--- sdef/SapphireEditorCommon.sdef 16 Mar 2011 04:31:20 -0000 1.2 >+++ sdef/SapphireEditorCommon.sdef 23 Apr 2011 12:45:29 -0000 >@@ -45,6 +45,7 @@ > <property-editor>Label</property-editor> > <property-editor>KeyBinding</property-editor> > <property-editor>Type</property-editor> >+ <property-editor>Hints</property-editor> > <property-editor>Images</property-editor> > <property-editor> > <property>Description</property> >#P org.eclipse.sapphire.ui >Index: src/org/eclipse/sapphire/ui/SapphireAction.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/SapphireAction.java,v >retrieving revision 1.4 >diff -u -r1.4 SapphireAction.java >--- src/org/eclipse/sapphire/ui/SapphireAction.java 20 Apr 2011 05:40:24 -0000 1.4 >+++ src/org/eclipse/sapphire/ui/SapphireAction.java 23 Apr 2011 12:45:30 -0000 >@@ -13,7 +13,9 @@ > > import java.util.ArrayList; > import java.util.Collections; >+import java.util.HashMap; > import java.util.List; >+import java.util.Map; > import java.util.concurrent.CopyOnWriteArrayList; > > import org.eclipse.sapphire.modeling.el.Function; >@@ -21,6 +23,7 @@ > import org.eclipse.sapphire.modeling.el.FunctionResult; > import org.eclipse.sapphire.modeling.el.Literal; > import org.eclipse.sapphire.ui.def.ISapphireActionDef; >+import org.eclipse.sapphire.ui.def.ISapphireHint; > import org.eclipse.sapphire.ui.def.SapphireActionType; > import org.eclipse.sapphire.ui.def.SapphireKeySequence; > import org.eclipse.sapphire.ui.internal.SapphireUiFrameworkPlugin; >@@ -48,6 +51,7 @@ > private final List<SapphireActionHandler> handlers = new CopyOnWriteArrayList<SapphireActionHandler>(); > private final List<SapphireActionHandlerFilter> filters = new CopyOnWriteArrayList<SapphireActionHandlerFilter>(); > private final Listener handlerListener; >+ private Map<String,Object> hints; > > public SapphireAction() > { >@@ -103,6 +107,21 @@ > } > > setEnabled( false ); >+ >+ this.hints = new HashMap<String,Object>(); >+ >+ for( ISapphireHint hint : def.getHints() ) >+ { >+ final String name = hint.getName().getText(); >+ Object parsedValue = null; >+ >+ if( name.equals( ISapphireActionDef.HINT_ACTION_STYLE ) ) >+ { >+ parsedValue = hint.getValue().getText(); >+ } >+ >+ this.hints.put( name, parsedValue ); >+ } > } > > @Override >@@ -196,6 +215,15 @@ > return this.parent.getContext(); > } > >+ @SuppressWarnings( "unchecked" ) >+ >+ public <T> T getRenderingHint( final String name, >+ final T defaultValue ) >+ { >+ final Object hintValue = this.hints == null ? null : this.hints.get( name ); >+ return hintValue == null ? defaultValue : (T) hintValue; >+ } >+ > public SapphireActionType getType() > { > synchronized( this ) >Index: src/org/eclipse/sapphire/ui/SapphireSection.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/SapphireSection.java,v >retrieving revision 1.15 >diff -u -r1.15 SapphireSection.java >--- src/org/eclipse/sapphire/ui/SapphireSection.java 21 Apr 2011 19:26:33 -0000 1.15 >+++ src/org/eclipse/sapphire/ui/SapphireSection.java 23 Apr 2011 12:45:30 -0000 >@@ -108,7 +108,7 @@ > final SapphireActionPresentationManager actionPresentationManager = new SapphireActionPresentationManager( context, actions ); > final SapphireToolBarActionPresentation toolBarActionsPresentation = new SapphireToolBarActionPresentation( actionPresentationManager ); > >- final ToolBar toolbar = new ToolBar( this.section, SWT.FLAT | SWT.HORIZONTAL ); >+ final ToolBar toolbar = new ToolBar( this.section, SWT.FLAT | SWT.HORIZONTAL | SWT.RIGHT ); > toolBarActionsPresentation.setToolBar( toolbar ); > toolBarActionsPresentation.render(); > this.section.setTextClient( toolbar ); >Index: src/org/eclipse/sapphire/ui/def/ISapphireActionDef.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/def/ISapphireActionDef.java,v >retrieving revision 1.4 >diff -u -r1.4 ISapphireActionDef.java >--- src/org/eclipse/sapphire/ui/def/ISapphireActionDef.java 11 Mar 2011 17:47:28 -0000 1.4 >+++ src/org/eclipse/sapphire/ui/def/ISapphireActionDef.java 23 Apr 2011 12:45:30 -0000 >@@ -13,6 +13,7 @@ > > import org.eclipse.core.runtime.IStatus; > import org.eclipse.sapphire.modeling.ListProperty; >+import org.eclipse.sapphire.modeling.ModelElementList; > import org.eclipse.sapphire.modeling.ModelElementType; > import org.eclipse.sapphire.modeling.Value; > import org.eclipse.sapphire.modeling.ValueProperty; >@@ -25,6 +26,7 @@ > import org.eclipse.sapphire.modeling.annotations.Type; > import org.eclipse.sapphire.modeling.serialization.ValueSerialization; > import org.eclipse.sapphire.modeling.xml.annotations.XmlBinding; >+import org.eclipse.sapphire.modeling.xml.annotations.XmlListBinding; > import org.eclipse.sapphire.ui.def.internal.KeySequenceValueSerializationService; > > /** >@@ -41,6 +43,11 @@ > { > ModelElementType TYPE = new ModelElementType( ISapphireActionDef.class ); > >+ String HINT_ACTION_STYLE = "action.style"; >+ String HINT_VALUE_ACTION_STYLE_IMAGE = "image"; >+ String HINT_VALUE_ACTION_STYLE_IMAGE_LABEL = "image+label"; >+ String HINT_VALUE_ACTION_STYLE_LABEL_ONLY = "label-only"; >+ > // *** Id *** > > @NonNullValue >@@ -166,6 +173,15 @@ > Value<String> getGroup(); > void setGroup( String value ); > >+ // *** Hints *** >+ >+ @Label(standard = "hints") >+ @Type(base = ISapphireHint.class) >+ @XmlListBinding(mappings = @XmlListBinding.Mapping(element = "hint", type = ISapphireHint.class)) >+ ListProperty PROP_HINTS = new ListProperty(TYPE, "Hints"); >+ >+ ModelElementList<ISapphireHint> getHints(); >+ > // *** LocationHints *** > > @Documentation( content = "Location hints are used to arrange actions in relation to each other. " + >Index: src/org/eclipse/sapphire/ui/def/ISapphireHint.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/def/ISapphireHint.java,v >retrieving revision 1.5 >diff -u -r1.5 ISapphireHint.java >--- src/org/eclipse/sapphire/ui/def/ISapphireHint.java 7 Apr 2011 06:53:04 -0000 1.5 >+++ src/org/eclipse/sapphire/ui/def/ISapphireHint.java 23 Apr 2011 12:45:30 -0000 >@@ -72,7 +72,8 @@ > "show.label", > "show.label.above", > "suppress.assist.contributors", >- ISapphirePartDef.HINT_WIDTH >+ ISapphirePartDef.HINT_WIDTH, >+ ISapphireActionDef.HINT_ACTION_STYLE, > }, > invalidValueMessage = "\"{0}\" is not a valid hint.", > invalidValueSeverity = IStatus.OK >Index: src/org/eclipse/sapphire/ui/def/internal/SapphireHintValuePossibleValuesService.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/def/internal/SapphireHintValuePossibleValuesService.java,v >retrieving revision 1.2 >diff -u -r1.2 SapphireHintValuePossibleValuesService.java >--- src/org/eclipse/sapphire/ui/def/internal/SapphireHintValuePossibleValuesService.java 11 Apr 2011 17:28:36 -0000 1.2 >+++ src/org/eclipse/sapphire/ui/def/internal/SapphireHintValuePossibleValuesService.java 23 Apr 2011 12:45:30 -0000 >@@ -15,6 +15,7 @@ > > import org.eclipse.core.runtime.IStatus; > import org.eclipse.sapphire.modeling.PossibleValuesService; >+import org.eclipse.sapphire.ui.def.ISapphireActionDef; > import org.eclipse.sapphire.ui.def.ISapphireHint; > import org.eclipse.sapphire.ui.def.ISapphirePropertyEditorDef; > >@@ -40,6 +41,12 @@ > values.add( ISapphirePropertyEditorDef.HINT_VALUE_CHECKBOX_LAYOUT_TRAILING_LABEL ); > values.add( ISapphirePropertyEditorDef.HINT_VALUE_CHECKBOX_LAYOUT_TRAILING_LABEL_INDENTED ); > } >+ else if ( hint.equals( ISapphireActionDef.HINT_ACTION_STYLE ) ) >+ { >+ values.add( ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE ); >+ values.add( ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE_LABEL ); >+ values.add( ISapphireActionDef.HINT_VALUE_ACTION_STYLE_LABEL_ONLY ); >+ } > } > } > >Index: src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarActionPresentation.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarActionPresentation.java,v >retrieving revision 1.4 >diff -u -r1.4 SapphireToolBarActionPresentation.java >--- src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarActionPresentation.java 29 Mar 2011 02:49:46 -0000 1.4 >+++ src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarActionPresentation.java 23 Apr 2011 12:45:30 -0000 >@@ -22,6 +22,7 @@ > import org.eclipse.sapphire.ui.SapphireActionGroup; > import org.eclipse.sapphire.ui.SapphireActionHandler; > import org.eclipse.sapphire.ui.SapphireRenderingContext; >+import org.eclipse.sapphire.ui.def.ISapphireActionDef; > import org.eclipse.sapphire.ui.def.SapphireActionType; > import org.eclipse.swt.SWT; > import org.eclipse.swt.accessibility.AccessibleAdapter; >@@ -129,8 +130,21 @@ > { > throw new IllegalStateException(); > } >- >- toolItem.setImage( context.getImageCache().getImage( action.getImage( 16 ) ) ); >+ >+ String hint = action.getRenderingHint(ISapphireActionDef.HINT_ACTION_STYLE, ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE); >+ >+ if (ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE.equals(hint) || >+ ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE_LABEL.equals(hint)) >+ { >+ toolItem.setImage( context.getImageCache().getImage( action.getImage( 16 ) ) ); >+ } >+ >+ if (ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE_LABEL.equals(hint) || >+ ISapphireActionDef.HINT_VALUE_ACTION_STYLE_LABEL_ONLY.equals(hint)) >+ { >+ toolItem.setText( LabelTransformer.transform( action.getLabel(), CapitalizationType.TITLE_STYLE, true ) ); >+ } >+ > toolItem.setToolTipText( LabelTransformer.transform( action.getLabel(), CapitalizationType.TITLE_STYLE, false ) ); > toolItem.setData( action ); > toolItem.addSelectionListener( toolItemListener ); >Index: src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarManagerActionPresentation.java >=================================================================== >RCS file: /cvsroot/technology/org.eclipse.sapphire/plugins/org.eclipse.sapphire.ui/src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarManagerActionPresentation.java,v >retrieving revision 1.4 >diff -u -r1.4 SapphireToolBarManagerActionPresentation.java >--- src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarManagerActionPresentation.java 29 Mar 2011 02:49:46 -0000 1.4 >+++ src/org/eclipse/sapphire/ui/swt/renderer/SapphireToolBarManagerActionPresentation.java 23 Apr 2011 12:45:30 -0000 >@@ -13,11 +13,15 @@ > > import static org.eclipse.sapphire.modeling.util.MiscUtil.equal; > >+import java.util.ArrayList; > import java.util.List; > > import org.eclipse.jface.action.ActionContributionItem; >+import org.eclipse.jface.action.ContributionItem; >+import org.eclipse.jface.action.ControlContribution; > import org.eclipse.jface.action.IAction; > import org.eclipse.jface.action.IContributionItem; >+import org.eclipse.jface.action.IContributionManager; > import org.eclipse.jface.action.IToolBarManager; > import org.eclipse.jface.action.Separator; > import org.eclipse.jface.action.SubContributionItem; >@@ -30,12 +34,22 @@ > import org.eclipse.sapphire.ui.SapphireActionGroup; > import org.eclipse.sapphire.ui.SapphireActionHandler; > import org.eclipse.sapphire.ui.SapphireRenderingContext; >+import org.eclipse.sapphire.ui.def.ISapphireActionDef; > import org.eclipse.sapphire.ui.def.SapphireActionType; >+import org.eclipse.swt.SWT; >+import org.eclipse.swt.events.DisposeEvent; >+import org.eclipse.swt.events.DisposeListener; > import org.eclipse.swt.graphics.Cursor; > import org.eclipse.swt.graphics.Rectangle; >+import org.eclipse.swt.widgets.Button; >+import org.eclipse.swt.widgets.Composite; >+import org.eclipse.swt.widgets.Control; >+import org.eclipse.swt.widgets.CoolBar; >+import org.eclipse.swt.widgets.Menu; > import org.eclipse.swt.widgets.Shell; > import org.eclipse.swt.widgets.ToolBar; > import org.eclipse.swt.widgets.ToolItem; >+import org.eclipse.ui.internal.forms.widgets.FormsResources; > > /** > * @author <a href="mailto:konstantin.komissarchik@oracle.com">Konstantin Komissarchik</a> >@@ -47,6 +61,7 @@ > > { > private IToolBarManager toolbar; >+ private SapphireToolbarContribution sapphireToolbar; > > public SapphireToolBarManagerActionPresentation( final SapphireActionPresentationManager manager ) > { >@@ -68,6 +83,8 @@ > public void setToolBarManager( final IToolBarManager toolbar ) > { > this.toolbar = toolbar; >+ >+ this.sapphireToolbar = new SapphireToolbarContribution("sapphire"); > } > > public void render() >@@ -79,13 +96,15 @@ > boolean first = true; > String lastGroup = null; > >+ this.toolbar.add(this.sapphireToolbar); >+ > for( final SapphireAction action : getActions() ) > { > final String group = action.getGroup(); > > if( ! first && ! equal( lastGroup, group ) ) > { >- this.toolbar.add( new Separator() ); >+ this.sapphireToolbar.add( new Separator() ); > } > > first = false; >@@ -130,10 +149,30 @@ > throw new IllegalStateException(); > } > >- a.setImageDescriptor( action.getImage( 16 ) ); >+ String hint = action.getRenderingHint(ISapphireActionDef.HINT_ACTION_STYLE, ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE); >+ >+ if (ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE.equals(hint) || >+ ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE_LABEL.equals(hint)) >+ { >+ a.setImageDescriptor( action.getImage( 16 ) ); >+ } >+ >+ if (ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE_LABEL.equals(hint) || >+ ISapphireActionDef.HINT_VALUE_ACTION_STYLE_LABEL_ONLY.equals(hint)) >+ { >+ a.setText( LabelTransformer.transform( action.getLabel(), CapitalizationType.TITLE_STYLE, true ) ); >+ } >+ > a.setToolTipText( LabelTransformer.transform( action.getLabel(), CapitalizationType.TITLE_STYLE, false ) ); > >- this.toolbar.add( a ); >+ ActionContributionItem item = new ActionContributionItem(a); >+ >+ if (ISapphireActionDef.HINT_VALUE_ACTION_STYLE_IMAGE_LABEL.equals(hint)) >+ { >+ item.setMode(ActionContributionItem.MODE_FORCE_TEXT); >+ } >+ >+ this.sapphireToolbar.add( item ); > > final Runnable updateActionEnablementStateOp = new Runnable() > { >@@ -256,4 +295,43 @@ > } > } > >+ private final class SapphireToolbarContribution extends ControlContribution >+ { >+ private ToolBarManager embeddedToolbarManager; >+ private List<IContributionItem> items = new ArrayList<IContributionItem>(); >+ >+ protected SapphireToolbarContribution(String id) >+ { >+ super(id); >+ } >+ >+ public void add(IContributionItem item) >+ { >+ items.add(item); >+ } >+ >+ @Override >+ protected Control createControl(Composite parent) >+ { >+ this.embeddedToolbarManager = new ToolBarManager(SWT.FLAT | SWT.RIGHT); >+ ToolBar embeddedToolbar = this.embeddedToolbarManager.createControl(parent); >+ embeddedToolbar.setBackground(null); >+ embeddedToolbar.setForeground(parent.getForeground()); >+ embeddedToolbar.setCursor(FormsResources.getHandCursor()); >+ updateToolbar(); >+ return embeddedToolbar; >+ } >+ >+ private void updateToolbar() >+ { >+ this.embeddedToolbarManager.removeAll(); >+ >+ for (IContributionItem item : items) { >+ this.embeddedToolbarManager.add(item); >+ } >+ >+ this.embeddedToolbarManager.update(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 342771
:
193955
|
193956
|
194106
|
194109