Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorJeffrey Stedfast <jeff@xamarin.com>2011-10-18 21:07:46 +0400
committerJeffrey Stedfast <jeff@xamarin.com>2011-10-18 21:07:46 +0400
commitecf1e514653b7261aef0722d858db1ae3f591b74 (patch)
tree165a88f653e8d6a5d8960e056dbbc14c462f7253 /main
parentd19d50ed79015d8222df442fe2825c1082b09b43 (diff)
[TextEditor] Make sure tooltips show up on the right monitor
Fixed the logic for displaying tooltips in cases where the mouse cursor is hovering over a variable split between two monitors.
Diffstat (limited to 'main')
-rwxr-xr-xmain/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs6
1 files changed, 4 insertions, 2 deletions
diff --git a/main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs b/main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs
index eba4f26a8a..07f3032a95 100755
--- a/main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs
+++ b/main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs
@@ -2414,8 +2414,10 @@ namespace Mono.TextEditor
provider.GetRequiredPosition (this, liw, out w, out xalign);
w += 10;
- int x = xloc + ox + (int)textViewMargin.XOffset - (int) ((double)w * xalign);
- Gdk.Rectangle geometry = Screen.GetUsableMonitorGeometry (Screen.GetMonitorAtPoint (ox + xloc, oy + yloc));
+ int x = xloc + ox + (int) textViewMargin.XOffset;
+ Gdk.Rectangle geometry = Screen.GetUsableMonitorGeometry (Screen.GetMonitorAtPoint (x, oy + yloc));
+
+ x -= (int) ((double) w * xalign);
if (x + w >= geometry.Right)
x = geometry.Right - w;