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

Side by Side Diff: ash/drag_drop/drag_drop_controller_unittest.cc

Issue 11280290: events: Change gesture-event handler in EventHandler to not return any values. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/drag_drop/drag_drop_controller.cc ('k') | ash/launcher/launcher_button.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/drag_drop/drag_drop_controller.h" 5 #include "ash/drag_drop/drag_drop_controller.h"
6 6
7 #include "ash/drag_drop/drag_image_view.h" 7 #include "ash/drag_drop/drag_image_view.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "ash/test/ash_test_base.h" 9 #include "ash/test/ash_test_base.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 gfx::ImageSkiaRep* image = new gfx::ImageSkiaRep( 78 gfx::ImageSkiaRep* image = new gfx::ImageSkiaRep(
79 gfx::Size(10, 20), ui::SCALE_FACTOR_100P); 79 gfx::Size(10, 20), ui::SCALE_FACTOR_100P);
80 gfx::ImageSkia* image_skia = new gfx::ImageSkia(*image); 80 gfx::ImageSkia* image_skia = new gfx::ImageSkia(*image);
81 provider.set_drag_image(*image_skia); 81 provider.set_drag_image(*image_skia);
82 } 82 }
83 83
84 bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE { 84 bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE {
85 return true; 85 return true;
86 } 86 }
87 87
88 ui::EventResult OnGestureEvent(ui::GestureEvent* event) OVERRIDE { 88 void OnGestureEvent(ui::GestureEvent* event) OVERRIDE {
89 if (event->type() == ui::ET_GESTURE_LONG_TAP) 89 if (event->type() == ui::ET_GESTURE_LONG_TAP)
90 long_tap_received_ = true; 90 long_tap_received_ = true;
91 return ui::ER_UNHANDLED; 91 return;
92 } 92 }
93 93
94 bool GetDropFormats(int* formats, 94 bool GetDropFormats(int* formats,
95 std::set<OSExchangeData::CustomFormat>* custom_formats) { 95 std::set<OSExchangeData::CustomFormat>* custom_formats) {
96 *formats = ui::OSExchangeData::STRING; 96 *formats = ui::OSExchangeData::STRING;
97 return true; 97 return true;
98 } 98 }
99 99
100 bool CanDrop(const OSExchangeData& data) OVERRIDE { 100 bool CanDrop(const OSExchangeData& data) OVERRIDE {
101 return true; 101 return true;
(...skipping 866 matching lines...) Expand 10 before | Expand all | Expand 10 after
968 EXPECT_EQ("405,405", observer.window_location_on_destroying().ToString()); 968 EXPECT_EQ("405,405", observer.window_location_on_destroying().ToString());
969 } 969 }
970 for (Shell::RootWindowList::iterator iter = root_windows.begin(); 970 for (Shell::RootWindowList::iterator iter = root_windows.begin();
971 iter != root_windows.end(); ++iter) { 971 iter != root_windows.end(); ++iter) {
972 aura::client::SetDragDropClient(*iter, NULL); 972 aura::client::SetDragDropClient(*iter, NULL);
973 } 973 }
974 } 974 }
975 975
976 } // namespace test 976 } // namespace test
977 } // namespace aura 977 } // namespace aura
OLDNEW
« no previous file with comments | « ash/drag_drop/drag_drop_controller.cc ('k') | ash/launcher/launcher_button.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698