/** * Ueberschrieben, um einen DisposeListener an das Composite zu haengen. * * @see de.willuhn.jameica.gui.parts.TablePart#paint(org.eclipse.swt.widgets.Composite) */ public synchronized void paint(Composite parent) throws RemoteException { final TabFolder folder = new TabFolder(parent, SWT.NONE); folder.setLayoutData(new GridData(GridData.FILL_HORIZONTAL)); TabGroup tab = new TabGroup(folder, i18n.tr("Anzeige einschränken")); ColumnLayout cols = new ColumnLayout(tab.getComposite(), 2); { this.left = new SimpleContainer(cols.getComposite()); Input t = this.getText(); this.left.addInput(t); // Duerfen wir erst nach dem Zeichnen t.getControl().addKeyListener(new DelayedAdapter()); this.left.addInput(this.getKonto()); } { Container right = new SimpleContainer(cols.getComposite()); right.addInput(this.getRange()); MultiInput range = new MultiInput(this.getFrom(), this.getTo()); right.addInput(range); } this.buttons.addButton( i18n.tr("Aktualisieren"), new Action() { public void handleAction(Object context) throws ApplicationException { handleReload(true); } }, null, true, "view-refresh.png"); this.buttons.paint(parent); // Erstbefuellung GenericIterator items = getList( getKonto().getValue(), (Date) getFrom().getValue(), (Date) getTo().getValue(), (String) getText().getValue()); if (items != null) { items.begin(); while (items.hasNext()) addItem(items.next()); } super.paint(parent); }
/** @see de.willuhn.jameica.gui.parts.TablePart#paint(org.eclipse.swt.widgets.Composite) */ public synchronized void paint(Composite parent) throws RemoteException { Application.getMessagingFactory() .getMessagingQueue(Settings.QUEUE_KONTENRAHMEN_CREATED) .registerMessageConsumer(this.mc); parent.addDisposeListener( new DisposeListener() { public void widgetDisposed(DisposeEvent e) { Application.getMessagingFactory() .getMessagingQueue(Settings.QUEUE_KONTENRAHMEN_CREATED) .unRegisterMessageConsumer(mc); } }); super.paint(parent); }
public TablePart paintSpaltenpaintSpaltendefinitionTable(Composite parent) throws RemoteException { if (spaltendefinitionList != null) { return spaltendefinitionList; } spaltendefinitionList = new TablePart(spalten, null); spaltendefinitionList.addColumn(JVereinPlugin.getI18n().tr("Spalte"), "spaltenbezeichnung"); spaltendefinitionList.setCheckable(true); spaltendefinitionList.setMulti(true); spaltendefinitionList.setSummary(false); spaltendefinitionList.paint(parent); for (int i = 0; i < spalten.size(); ++i) { spaltendefinitionList.setChecked(spalten.get(i), spalten.get(i).isChecked()); } return spaltendefinitionList; }