@Override public void setData( String key, Object value ) { browser.setData(key, value); }
public Composite createComposite(Composite parentComp) { // if(dialog==null) { // shell = new Shell((Shell)parentComp,style); // composite = shell; // } else { composite = new Composite(parentComp, SWT.NONE); // } composite.setData(this); return composite; }
public Composite createComposite(Composite parentComp) { // if(dialog==null) { // shell = new Shell((Shell)parentComp,style); // composite = shell; // } else { composite = new Composite(parentComp, SWT.NONE); // } composite.setData(this); return composite; }
/** * Creates the SWT-Composite of the NotebookPage. All SWT-Widgets of this PageClient * will be children of this Composite (directly or indirectly). * * @param parentComp the SWT-Composite to use as parent of the created SWT-Composite. * @return the newly created SWT-Composite corresponding to this NotebookPage */ public Composite createComposite(Composite parentComp) { composite = new Composite(parentComp, SWT.NONE); composite.setData(this); return composite; }
/** * Creates the SWT-Composite of the NotebookPage. All SWT-Widgets of this PageClient * will be children of this Composite (directly or indirectly). * * @param parentComp the SWT-Composite to use as parent of the created SWT-Composite. * @return the newly created SWT-Composite corresponding to this NotebookPage */ public Composite createComposite(Composite parentComp) { composite = new Composite(parentComp, SWT.NONE); composite.setData(this); return composite; }
@Override public void startContainerLayout( Composite container, SwtMetawidget metawidget ) { super.startContainerLayout( container, metawidget ); container.setData( getClass().getName(), null ); }
@Override public void setData( String key, Object value ) { if( !RWT.MARKUP_ENABLED.equals( key ) || !isMarkupEnabledFor( this ) ) { super.setData( key, value ); } }
private void createUIParent() { uiParent = new Composite( shell, SWT.NONE ); uiParent.setData( RWT.CUSTOM_VARIANT, CUSTOM_VARIANT_TABRIS_UI ); uiParent.setLayoutData( new GridData( GridData.FILL, GridData.CENTER, true, false ) ); uiParent.setBackgroundMode( SWT.INHERIT_DEFAULT ); GridLayout layout = new GridLayout( 4, false ); layout.marginHeight = 0; layout.marginWidth = 10; layout.verticalSpacing = 0; uiParent.setLayout( layout ); }
@Override protected State getState( Composite container, SwtMetawidget metawidget ) { State state = (State) container.getData( getClass().getName() ); if ( state == null ) { state = new State(); container.setData( getClass().getName(), state ); } return state; }
private State getState( Composite container ) { State state = (State) container.getData( MigLayout.class.getName() ); if ( state == null ) { state = new State(); container.setData( MigLayout.class.getName(), state ); } return state; }
@Override public void setData( String key, Object value ) { if( RWT.CUSTOM_ITEM_HEIGHT.equals( key ) ) { setCustomItemHeight( value ); } else if( RWT.PRELOADED_ITEMS.equals( key ) ) { setPreloadedItems( value ); } if( !RWT.MARKUP_ENABLED.equals( key ) || !isMarkupEnabledFor( this ) ) { super.setData( key, value ); } }
private Composite createFacade() { Composite facade = new Composite( composite, SWT.NONE ); facade.setData( GROUPED_EVENT_COMPOSITE, WidgetUtil.getId( composite ) ); facade.setData( RWT.CUSTOM_VARIANT, GROUPED_EVENT_COMPOSITE ); addLayoutDataWithExclude( facade ); layoutFacade( facade ); addResizeListener( facade ); return facade; }
@Override public void widgetSelected(SelectionEvent ev){ Composite c = (Composite)tf.getSelection().getControl(); Object o = c.getData(); if ( o instanceof Runnable ){ ((Runnable)o).run(); c.setData(null); } } });
@Override public void widgetSelected(SelectionEvent ev){ Composite c = (Composite)tf.getSelection().getControl(); Object o = c.getData(); if ( o instanceof Runnable ){ ((Runnable)o).run(); c.setData(null); } } });
@Override public void reset() { Composite composite = getComposite(); if (composite.getData(BACKGROUND_OVERRIDDEN_BY_CSS_MARKER) != null) { composite.setData(BACKGROUND_OVERRIDDEN_BY_CSS_MARKER, null); } super.reset(); }
private Composite getHostPane() { // Create one hostPane = new Composite(trimStackTB.getShell(), SWT.NONE); hostPane.setData(ShellActivationListener.DIALOG_IGNORE_KEY, Boolean.TRUE); hostPane.addDisposeListener(e -> hostPane = null); setHostSize(); // Set a special layout that allows resizing fixedSides = getFixedSides(); hostPane.setLayout(new TrimPaneLayout(toolControl, fixedSides)); return hostPane; }
public static void setBackgroundOverriddenDuringRenderering( Composite composite, Color background) { CSSSWTColorHelper.setBackground(composite, background); composite.setData(BACKGROUND_SET_BY_TAB_RENDERER, background); for (Control control : composite.getChildren()) { if (!CompositeElement.hasBackgroundOverriddenByCSS(control)) { CSSSWTColorHelper.setBackground(control, background); control.setData(BACKGROUND_SET_BY_TAB_RENDERER, background); } } } }
public void createPartControl(Composite parent) { parent.setData(this); fPageBook = new PageBook(parent, SWT.NONE); createCompareControl(); IContextService service = (IContextService)getSite().getService(IContextService.class); if (service != null) service.activateContext("org.eclipse.compare.compareEditorScope"); //$NON-NLS-1$ }
private void createStandbyPart() { standbyPart = new StandbyPart(model); standbyPart.init(this, getMemento(memento, IIntroConstants.MEMENTO_STANDBY_PART_TAG)); standbyPart.createPartControl((Composite) getControl()); restoreStandby = false; container.setData(IIntroConstants.SHOW_STANDBY_PART, "true"); //$NON-NLS-1$ }
@Override public void createPartControl(Composite parent) { parent.setData(this); fPageBook = new PageBook(parent, SWT.NONE); createCompareControl(); IContextService service = getSite().getService(IContextService.class); if (service != null) { service.activateContext("org.eclipse.compare.compareEditorScope"); //$NON-NLS-1$ service.activateContext("org.eclipse.ui.textEditorScope"); //$NON-NLS-1$ } }