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

Side by Side Diff: ui/views/test/widget_event_generator_mac.h

Issue 322893005: MacViews: Add WidgetEventGenerator to abstract platform-specific event generation for tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: self review + related fix for r283070 Created 6 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef UI_VIEWS_TEST_WIDGET_EVENT_GENERATOR_MAC_H_
6 #define UI_VIEWS_TEST_WIDGET_EVENT_GENERATOR_MAC_H_
7
8 #include "base/macros.h"
9 #include "ui/events/test/event_generator.h"
10 #include "ui/gfx/native_widget_types.h"
11
12 namespace views {
13 namespace test {
14
15 // Encapsulates event generation for an NSWindow. This is a helper class that
16 // creates a ui::test::EventGeneratorDelegate for the parent EventGenerator,
17 // which returns wrapped EventTargets that redirect events to the NSWindow as
18 // native, NSEvents. Only a single window is supported.
19 class WidgetEventGeneratorMac : public ui::test::EventGenerator {
20 public:
21 explicit WidgetEventGeneratorMac(gfx::NativeWindow ns_window);
22 virtual ~WidgetEventGeneratorMac();
23
24 private:
25 DISALLOW_COPY_AND_ASSIGN(WidgetEventGeneratorMac);
26 };
27
28 } // namespace test
29 } // namespace views
30
31 #endif // UI_VIEWS_TEST_WIDGET_EVENT_GENERATOR_MAC_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698