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

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

Issue 1640503002: ash: Do not use MessageLoopForUI when not needed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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
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 "ash/shell/content/client/shell_browser_main_parts.h" 5 #include "ash/shell/content/client/shell_browser_main_parts.h"
6 6
7 #include "ash/ash_switches.h" 7 #include "ash/ash_switches.h"
8 #include "ash/content/shell_content_state.h" 8 #include "ash/content/shell_content_state.h"
9 #include "ash/desktop_background/desktop_background_controller.h" 9 #include "ash/desktop_background/desktop_background_controller.h"
10 #include "ash/shell.h" 10 #include "ash/shell.h"
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 views_delegate_.reset(); 163 views_delegate_.reset();
164 164
165 // The keyboard may have created a WebContents. The WebContents is destroyed 165 // The keyboard may have created a WebContents. The WebContents is destroyed
166 // with the UI, and it needs the BrowserContext to be alive during its 166 // with the UI, and it needs the BrowserContext to be alive during its
167 // destruction. So destroy all of the UI elements before destroying the 167 // destruction. So destroy all of the UI elements before destroying the
168 // browser context. 168 // browser context.
169 browser_context_.reset(); 169 browser_context_.reset();
170 } 170 }
171 171
172 bool ShellBrowserMainParts::MainMessageLoopRun(int* result_code) { 172 bool ShellBrowserMainParts::MainMessageLoopRun(int* result_code) {
173 base::MessageLoopForUI::current()->Run(); 173 base::MessageLoop::current()->Run();
174 return true; 174 return true;
175 } 175 }
176 176
177 } // namespace shell 177 } // namespace shell
178 } // namespace ash 178 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698