| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 "ui/views/views_delegate.h" | 5 #include "ui/views/views_delegate.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "ui/views/touchui/touch_selection_menu_runner_views.h" |
| 8 #include "ui/views/views_touch_selection_controller_factory.h" | 9 #include "ui/views/views_touch_selection_controller_factory.h" |
| 9 | 10 |
| 10 namespace views { | 11 namespace views { |
| 11 | 12 |
| 12 ViewsDelegate::ViewsDelegate() | 13 ViewsDelegate::ViewsDelegate() |
| 13 : views_tsc_factory_(new ViewsTouchEditingControllerFactory) { | 14 : views_tsc_factory_(new ViewsTouchEditingControllerFactory) { |
| 14 ui::TouchEditingControllerFactory::SetInstance(views_tsc_factory_.get()); | 15 ui::TouchEditingControllerFactory::SetInstance(views_tsc_factory_.get()); |
| 16 |
| 17 #if defined(USE_AURA) |
| 18 touch_selection_menu_runner_.reset(new TouchSelectionMenuRunnerViews()); |
| 19 #endif // defined(USE_AURA) |
| 15 } | 20 } |
| 16 | 21 |
| 17 ViewsDelegate::~ViewsDelegate() { | 22 ViewsDelegate::~ViewsDelegate() { |
| 18 ui::TouchEditingControllerFactory::SetInstance(NULL); | 23 ui::TouchEditingControllerFactory::SetInstance(NULL); |
| 19 } | 24 } |
| 20 | 25 |
| 21 void ViewsDelegate::SaveWindowPlacement(const Widget* widget, | 26 void ViewsDelegate::SaveWindowPlacement(const Widget* widget, |
| 22 const std::string& window_name, | 27 const std::string& window_name, |
| 23 const gfx::Rect& bounds, | 28 const gfx::Rect& bounds, |
| 24 ui::WindowShowState show_state) { | 29 ui::WindowShowState show_state) { |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 } | 97 } |
| 93 | 98 |
| 94 #if defined(OS_WIN) | 99 #if defined(OS_WIN) |
| 95 int ViewsDelegate::GetAppbarAutohideEdges(HMONITOR monitor, | 100 int ViewsDelegate::GetAppbarAutohideEdges(HMONITOR monitor, |
| 96 const base::Closure& callback) { | 101 const base::Closure& callback) { |
| 97 return EDGE_BOTTOM; | 102 return EDGE_BOTTOM; |
| 98 } | 103 } |
| 99 #endif | 104 #endif |
| 100 | 105 |
| 101 } // namespace views | 106 } // namespace views |
| OLD | NEW |