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:
authorMike Krüger <mkrueger@xamarin.com>2015-02-11 17:23:06 +0300
committerMike Krüger <mkrueger@xamarin.com>2015-02-11 17:23:06 +0300
commitc9c33bb840e3f046ff71bfe0c9868fb1b923a495 (patch)
tree43323c79412626afca496e2e79661886c963dc3b /main
parentbd4ef481310a1db2a9d2fc4efa02e46790bca28f (diff)
Implemented 'Bug 26924 - [Win32] Shift+mouse wheel doesn't scroll
horizontally'.
Diffstat (limited to 'main')
-rw-r--r--main/src/core/Mono.Texteditor/Mono.TextEditor/Gui/TextArea.cs17
1 files changed, 15 insertions, 2 deletions
diff --git a/main/src/core/Mono.Texteditor/Mono.TextEditor/Gui/TextArea.cs b/main/src/core/Mono.Texteditor/Mono.TextEditor/Gui/TextArea.cs
index c1efa4f730..8872924319 100644
--- a/main/src/core/Mono.Texteditor/Mono.TextEditor/Gui/TextArea.cs
+++ b/main/src/core/Mono.Texteditor/Mono.TextEditor/Gui/TextArea.cs
@@ -1631,18 +1631,31 @@ namespace Mono.TextEditor
var hasZoomModifier = (evnt.State & modifier) != 0;
if (hasZoomModifier && lastScrollTime != 0 && (evnt.Time - lastScrollTime) < 100)
hasZoomModifier = false;
-
+
if (hasZoomModifier) {
if (evnt.Direction == ScrollDirection.Up)
Options.ZoomIn ();
else if (evnt.Direction == ScrollDirection.Down)
Options.ZoomOut ();
-
+
this.QueueDraw ();
if (isMouseTrapped)
FireMotionEvent (mx + textViewMargin.XOffset, my, lastState);
return true;
}
+
+ if (!Platform.IsMac) {
+ if ((evnt.State & ModifierType.ShiftMask) == ModifierType.ShiftMask) {
+ if (evnt.Direction == ScrollDirection.Up)
+ HAdjustment.Value += HAdjustment.StepIncrement * 3;
+ else if (evnt.Direction == ScrollDirection.Down)
+ HAdjustment.Value -= HAdjustment.StepIncrement * 3;
+
+ this.QueueDraw ();
+
+ return true;
+ }
+ }
lastScrollTime = evnt.Time;
return base.OnScrollEvent (evnt);
}