Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(520)

Unified Diff: remoting/protocol/mouse_input_filter_unittest.cc

Issue 10255007: Clamp events before they are sent to EventExecutors. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix typo. Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/protocol/mouse_input_filter.cc ('k') | remoting/remoting.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/mouse_input_filter_unittest.cc
diff --git a/remoting/client/mouse_input_filter_unittest.cc b/remoting/protocol/mouse_input_filter_unittest.cc
similarity index 95%
rename from remoting/client/mouse_input_filter_unittest.cc
rename to remoting/protocol/mouse_input_filter_unittest.cc
index 1396cb4ae31e278de1f798883e9678413b05e8a9..376decdef21ba1c897262652117d4d3a0f36e09d 100644
--- a/remoting/client/mouse_input_filter_unittest.cc
+++ b/remoting/protocol/mouse_input_filter_unittest.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "remoting/client/mouse_input_filter.h"
+#include "remoting/protocol/mouse_input_filter.h"
#include "remoting/proto/event.pb.h"
#include "remoting/protocol/protocol_mock_objects.h"
@@ -14,21 +14,20 @@ using ::testing::_;
using ::testing::InSequence;
namespace remoting {
-
-using protocol::MockInputStub;
+namespace protocol {
MATCHER_P2(EqualsMouseMoveEvent, x, y, "") {
return arg.x() == x && arg.y() == y;
}
-static protocol::MouseEvent MouseMoveEvent(int x, int y) {
- protocol::MouseEvent event;
+static MouseEvent MouseMoveEvent(int x, int y) {
+ MouseEvent event;
event.set_x(x);
event.set_y(y);
return event;
}
-static void InjectTestSequence(protocol::InputStub* input_stub) {
+static void InjectTestSequence(InputStub* input_stub) {
static const SkIPoint input_sequence[] = {
{-5, 10}, {0, 10}, {-1, 10}, {15, 40}, {15, 45}, {15, 39}, {15, 25}
};
@@ -162,4 +161,5 @@ TEST(MouseInputFilterTest, DownScalingAndClamping) {
InjectTestSequence(&mouse_filter);
}
+} // namespace protocol
} // namespace remoting
« no previous file with comments | « remoting/protocol/mouse_input_filter.cc ('k') | remoting/remoting.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698