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

Side by Side Diff: chrome/browser/app_controller_mac.mm

Issue 14113053: chrome: Use base::MessageLoop. (Part 3) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase again Created 7 years, 6 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 | chrome/browser/autocomplete/autocomplete_provider_unittest.cc » ('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 #import "chrome/browser/app_controller_mac.h" 5 #import "chrome/browser/app_controller_mac.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 817 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 if ([delegate isKindOfClass:[BrowserWindowController class]]) { 828 if ([delegate isKindOfClass:[BrowserWindowController class]]) {
829 [delegate commandDispatch:sender]; 829 [delegate commandDispatch:sender];
830 return; 830 return;
831 } 831 }
832 } 832 }
833 833
834 // Ignore commands during session restore's browser creation. It uses a 834 // Ignore commands during session restore's browser creation. It uses a
835 // nested message loop and commands dispatched during this operation cause 835 // nested message loop and commands dispatched during this operation cause
836 // havoc. 836 // havoc.
837 if (SessionRestore::IsRestoring(lastProfile) && 837 if (SessionRestore::IsRestoring(lastProfile) &&
838 MessageLoop::current()->IsNested()) 838 base::MessageLoop::current()->IsNested())
839 return; 839 return;
840 840
841 NSInteger tag = [sender tag]; 841 NSInteger tag = [sender tag];
842 switch (tag) { 842 switch (tag) {
843 case IDC_NEW_TAB: 843 case IDC_NEW_TAB:
844 // Create a new tab in an existing browser window (which we activate) if 844 // Create a new tab in an existing browser window (which we activate) if
845 // possible. 845 // possible.
846 if (Browser* browser = ActivateBrowser(lastProfile)) { 846 if (Browser* browser = ActivateBrowser(lastProfile)) {
847 chrome::ExecuteCommand(browser, IDC_NEW_TAB); 847 chrome::ExecuteCommand(browser, IDC_NEW_TAB);
848 break; 848 break;
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after
1316 1316
1317 //--------------------------------------------------------------------------- 1317 //---------------------------------------------------------------------------
1318 1318
1319 namespace app_controller_mac { 1319 namespace app_controller_mac {
1320 1320
1321 bool IsOpeningNewWindow() { 1321 bool IsOpeningNewWindow() {
1322 return g_is_opening_new_window; 1322 return g_is_opening_new_window;
1323 } 1323 }
1324 1324
1325 } // namespace app_controller_mac 1325 } // namespace app_controller_mac
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/autocomplete/autocomplete_provider_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698