void install() { fViewer.addViewportListener(this); fViewer.getDocument().addDocumentListener(this); fViewer.getTextWidget().addControlListener(this); } }
protected void refresh() { adjustItemNumber(); if (fInput == null) return; if (fInput.fAnnotations == null) return; if (fInput.fViewer != null) fInput.fViewer.addViewportListener(fViewportListener); fShell.setRegion(fLayouter.getShellRegion(fInput.fAnnotations.length)); Layout layout= fLayouter.getLayout(fInput.fAnnotations.length); fComposite.setLayout(layout); Control[] children= fComposite.getChildren(); for (int i= 0; i < fInput.fAnnotations.length; i++) { Canvas canvas= (Canvas) children[i]; Item item= new Item(); item.canvas= canvas; item.fAnnotation= fInput.fAnnotations[i]; canvas.setData(item); canvas.redraw(); } }
protected void refresh() { adjustItemNumber(); if (fInput == null) return; if (fInput.fAnnotations == null) return; if (fInput.fViewer != null) fInput.fViewer.addViewportListener(fViewportListener); fShell.setRegion(fLayouter.getShellRegion(fInput.fAnnotations.length)); Layout layout= fLayouter.getLayout(fInput.fAnnotations.length); fComposite.setLayout(layout); Control[] children= fComposite.getChildren(); for (int i= 0; i < fInput.fAnnotations.length; i++) { Canvas canvas= (Canvas) children[i]; Item item= new Item(); item.canvas= canvas; item.fAnnotation= fInput.fAnnotations[i]; canvas.setData(item); canvas.redraw(); } }
protected void refresh() { adjustItemNumber(); if (fInput == null) return; if (fInput.fAnnotations == null) return; if (fInput.fViewer != null) fInput.fViewer.addViewportListener(fViewportListener); fShell.setRegion(fLayouter.getShellRegion(fInput.fAnnotations.length)); Layout layout= fLayouter.getLayout(fInput.fAnnotations.length); fComposite.setLayout(layout); Control[] children= fComposite.getChildren(); for (int i= 0; i < fInput.fAnnotations.length; i++) { Canvas canvas= (Canvas) children[i]; Item item= new Item(); item.canvas= canvas; item.fAnnotation= fInput.fAnnotations[i]; canvas.setData(item); canvas.redraw(); } }
textWidget.addKeyListener(this); editor.getSite().getShell().addControlListener(this); viewer.addViewportListener(this); popup.addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent e) {
fEditor.getSite().getShell().addControlListener(this); viewer.addTextListener(this); viewer.addViewportListener(this); fPopup.addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent e) {
fEditor.getSite().getShell().addControlListener(this); viewer.addTextListener(this); viewer.addViewportListener(this); fPopup.addDisposeListener(new DisposeListener() { @Override
fEditor.getSite().getShell().addControlListener(this); viewer.addTextListener(this); viewer.addViewportListener(this); fPopup.addDisposeListener(new DisposeListener() { @Override