Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcletavernie2012-02-20 07:43:13 -0500
committercletavernie2012-02-20 07:43:13 -0500
commit6d6d3064c0977a09d4964dc72b50c78f0d0fcdfc (patch)
treea313d439609ec44025d53302d08b5c72911b5a31 /plugins
parent78f5e8105430d922ebcb866d194d3b4ed3e82a9e (diff)
downloadorg.eclipse.papyrus-6d6d3064c0977a09d4964dc72b50c78f0d0fcdfc.tar.gz
org.eclipse.papyrus-6d6d3064c0977a09d4964dc72b50c78f0d0fcdfc.tar.xz
org.eclipse.papyrus-6d6d3064c0977a09d4964dc72b50c78f0d0fcdfc.zip
371905: [ModelExplorer] Tooltips related to error markers are no longer displayed by the model explorer
https://bugs.eclipse.org/bugs/show_bug.cgi?id=371905
Diffstat (limited to 'plugins')
-rw-r--r--plugins/infra/org.eclipse.papyrus.infra.hyperlink/META-INF/MANIFEST.MF3
-rw-r--r--plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorHyperLinkEditorShell.java8
-rw-r--r--plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorLookForEditorShell.java19
-rw-r--r--plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.modelexplorer/src/org/eclipse/papyrus/uml/diagram/modelexplorer/handler/DiagramViewHandler.java10
4 files changed, 23 insertions, 17 deletions
diff --git a/plugins/infra/org.eclipse.papyrus.infra.hyperlink/META-INF/MANIFEST.MF b/plugins/infra/org.eclipse.papyrus.infra.hyperlink/META-INF/MANIFEST.MF
index 0cbf4786bc3..7b1e02d1118 100644
--- a/plugins/infra/org.eclipse.papyrus.infra.hyperlink/META-INF/MANIFEST.MF
+++ b/plugins/infra/org.eclipse.papyrus.infra.hyperlink/META-INF/MANIFEST.MF
@@ -9,7 +9,8 @@ Require-Bundle: org.eclipse.emf.transaction,
org.eclipse.gef,
org.eclipse.papyrus.infra.emf,
org.eclipse.papyrus.views.modelexplorer,
- org.eclipse.papyrus.infra.table.instance
+ org.eclipse.papyrus.infra.table.instance,
+ org.eclipse.ui.navigator;bundle-version="3.5.100"
Bundle-ActivationPolicy: lazy
Bundle-RequiredExecutionEnvironment: J2SE-1.5
Export-Package: org.eclipse.papyrus.infra.hyperlink,
diff --git a/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorHyperLinkEditorShell.java b/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorHyperLinkEditorShell.java
index 2082513b2f7..8be508db105 100644
--- a/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorHyperLinkEditorShell.java
+++ b/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorHyperLinkEditorShell.java
@@ -20,7 +20,8 @@ import org.eclipse.papyrus.infra.core.editorsfactory.IPageIconsRegistry;
import org.eclipse.papyrus.infra.hyperlink.helper.EditorHyperLinkHelper;
import org.eclipse.papyrus.infra.hyperlink.messages.Messages;
import org.eclipse.papyrus.infra.hyperlink.object.HyperLinkEditor;
-import org.eclipse.papyrus.views.modelexplorer.MoDiscoLabelProviderWTooltips;
+import org.eclipse.papyrus.views.modelexplorer.DecoratingLabelProviderWTooltips;
+import org.eclipse.papyrus.views.modelexplorer.MoDiscoLabelProvider;
import org.eclipse.swt.events.MouseEvent;
import org.eclipse.swt.events.MouseListener;
import org.eclipse.swt.widgets.Display;
@@ -55,8 +56,9 @@ public class EditorHyperLinkEditorShell extends AbstractEditHyperlinkDocumentShe
getEditHyperlinkShell().pack();
getEditHyperlinkShell().open();
while(!getEditHyperlinkShell().isDisposed()) {
- if(!display.readAndDispatch())
+ if(!display.readAndDispatch()) {
display.sleep();
+ }
}
}
@@ -122,7 +124,7 @@ public class EditorHyperLinkEditorShell extends AbstractEditHyperlinkDocumentShe
hyperLinkEditor.setObject(selection);
//TODO : remove this dependency
- MoDiscoLabelProviderWTooltips labelProvider = new MoDiscoLabelProviderWTooltips();
+ DecoratingLabelProviderWTooltips labelProvider = new DecoratingLabelProviderWTooltips(new MoDiscoLabelProvider());
getObjectLabeltext().setText(labelProvider.getText(selection));
if(usedefaultTooltip) {
getTooltipInputText().setText(getObjectLabeltext().getText());
diff --git a/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorLookForEditorShell.java b/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorLookForEditorShell.java
index 518bb365c4a..048572aa1bd 100644
--- a/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorLookForEditorShell.java
+++ b/plugins/infra/org.eclipse.papyrus.infra.hyperlink/src/org/eclipse/papyrus/infra/hyperlink/ui/EditorLookForEditorShell.java
@@ -44,8 +44,9 @@ import org.eclipse.papyrus.infra.hyperlink.helper.AbstractHyperLinkEditorHelper;
import org.eclipse.papyrus.infra.hyperlink.object.HyperLinkEditor;
import org.eclipse.papyrus.infra.hyperlink.util.EditorListContentProvider;
import org.eclipse.papyrus.infra.hyperlink.util.HyperLinkEditorHelpersRegistrationUtil;
-import org.eclipse.papyrus.infra.table.instance.papyrustableinstance.PapyrusTableInstance;//TODO remove this dependency
-import org.eclipse.papyrus.views.modelexplorer.MoDiscoLabelProviderWTooltips;
+import org.eclipse.papyrus.infra.table.instance.papyrustableinstance.PapyrusTableInstance;
+import org.eclipse.papyrus.views.modelexplorer.DecoratingLabelProviderWTooltips;
+import org.eclipse.papyrus.views.modelexplorer.MoDiscoLabelProvider;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
@@ -55,6 +56,7 @@ import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Menu;
import org.eclipse.swt.widgets.MenuItem;
+//TODO remove this dependency
@@ -360,9 +362,13 @@ public class EditorLookForEditorShell extends AbstractLookForEditorShell {
}
return false;
}
-
+
//TODO delete this class to remove the PapyrusTable dependencies!
- private class LocalLabelProvider extends MoDiscoLabelProviderWTooltips{
+ private class LocalLabelProvider extends DecoratingLabelProviderWTooltips {
+
+ public LocalLabelProvider() {
+ super(new MoDiscoLabelProvider());
+ }
/**
* Return the EditorRegistry for nested editor descriptors. Subclass should
@@ -381,6 +387,7 @@ public class EditorLookForEditorShell extends AbstractLookForEditorShell {
return new PageIconsRegistry();
}
}
+
/**
* the icon registry
*/
@@ -402,11 +409,11 @@ public class EditorLookForEditorShell extends AbstractLookForEditorShell {
}
return (IPageIconsRegistryExtended)editorRegistry;
}
-
+
@Override
public String getText(Object element) {
if(element instanceof PapyrusTableInstance) {
- return ((PapyrusTableInstance)element).getName();
+ return ((PapyrusTableInstance)element).getName();
}
return super.getText(element);
}
diff --git a/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.modelexplorer/src/org/eclipse/papyrus/uml/diagram/modelexplorer/handler/DiagramViewHandler.java b/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.modelexplorer/src/org/eclipse/papyrus/uml/diagram/modelexplorer/handler/DiagramViewHandler.java
index a6dd63b6408..249e06a42a1 100644
--- a/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.modelexplorer/src/org/eclipse/papyrus/uml/diagram/modelexplorer/handler/DiagramViewHandler.java
+++ b/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.modelexplorer/src/org/eclipse/papyrus/uml/diagram/modelexplorer/handler/DiagramViewHandler.java
@@ -19,7 +19,8 @@ import org.eclipse.core.commands.ExecutionException;
import org.eclipse.papyrus.infra.emf.providers.MoDiscoContentProvider;
import org.eclipse.papyrus.uml.diagram.modelexplorer.provider.DiagramContentProvider;
import org.eclipse.papyrus.uml.diagram.modelexplorer.provider.DiagramLabelProvider;
-import org.eclipse.papyrus.views.modelexplorer.MoDiscoLabelProviderWTooltips;
+import org.eclipse.papyrus.views.modelexplorer.DecoratingLabelProviderWTooltips;
+import org.eclipse.papyrus.views.modelexplorer.MoDiscoLabelProvider;
import org.eclipse.papyrus.views.modelexplorer.ModelExplorerPageBookView;
import org.eclipse.swt.widgets.Event;
import org.eclipse.swt.widgets.ToolItem;
@@ -59,14 +60,9 @@ public class DiagramViewHandler extends AbstractHandler {
getCommonNavigator().getCommonViewer().setLabelProvider(new DiagramLabelProvider());
} else {
getCommonNavigator().getCommonViewer().setContentProvider(new MoDiscoContentProvider());
- getCommonNavigator().getCommonViewer().setLabelProvider(new MoDiscoLabelProviderWTooltips());
+ getCommonNavigator().getCommonViewer().setLabelProvider(new DecoratingLabelProviderWTooltips(new MoDiscoLabelProvider()));
}
getCommonNavigator().getCommonViewer().refresh();
return null;
}
-
-
-
-
-
}

Back to the top