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

Unified Diff: athena/main/athena_launcher.cc

Issue 416243004: Enable touch text selection on Athena (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Got rid of windows list in overview mode 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 side-by-side diff with in-line comments
Download patch
Index: athena/main/athena_launcher.cc
diff --git a/athena/main/athena_launcher.cc b/athena/main/athena_launcher.cc
index 5da92745ca6d3341ca24254c67bfc1f4f46c077d..fce418f68ae0eb76bc5a281a44488850934cd834 100644
--- a/athena/main/athena_launcher.cc
+++ b/athena/main/athena_launcher.cc
@@ -13,6 +13,7 @@
#include "athena/wm/public/window_manager.h"
#include "base/memory/scoped_ptr.h"
#include "ui/aura/window_property.h"
+#include "ui/views/views_delegate.h"
#include "ui/wm/core/visibility_controller.h"
#if defined(USE_X11)
@@ -36,12 +37,30 @@ DEFINE_OWNED_WINDOW_PROPERTY_KEY(athena::RootWindowState,
kRootWindowStateKey,
NULL);
+class AthenaViewsDelegate : public views::ViewsDelegate {
+ public:
+ AthenaViewsDelegate() {}
+ virtual ~AthenaViewsDelegate() {}
+
+ private:
+ // views::ViewsDelegate:
+ virtual void OnBeforeWidgetInit(
+ views::Widget::InitParams* params,
+ views::internal::NativeWidgetDelegate* delegate) OVERRIDE {
+ }
+
+ DISALLOW_COPY_AND_ASSIGN(AthenaViewsDelegate);
+};
+
void StartAthena(aura::Window* root_window,
athena::ActivityFactory* activity_factory,
athena::AppModelBuilder* app_model_builder) {
#if defined(USE_X11)
ui::TouchFactory::SetTouchDeviceListFromCommandLine();
#endif
+
+ views::ViewsDelegate::views_delegate = new AthenaViewsDelegate();
+
RootWindowState* root_window_state = new RootWindowState;
root_window->SetProperty(kRootWindowStateKey, root_window_state);
@@ -65,6 +84,8 @@ void ShutdownAthena() {
athena::WindowManager::Shutdown();
athena::ScreenManager::Shutdown();
athena::InputManager::Shutdown();
+
+ delete views::ViewsDelegate::views_delegate;
}
} // namespace athena

Powered by Google App Engine
This is Rietveld 408576698