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

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

Issue 9428018: Create BaseWindow and ExtensionWindowWrapper for extension API access to Panels (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Address comments. Created 8 years, 10 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 #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 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 #include "content/public/browser/web_contents_delegate.h" 49 #include "content/public/browser/web_contents_delegate.h"
50 #include "content/public/common/page_transition_types.h" 50 #include "content/public/common/page_transition_types.h"
51 #include "content/public/common/page_zoom.h" 51 #include "content/public/common/page_zoom.h"
52 #include "ui/base/ui_base_types.h" 52 #include "ui/base/ui_base_types.h"
53 #include "ui/gfx/rect.h" 53 #include "ui/gfx/rect.h"
54 54
55 class BrowserSyncedWindowDelegate; 55 class BrowserSyncedWindowDelegate;
56 class BrowserTabRestoreServiceDelegate; 56 class BrowserTabRestoreServiceDelegate;
57 class BrowserWindow; 57 class BrowserWindow;
58 class Extension; 58 class Extension;
59 class ExtensionWindowController;
59 class FindBarController; 60 class FindBarController;
60 class FullscreenController; 61 class FullscreenController;
61 class HtmlDialogUIDelegate; 62 class HtmlDialogUIDelegate;
62 class InstantController; 63 class InstantController;
63 class InstantUnloadHandler; 64 class InstantUnloadHandler;
64 class PrefService; 65 class PrefService;
65 class Profile; 66 class Profile;
66 class SessionStorageNamespace; 67 class SessionStorageNamespace;
67 class SkBitmap; 68 class SkBitmap;
68 class StatusBubble; 69 class StatusBubble;
(...skipping 475 matching lines...) Expand 10 before | Expand all | Expand 10 after
544 void MoveTabPrevious(); 545 void MoveTabPrevious();
545 void SelectNumberedTab(int index); 546 void SelectNumberedTab(int index);
546 void SelectLastTab(); 547 void SelectLastTab();
547 void DuplicateTab(); 548 void DuplicateTab();
548 void WriteCurrentURLToClipboard(); 549 void WriteCurrentURLToClipboard();
549 void ConvertPopupToTabbedBrowser(); 550 void ConvertPopupToTabbedBrowser();
550 // In kiosk mode, the first toggle is valid, the rest is discarded. 551 // In kiosk mode, the first toggle is valid, the rest is discarded.
551 void ToggleFullscreenMode(); 552 void ToggleFullscreenMode();
552 // See the description of 553 // See the description of
553 // FullscreenController::ToggleFullscreenModeWithExtension. 554 // FullscreenController::ToggleFullscreenModeWithExtension.
554 void ToggleFullscreenModeWithExtension(const Extension& extension); 555 void ToggleFullscreenModeWithExtension(const GURL& extension_url);
555 #if defined(OS_MACOSX) 556 #if defined(OS_MACOSX)
556 void TogglePresentationMode(); 557 void TogglePresentationMode();
557 #endif 558 #endif
558 void Exit(); 559 void Exit();
559 #if defined(OS_CHROMEOS) 560 #if defined(OS_CHROMEOS)
560 void Search(); 561 void Search();
561 void ShowKeyboardOverlay(); 562 void ShowKeyboardOverlay();
562 #endif 563 #endif
563 564
564 // Page-related commands 565 // Page-related commands
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
878 // True when the current tab is in fullscreen mode, requested by 879 // True when the current tab is in fullscreen mode, requested by
879 // webkitRequestFullScreen. 880 // webkitRequestFullScreen.
880 bool IsFullscreenForTab() const; 881 bool IsFullscreenForTab() const;
881 882
882 // Called each time the browser window is shown. 883 // Called each time the browser window is shown.
883 void OnWindowDidShow(); 884 void OnWindowDidShow();
884 885
885 // Show the first run search engine bubble on the location bar. 886 // Show the first run search engine bubble on the location bar.
886 void ShowFirstRunBubble(); 887 void ShowFirstRunBubble();
887 888
889 ExtensionWindowController* extension_window_controller() const {
890 return extension_window_controller_.get();
891 }
892
888 protected: 893 protected:
889 // Wrapper for the factory method in BrowserWindow. This allows subclasses to 894 // Wrapper for the factory method in BrowserWindow. This allows subclasses to
890 // set their own window. 895 // set their own window.
891 virtual BrowserWindow* CreateBrowserWindow(); 896 virtual BrowserWindow* CreateBrowserWindow();
892 897
893 private: 898 private:
894 FRIEND_TEST_ALL_PREFIXES(AppModeTest, EnableAppModeTest); 899 FRIEND_TEST_ALL_PREFIXES(AppModeTest, EnableAppModeTest);
895 FRIEND_TEST_ALL_PREFIXES(BrowserTest, NoTabsInPopups); 900 FRIEND_TEST_ALL_PREFIXES(BrowserTest, NoTabsInPopups);
896 FRIEND_TEST_ALL_PREFIXES(BrowserTest, ConvertTabToAppShortcut); 901 FRIEND_TEST_ALL_PREFIXES(BrowserTest, ConvertTabToAppShortcut);
897 FRIEND_TEST_ALL_PREFIXES(BrowserTest, OpenAppWindowLikeNtp); 902 FRIEND_TEST_ALL_PREFIXES(BrowserTest, OpenAppWindowLikeNtp);
(...skipping 551 matching lines...) Expand 10 before | Expand all | Expand 10 after
1449 // Helper which implements the SyncedWindowDelegate interface. 1454 // Helper which implements the SyncedWindowDelegate interface.
1450 scoped_ptr<BrowserSyncedWindowDelegate> synced_window_delegate_; 1455 scoped_ptr<BrowserSyncedWindowDelegate> synced_window_delegate_;
1451 1456
1452 scoped_ptr<InstantController> instant_; 1457 scoped_ptr<InstantController> instant_;
1453 scoped_ptr<InstantUnloadHandler> instant_unload_handler_; 1458 scoped_ptr<InstantUnloadHandler> instant_unload_handler_;
1454 1459
1455 BookmarkBar::State bookmark_bar_state_; 1460 BookmarkBar::State bookmark_bar_state_;
1456 1461
1457 scoped_refptr<FullscreenController> fullscreen_controller_; 1462 scoped_refptr<FullscreenController> fullscreen_controller_;
1458 1463
1464 scoped_ptr<ExtensionWindowController> extension_window_controller_;
1465
1459 // True if the browser window has been shown at least once. 1466 // True if the browser window has been shown at least once.
1460 bool window_has_shown_; 1467 bool window_has_shown_;
1461 1468
1462 DISALLOW_COPY_AND_ASSIGN(Browser); 1469 DISALLOW_COPY_AND_ASSIGN(Browser);
1463 }; 1470 };
1464 1471
1465 #endif // CHROME_BROWSER_UI_BROWSER_H_ 1472 #endif // CHROME_BROWSER_UI_BROWSER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698