Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfbecker2009-06-22 20:42:19 +0000
committerfbecker2009-06-22 20:42:19 +0000
commitf7361b80b243e956b58b4605dcf5c3790603e261 (patch)
tree9d089096597365d0ac4fbdb788fe8d57518b6636
parent1a2a5afc268d259eac549e49ab7c85e33c435d5e (diff)
downloadorg.eclipse.mylyn.tasks-f7361b80b243e956b58b4605dcf5c3790603e261.tar.gz
org.eclipse.mylyn.tasks-f7361b80b243e956b58b4605dcf5c3790603e261.tar.xz
org.eclipse.mylyn.tasks-f7361b80b243e956b58b4605dcf5c3790603e261.zip
ASSIGNED - bug 280973: [mac] Tooltip not shown when Tasklist is scrolled
https://bugs.eclipse.org/bugs/show_bug.cgi?id=280973
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/PlatformUtil.java8
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTip.java8
2 files changed, 6 insertions, 10 deletions
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/PlatformUtil.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/PlatformUtil.java
index 13958ac97..db14107d9 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/PlatformUtil.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/PlatformUtil.java
@@ -144,12 +144,4 @@ public class PlatformUtil {
public static boolean hasNarrowToolBar() {
return Platform.WS_WIN32.equals(SWT.getPlatform());
}
-
- /**
- * On Cocoa the bounds from an TreeViewer are handed in the way that scrolling did not change them. So when you have
- * initial not visible Element the bound of them are outside of the TreeViewer control
- */
- public static boolean needsTreeItemBoundsFix() {
- return "cocoa".equals(SWT.getPlatform()); //$NON-NLS-1$
- }
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTip.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTip.java
index a4fff011b..2e773c777 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTip.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTip.java
@@ -428,8 +428,12 @@ public class TaskListToolTip extends GradientToolTip {
Rectangle bounds = getBounds(tipWidget);
if (tipWidget instanceof ScalingHyperlink) {
currentTipElement = getTaskListElement(tipWidget);
- } else if (PlatformUtil.needsTreeItemBoundsFix()
- || (bounds != null && control.getBounds().contains(bounds.x, bounds.y))) {
+ } else if (tipWidget instanceof TreeItem) {
+ Tree tree = ((TreeItem) tipWidget).getParent();
+ if ((bounds != null && tree.getClientArea().contains(bounds.x, bounds.y))) {
+ currentTipElement = getTaskListElement(tipWidget);
+ }
+ } else if ((bounds != null && control.getBounds().contains(bounds.x, bounds.y))) {
currentTipElement = getTaskListElement(tipWidget);
}
}

Back to the top