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

Side by Side Diff: content/gpu/gpu_main.cc

Issue 23191007: Make the GPU process use an X11 event loop (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 | « base/message_loop/message_loop.cc ('k') | ui/gl/gl_surface_glx.h » ('j') | 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 <stdlib.h> 5 #include <stdlib.h>
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #endif 9 #endif
10 10
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 base::MessageLoop::Type message_loop_type = base::MessageLoop::TYPE_IO; 137 base::MessageLoop::Type message_loop_type = base::MessageLoop::TYPE_IO;
138 #if defined(OS_WIN) 138 #if defined(OS_WIN)
139 // Unless we're running on desktop GL, we don't need a UI message 139 // Unless we're running on desktop GL, we don't need a UI message
140 // loop, so avoid its use to work around apparent problems with some 140 // loop, so avoid its use to work around apparent problems with some
141 // third-party software. 141 // third-party software.
142 if (command_line.HasSwitch(switches::kUseGL) && 142 if (command_line.HasSwitch(switches::kUseGL) &&
143 command_line.GetSwitchValueASCII(switches::kUseGL) == 143 command_line.GetSwitchValueASCII(switches::kUseGL) ==
144 gfx::kGLImplementationDesktopName) { 144 gfx::kGLImplementationDesktopName) {
145 message_loop_type = base::MessageLoop::TYPE_UI; 145 message_loop_type = base::MessageLoop::TYPE_UI;
146 } 146 }
147 #elif defined(OS_LINUX) && !defined(OS_CHROMEOS)
148 message_loop_type = base::MessageLoop::TYPE_GPU;
147 #elif defined(OS_LINUX) 149 #elif defined(OS_LINUX)
148 message_loop_type = base::MessageLoop::TYPE_DEFAULT; 150 message_loop_type = base::MessageLoop::TYPE_DEFAULT;
149 #endif 151 #endif
150 152
151 base::MessageLoop main_message_loop(message_loop_type); 153 base::MessageLoop main_message_loop(message_loop_type);
152 base::PlatformThread::SetName("CrGpuMain"); 154 base::PlatformThread::SetName("CrGpuMain");
153 155
154 // In addition to disabling the watchdog if the command line switch is 156 // In addition to disabling the watchdog if the command line switch is
155 // present, disable the watchdog on valgrind because the code is expected 157 // present, disable the watchdog on valgrind because the code is expected
156 // to run slowly in that case. 158 // to run slowly in that case.
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after
426 return true; 428 return true;
427 } 429 }
428 430
429 return false; 431 return false;
430 } 432 }
431 #endif // defined(OS_WIN) 433 #endif // defined(OS_WIN)
432 434
433 } // namespace. 435 } // namespace.
434 436
435 } // namespace content 437 } // namespace content
OLDNEW
« no previous file with comments | « base/message_loop/message_loop.cc ('k') | ui/gl/gl_surface_glx.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698