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

Side by Side Diff: chrome/browser/ui/browser.cc

Issue 9702055: Automated tests for full screen & mouse lock M16 features (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: FileURL & BrowserTest compilation fixes Created 8 years, 9 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 #include "chrome/browser/ui/browser.h" 5 #include "chrome/browser/ui/browser.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #include <shellapi.h> 9 #include <shellapi.h>
10 #endif // OS_WIN 10 #endif // OS_WIN
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after
482 } 482 }
483 483
484 // There may be pending file dialogs, we need to tell them that we've gone 484 // There may be pending file dialogs, we need to tell them that we've gone
485 // away so they don't try and call back to us. 485 // away so they don't try and call back to us.
486 if (select_file_dialog_.get()) 486 if (select_file_dialog_.get())
487 select_file_dialog_->ListenerDestroyed(); 487 select_file_dialog_->ListenerDestroyed();
488 488
489 TabRestoreServiceDestroyed(tab_restore_service_); 489 TabRestoreServiceDestroyed(tab_restore_service_);
490 } 490 }
491 491
492 bool Browser::IsFullscreenForTab() const { 492 bool Browser::IsFullscreenForTabOrPending() const {
493 return fullscreen_controller_->IsFullscreenForTab(); 493 return fullscreen_controller_->IsFullscreenForTabOrPending();
494 }
495
496 bool Browser::IsMouseLockedOrPending() const {
497 return fullscreen_controller_->IsMouseLockedOrPending();
494 } 498 }
495 499
496 // static 500 // static
497 Browser* Browser::Create(Profile* profile) { 501 Browser* Browser::Create(Profile* profile) {
498 Browser* browser = new Browser(TYPE_TABBED, profile); 502 Browser* browser = new Browser(TYPE_TABBED, profile);
499 browser->InitBrowserWindow(); 503 browser->InitBrowserWindow();
500 return browser; 504 return browser;
501 } 505 }
502 506
503 // static 507 // static
(...skipping 3655 matching lines...) Expand 10 before | Expand all | Expand 10 after
4159 void Browser::EnumerateDirectory(WebContents* tab, int request_id, 4163 void Browser::EnumerateDirectory(WebContents* tab, int request_id,
4160 const FilePath& path) { 4164 const FilePath& path) {
4161 EnumerateDirectoryHelper(tab, request_id, path); 4165 EnumerateDirectoryHelper(tab, request_id, path);
4162 } 4166 }
4163 4167
4164 void Browser::ToggleFullscreenModeForTab(WebContents* tab, 4168 void Browser::ToggleFullscreenModeForTab(WebContents* tab,
4165 bool enter_fullscreen) { 4169 bool enter_fullscreen) {
4166 fullscreen_controller_->ToggleFullscreenModeForTab(tab, enter_fullscreen); 4170 fullscreen_controller_->ToggleFullscreenModeForTab(tab, enter_fullscreen);
4167 } 4171 }
4168 4172
4169 bool Browser::IsFullscreenForTab(const WebContents* tab) const { 4173 bool Browser::IsFullscreenForTabOrPending(const WebContents* tab) const {
4170 return fullscreen_controller_->IsFullscreenForTabOrPending(tab); 4174 return fullscreen_controller_->IsFullscreenForTabOrPending(tab);
4171 } 4175 }
4172 4176
4173 void Browser::JSOutOfMemory(WebContents* tab) { 4177 void Browser::JSOutOfMemory(WebContents* tab) {
4174 JSOutOfMemoryHelper(tab); 4178 JSOutOfMemoryHelper(tab);
4175 } 4179 }
4176 4180
4177 void Browser::RegisterProtocolHandler(WebContents* tab, 4181 void Browser::RegisterProtocolHandler(WebContents* tab,
4178 const std::string& protocol, 4182 const std::string& protocol,
4179 const GURL& url, 4183 const GURL& url,
(...skipping 1464 matching lines...) Expand 10 before | Expand all | Expand 10 after
5644 } else { 5648 } else {
5645 LoginUIServiceFactory::GetForProfile( 5649 LoginUIServiceFactory::GetForProfile(
5646 profile()->GetOriginalProfile())->ShowLoginUI(); 5650 profile()->GetOriginalProfile())->ShowLoginUI();
5647 } 5651 }
5648 #endif 5652 #endif
5649 } 5653 }
5650 5654
5651 void Browser::ToggleSpeechInput() { 5655 void Browser::ToggleSpeechInput() {
5652 GetSelectedWebContents()->GetRenderViewHost()->ToggleSpeechInput(); 5656 GetSelectedWebContents()->GetRenderViewHost()->ToggleSpeechInput();
5653 } 5657 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698