Author: pkluegl
Date: Wed Jan 18 15:38:13 2012
New Revision: 1232934

URL: http://svn.apache.org/viewvc?rev=1232934&view=rev
Log:
UIMA-2287
TextMarker views now extend CasEditorView. Removed basic stream view.

Modified:
    
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/browser/AnnotationBrowserView.java
    
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/selection/SelectionView.java
    
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/tree/AnnotationTreeContentProvider.java
    
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/ExplainPerspective.java
    
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/TextMarkerPerspective.java

Modified: 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/browser/AnnotationBrowserView.java
URL: 
http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/browser/AnnotationBrowserView.java?rev=1232934&r1=1232933&r2=1232934&view=diff
==============================================================================
--- 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/browser/AnnotationBrowserView.java
 (original)
+++ 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/browser/AnnotationBrowserView.java
 Wed Jan 18 15:38:13 2012
@@ -20,11 +20,12 @@
 package org.apache.uima.textmarker.caseditor.view.browser;
 
 import org.apache.uima.caseditor.editor.AnnotationEditor;
-import org.apache.uima.caseditor.editor.AnnotationEditorView;
+import org.apache.uima.caseditor.editor.CasEditorView;
 import org.apache.uima.caseditor.editor.ICasEditor;
 import org.apache.uima.textmarker.caseditor.view.tree.AnnotationTreeViewPage;
+import org.eclipse.ui.part.IPageBookViewPage;
 
