summaryrefslogtreecommitdiff
path: root/src/activity_replay.cc
diff options
context:
space:
mode:
authorDennis Kempin <denniskempin@chromium.org>2014-02-21 14:17:16 -0800
committerchrome-internal-fetch <chrome-internal-fetch@google.com>2014-03-21 23:50:39 +0000
commit9c3a44270c16d3b704036195bc20887a6568e463 (patch)
tree6f3e142b3a0e2087fc1f246b7405c4662385f279 /src/activity_replay.cc
parent9140692bb5600112299d3104fba8891926f7df1a (diff)
downloadlibchrome-gestures-9c3a44270c16d3b704036195bc20887a6568e463.tar.gz
MouseInterpreter: Add scroll wheel emulation
For mice that do not have a scroll wheel we can now emulate scrolling by pressing the middle button and moving the mouse. This feature is automatically enabled for mice not reporting REL_WHEEL or REL_HWHEEL. For other devices this feature can be enabled with a property. BUG=chromium:285663 TEST=Ideally to be tested on Stout. Test with an old mouse that does not have a scroll wheel, as well as with the built in trackpoint. Middle clicking should still work. Change-Id: I7390075a013a3f711f7d32e209dac8404687f341 Reviewed-on: https://chromium-review.googlesource.com/187457 Commit-Queue: Dennis Kempin <denniskempin@chromium.org> Tested-by: Dennis Kempin <denniskempin@chromium.org> Reviewed-by: Dennis Kempin <denniskempin@chromium.org>
Diffstat (limited to 'src/activity_replay.cc')
-rwxr-xr-x[-rw-r--r--]src/activity_replay.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/activity_replay.cc b/src/activity_replay.cc
index 2ed8eda..72400c6 100644..100755
--- a/src/activity_replay.cc
+++ b/src/activity_replay.cc
@@ -166,6 +166,8 @@ bool ActivityReplay::ParseHardwareProperties(DictionaryValue* obj,
props.support_semi_mt, bool, true);
PARSE_HP(obj, ActivityLog::kKeyHardwarePropIsButtonPad, bool, GetBoolean,
props.is_button_pad, bool, true);
+ PARSE_HP(obj, ActivityLog::kKeyHardwarePropHasWheel, bool, GetBoolean,
+ props.has_wheel, bool, true);
*out_props = props;
return true;
}