| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_UI_BROWSER_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_H_ |
| 6 #define CHROME_BROWSER_UI_BROWSER_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 387 void ToggleEncodingAutoDetect(); | 387 void ToggleEncodingAutoDetect(); |
| 388 void OverrideEncoding(int encoding_id); | 388 void OverrideEncoding(int encoding_id); |
| 389 | 389 |
| 390 // Show various bits of UI | 390 // Show various bits of UI |
| 391 void OpenFile(); | 391 void OpenFile(); |
| 392 | 392 |
| 393 void UpdateDownloadShelfVisibility(bool visible); | 393 void UpdateDownloadShelfVisibility(bool visible); |
| 394 | 394 |
| 395 ///////////////////////////////////////////////////////////////////////////// | 395 ///////////////////////////////////////////////////////////////////////////// |
| 396 | 396 |
| 397 // Returns true if we should allow fast shutdown for the given WebContents. |
| 398 static bool CanFastShutdownWebContents(content::WebContents* contents); |
| 399 |
| 397 // Helper function to run unload listeners on a WebContents. | 400 // Helper function to run unload listeners on a WebContents. |
| 398 static bool RunUnloadEventsHelper(content::WebContents* contents); | 401 static bool RunUnloadEventsHelper(content::WebContents* contents); |
| 399 | 402 |
| 400 // Helper function to handle JS out of memory notifications | 403 // Helper function to handle JS out of memory notifications |
| 401 static void JSOutOfMemoryHelper(content::WebContents* web_contents); | 404 static void JSOutOfMemoryHelper(content::WebContents* web_contents); |
| 402 | 405 |
| 403 // Helper function to register a protocol handler. | 406 // Helper function to register a protocol handler. |
| 404 static void RegisterProtocolHandlerHelper(content::WebContents* web_contents, | 407 static void RegisterProtocolHandlerHelper(content::WebContents* web_contents, |
| 405 const std::string& protocol, | 408 const std::string& protocol, |
| 406 const GURL& url, | 409 const GURL& url, |
| (...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 935 | 938 |
| 936 // The following factory is used to close the frame at a later time. | 939 // The following factory is used to close the frame at a later time. |
| 937 base::WeakPtrFactory<Browser> weak_factory_; | 940 base::WeakPtrFactory<Browser> weak_factory_; |
| 938 | 941 |
| 939 scoped_ptr<BrowserLanguageStateObserver> language_state_observer_; | 942 scoped_ptr<BrowserLanguageStateObserver> language_state_observer_; |
| 940 | 943 |
| 941 DISALLOW_COPY_AND_ASSIGN(Browser); | 944 DISALLOW_COPY_AND_ASSIGN(Browser); |
| 942 }; | 945 }; |
| 943 | 946 |
| 944 #endif // CHROME_BROWSER_UI_BROWSER_H_ | 947 #endif // CHROME_BROWSER_UI_BROWSER_H_ |
| OLD | NEW |