-public class AnnotationBrowserView extends AnnotationEditorView {
+public class AnnotationBrowserView extends CasEditorView {
   public static final String ID = "org.apache.uima.caseditor.browser";
 
   public AnnotationBrowserView() {
@@ -32,13 +33,11 @@ public class AnnotationBrowserView exten
   }
 
   @Override
-  protected PageRec doCreatePage(ICasEditor editor) {
-    PageRec result = null;
+  protected IPageBookViewPage doCreatePage(ICasEditor editor) {
+    IPageBookViewPage result = null;
     if (editor.getDocument() != null && editor instanceof AnnotationEditor) {
       AnnotationTreeViewPage page = new AnnotationTreeViewPage(false, 
(AnnotationEditor) editor);
-      initPage(page);
-      page.createControl(getPageBook());
-      result = new PageRec(editor, page);
+      result = page;
     }
     return result;
   }

Modified: 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/selection/SelectionView.java
URL: 
http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/selection/SelectionView.java?rev=1232934&r1=1232933&r2=1232934&view=diff
==============================================================================
--- 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/selection/SelectionView.java
 (original)
+++ 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/selection/SelectionView.java
 Wed Jan 18 15:38:13 2012
@@ -20,13 +20,14 @@
 package org.apache.uima.textmarker.caseditor.view.selection;
 
 import org.apache.uima.caseditor.editor.AnnotationEditor;
-import org.apache.uima.caseditor.editor.AnnotationEditorView;
+import org.apache.uima.caseditor.editor.CasEditorView;
 import org.apache.uima.caseditor.editor.ICasEditor;
 import org.apache.uima.textmarker.caseditor.view.tree.AnnotationTreeViewPage;
+import org.eclipse.ui.part.IPageBookViewPage;
 
 /**
  */
-public final class SelectionView extends AnnotationEditorView {
+public final class SelectionView extends CasEditorView {
 
   public static final String ID = "org.apache.uima.caseditor.selection";
 
@@ -35,13 +36,11 @@ public final class SelectionView extends
   }
 
   @Override
-  protected PageRec doCreatePage(ICasEditor editor) {
-    PageRec result = null;
+  protected IPageBookViewPage doCreatePage(ICasEditor editor) {
+    IPageBookViewPage result = null;
     if (editor.getDocument() != null && editor instanceof AnnotationEditor) {
       AnnotationTreeViewPage page = new AnnotationTreeViewPage(true, 
(AnnotationEditor) editor);
-      initPage(page);
-      page.createControl(getPageBook());
-      result = new PageRec(editor, page);
+      result = page;
     }
     return result;
   }

Modified: 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/tree/AnnotationTreeContentProvider.java
URL: 
http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/tree/AnnotationTreeContentProvider.java?rev=1232934&r1=1232933&r2=1232934&view=diff
==============================================================================
--- 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/tree/AnnotationTreeContentProvider.java
 (original)
+++ 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-caseditor/src/main/java/org/apache/uima/textmarker/caseditor/view/tree/AnnotationTreeContentProvider.java
 Wed Jan 18 15:38:13 2012
@@ -136,10 +136,10 @@ public class AnnotationTreeContentProvid
   @Override
   public void casDocumentChanged(IEditorInput oldInput, ICasDocument 
oldDocument,
           IEditorInput newInput, ICasDocument newDocument) {
-    document.removeChangeListener(this);
-    document = newDocument;
-    document.addChangeListener(this);
-    changed();
+//    document.removeChangeListener(this);
+//    document = newDocument;
+//    document.addChangeListener(this);
+//    changed();
   }
 
 }

Modified: 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/ExplainPerspective.java
URL: 
http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/ExplainPerspective.java?rev=1232934&r1=1232933&r2=1232934&view=diff
==============================================================================
--- 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/ExplainPerspective.java
 (original)
+++ 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/ExplainPerspective.java
 Wed Jan 18 15:38:13 2012
@@ -44,8 +44,6 @@ public class ExplainPerspective implemen
 
   public static final String QUERY = 
"org.apache.uima.textmarker.query.ui.ScriptQueryView";
 
-  public static final String BASIC_STREAM = 
"org.apache.uima.textmarker.explain.basic";
-
   public static final String PALETTE_VIEW = 
"org.apache.uima.cev.views.palette";
 
   public static final String TYPE_BROWSER = 
"org.apache.uima.cev.views.typeBrowser";
@@ -87,7 +85,6 @@ public class ExplainPerspective implemen
     layout.addShowViewShortcut(IProgressConstants.PROGRESS_VIEW_ID);
 
     layout.addShowViewShortcut(SCRIPT_EXPLORER);
-    layout.addShowViewShortcut(BASIC_STREAM);
     layout.addShowViewShortcut(PALETTE_VIEW);
     layout.addShowViewShortcut(TYPE_BROWSER);
     layout.addShowViewShortcut(SELECTION_VIEW);
@@ -101,7 +98,6 @@ public class ExplainPerspective implemen
 
     IFolderLayout rightFolder = layout.createFolder("rightFolder", 
IPageLayout.RIGHT, (float) 0.75,
             editorArea);
-    rightFolder.addView(BASIC_STREAM);
     rightFolder.addView(APPLIED_RULES);
     rightFolder.addView(SELECTION_RULES);
     rightFolder.addView(RULE_LIST);

Modified: 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/TextMarkerPerspective.java
URL: 
http://svn.apache.org/viewvc/uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/TextMarkerPerspective.java?rev=1232934&r1=1232933&r2=1232934&view=diff
==============================================================================
--- 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/TextMarkerPerspective.java
 (original)
+++ 
uima/sandbox/trunk/TextMarker/uimaj-ep-textmarker-ide/src/main/java/org/apache/uima/textmarker/ide/ui/TextMarkerPerspective.java
 Wed Jan 18 15:38:13 2012
@@ -30,8 +30,6 @@ import org.eclipse.ui.progress.IProgress
 
 public class TextMarkerPerspective implements IPerspectiveFactory {
 
-  public static final String BASIC_STREAM = 
"org.apache.uima.textmarker.explain.basic";
-
   public static final String TYPE_BROWSER = 
"org.apache.uima.caseditor.browser";
 
   public static final String SELECTION_VIEW = 
"org.apache.uima.caseditor.selection";
@@ -75,7 +73,6 @@ public class TextMarkerPerspective imple
     layout.addShowViewShortcut(IProgressConstants.PROGRESS_VIEW_ID);
 
     layout.addShowViewShortcut(SCRIPT_EXPLORER);
-    layout.addShowViewShortcut(BASIC_STREAM);
     layout.addShowViewShortcut(TYPE_BROWSER);
     layout.addShowViewShortcut(SELECTION_VIEW);
     layout.addShowViewShortcut(TEXTRULER);
@@ -95,7 +92,6 @@ public class TextMarkerPerspective imple
             editorArea);
     rightFolder.addView(IPageLayout.ID_OUTLINE);
     rightFolder.addView(TYPE_BROWSER);
-    rightFolder.addView(BASIC_STREAM);
 
     // Folder
     IFolderLayout folder = layout.createFolder("left", IPageLayout.LEFT, 
(float) 0.2, editorArea); //$NON-NLS-1$               


Reply via email to