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

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

Issue 10538039: Renamed BrowserWindow::GetNativeHandle() to GetNativeWindow() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update copyrights Created 8 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
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/file_path.h" 10 #include "base/file_path.h"
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after
711 return service && !service->entries().empty(); 711 return service && !service->entries().empty();
712 } 712 }
713 713
714 // Returns true if there is not a modal window (either window- or application- 714 // Returns true if there is not a modal window (either window- or application-
715 // modal) blocking the active browser. Note that tab modal dialogs (HTTP auth 715 // modal) blocking the active browser. Note that tab modal dialogs (HTTP auth
716 // sheets) will not count as blocking the browser. But things like open/save 716 // sheets) will not count as blocking the browser. But things like open/save
717 // dialogs that are window modal will block the browser. 717 // dialogs that are window modal will block the browser.
718 - (BOOL)keyWindowIsNotModal { 718 - (BOOL)keyWindowIsNotModal {
719 Browser* browser = browser::GetLastActiveBrowser(); 719 Browser* browser = browser::GetLastActiveBrowser();
720 return [NSApp modalWindow] == nil && (!browser || 720 return [NSApp modalWindow] == nil && (!browser ||
721 ![[browser->window()->GetNativeHandle() attachedSheet] 721 ![[browser->window()->GetNativeWindow() attachedSheet]
722 isKindOfClass:[NSWindow class]]); 722 isKindOfClass:[NSWindow class]]);
723 } 723 }
724 724
725 // Called to validate menu items when there are no key windows. All the 725 // Called to validate menu items when there are no key windows. All the
726 // items we care about have been set with the |commandDispatch:| action and 726 // items we care about have been set with the |commandDispatch:| action and
727 // a target of FirstResponder in IB. If it's not one of those, let it 727 // a target of FirstResponder in IB. If it's not one of those, let it
728 // continue up the responder chain to be handled elsewhere. We pull out the 728 // continue up the responder chain to be handled elsewhere. We pull out the
729 // tag as the cross-platform constant to differentiate and dispatch the 729 // tag as the cross-platform constant to differentiate and dispatch the
730 // various commands. 730 // various commands.
731 - (BOOL)validateUserInterfaceItem:(id<NSValidatedUserInterfaceItem>)item { 731 - (BOOL)validateUserInterfaceItem:(id<NSValidatedUserInterfaceItem>)item {
(...skipping 586 matching lines...) Expand 10 before | Expand all | Expand 10 after
1318 1318
1319 } // namespace browser 1319 } // namespace browser
1320 1320
1321 namespace app_controller_mac { 1321 namespace app_controller_mac {
1322 1322
1323 bool IsOpeningNewWindow() { 1323 bool IsOpeningNewWindow() {
1324 return g_is_opening_new_window; 1324 return g_is_opening_new_window;
1325 } 1325 }
1326 1326
1327 } // namespace app_controller_mac 1327 } // namespace app_controller_mac
OLDNEW
« no previous file with comments | « chrome/browser/accessibility/accessibility_win_browsertest.cc ('k') | chrome/browser/automation/automation_provider_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698