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

Side by Side Diff: content/shell/shell_browser_main_parts.cc

Issue 10991038: content-shell: Allow using the mouse the generate touch-events in linux. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 2 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
« no previous file with comments | « no previous file | no next file » | 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 "content/shell/shell_browser_main_parts.h" 5 #include "content/shell/shell_browser_main_parts.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 11 matching lines...) Expand all
22 #include "grit/net_resources.h" 22 #include "grit/net_resources.h"
23 #include "net/base/net_module.h" 23 #include "net/base/net_module.h"
24 #include "net/base/net_util.h" 24 #include "net/base/net_util.h"
25 #include "ui/base/resource/resource_bundle.h" 25 #include "ui/base/resource/resource_bundle.h"
26 26
27 #if defined(OS_ANDROID) 27 #if defined(OS_ANDROID)
28 #include "net/base/network_change_notifier.h" 28 #include "net/base/network_change_notifier.h"
29 #include "net/android/network_change_notifier_factory_android.h" 29 #include "net/android/network_change_notifier_factory_android.h"
30 #endif 30 #endif
31 31
32 #if defined(USE_AURA) && defined(USE_X11)
33 #include "ui/base/touch/touch_factory.h"
34 #endif
35
32 namespace content { 36 namespace content {
33 37
34 namespace { 38 namespace {
35 39
36 static GURL GetStartupURL() { 40 static GURL GetStartupURL() {
37 CommandLine* command_line = CommandLine::ForCurrentProcess(); 41 CommandLine* command_line = CommandLine::ForCurrentProcess();
38 if (command_line->HasSwitch(switches::kContentBrowserTest)) 42 if (command_line->HasSwitch(switches::kContentBrowserTest))
39 return GURL(); 43 return GURL();
40 const CommandLine::StringVector& args = command_line->GetArgs(); 44 const CommandLine::StringVector& args = command_line->GetArgs();
41 45
(...skipping 30 matching lines...) Expand all
72 parameters_(parameters), 76 parameters_(parameters),
73 run_message_loop_(true), 77 run_message_loop_(true),
74 devtools_delegate_(NULL) { 78 devtools_delegate_(NULL) {
75 } 79 }
76 80
77 ShellBrowserMainParts::~ShellBrowserMainParts() { 81 ShellBrowserMainParts::~ShellBrowserMainParts() {
78 } 82 }
79 83
80 #if !defined(OS_MACOSX) 84 #if !defined(OS_MACOSX)
81 void ShellBrowserMainParts::PreMainMessageLoopStart() { 85 void ShellBrowserMainParts::PreMainMessageLoopStart() {
86 #if defined(USE_AURA) && defined(USE_X11)
87 ui::TouchFactory::SetTouchDeviceListFromCommandLine();
88 #endif
82 } 89 }
83 #endif 90 #endif
84 91
85 void ShellBrowserMainParts::PostMainMessageLoopStart() { 92 void ShellBrowserMainParts::PostMainMessageLoopStart() {
86 #if defined(OS_ANDROID) 93 #if defined(OS_ANDROID)
87 MessageLoopForUI::current()->Start(); 94 MessageLoopForUI::current()->Start();
88 #endif 95 #endif
89 } 96 }
90 97
91 void ShellBrowserMainParts::PreEarlyInitialization() { 98 void ShellBrowserMainParts::PreEarlyInitialization() {
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 #if defined(USE_AURA) 153 #if defined(USE_AURA)
147 Shell::PlatformExit(); 154 Shell::PlatformExit();
148 #endif 155 #endif
149 if (devtools_delegate_) 156 if (devtools_delegate_)
150 devtools_delegate_->Stop(); 157 devtools_delegate_->Stop();
151 browser_context_.reset(); 158 browser_context_.reset();
152 off_the_record_browser_context_.reset(); 159 off_the_record_browser_context_.reset();
153 } 160 }
154 161
155 } // namespace 162 } // namespace
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698