OLD | NEW |
(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 #include "ui/views/test/widget_event_generator.h" |
| 6 |
| 7 #include "ui/aura/window.h" |
| 8 #include "ui/views/widget.h" |
| 9 |
| 10 namespace views { |
| 11 namespace test { |
| 12 |
| 13 WidgetEventGenerator::WidgetEventGenerator(Widget* widget) |
| 14 : aura::test::EventGenerator(widget->GetNativeView()->GetRootWindow()) { |
| 15 } |
| 16 |
| 17 WidgetEventGenerator::WidgetEventGenerator(gfx::NativeView context) |
| 18 : aura::test::EventGenerator(context) { |
| 19 } |
| 20 |
| 21 WidgetEventGenerator::WidgetEventGenerator( |
| 22 gfx::NativeView context, |
| 23 Widget* window_for_initial_location) |
| 24 : aura::test::EventGenerator(context, window_for_initial_location) { |
| 25 } |
| 26 |
| 27 WidgetEventGenerator::~WidgetEventGenerator() { |
| 28 } |
| 29 |
| 30 // static |
| 31 WidgetEventGenerator::SimulateNativeDestroy(Widget* widget) { |
| 32 delete widget->GetNativeView(); |
| 33 } |
| 34 |
| 35 } // namespace views |
| 36 } // namespace test |
OLD | NEW |