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

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

Issue 3129003: remove toolstrips (Closed)
Patch Set: merge Created 10 years, 4 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
« no previous file with comments | « chrome/app/chrome_dll_resource.h ('k') | chrome/browser/browser.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_BROWSER_H_ 5 #ifndef CHROME_BROWSER_BROWSER_H_
6 #define CHROME_BROWSER_BROWSER_H_ 6 #define CHROME_BROWSER_BROWSER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 14 matching lines...) Expand all
25 #include "chrome/browser/tab_contents/tab_contents_delegate.h" 25 #include "chrome/browser/tab_contents/tab_contents_delegate.h"
26 #include "chrome/browser/toolbar_model.h" 26 #include "chrome/browser/toolbar_model.h"
27 #include "chrome/common/extensions/extension.h" 27 #include "chrome/common/extensions/extension.h"
28 #include "chrome/common/notification_registrar.h" 28 #include "chrome/common/notification_registrar.h"
29 #include "chrome/common/page_transition_types.h" 29 #include "chrome/common/page_transition_types.h"
30 #include "chrome/common/page_zoom.h" 30 #include "chrome/common/page_zoom.h"
31 #include "gfx/rect.h" 31 #include "gfx/rect.h"
32 32
33 class BrowserWindow; 33 class BrowserWindow;
34 class Extension; 34 class Extension;
35 class ExtensionShelfModel;
36 class FindBarController; 35 class FindBarController;
37 class PrefService; 36 class PrefService;
38 class Profile; 37 class Profile;
39 class SkBitmap; 38 class SkBitmap;
40 class StatusBubble; 39 class StatusBubble;
41 class TabNavigation; 40 class TabNavigation;
42 namespace gfx { 41 namespace gfx {
43 class Point; 42 class Point;
44 } 43 }
45 44
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 79
81 // Possible elements of the Browser window. 80 // Possible elements of the Browser window.
82 enum WindowFeature { 81 enum WindowFeature {
83 FEATURE_NONE = 0, 82 FEATURE_NONE = 0,
84 FEATURE_TITLEBAR = 1, 83 FEATURE_TITLEBAR = 1,
85 FEATURE_TABSTRIP = 2, 84 FEATURE_TABSTRIP = 2,
86 FEATURE_TOOLBAR = 4, 85 FEATURE_TOOLBAR = 4,
87 FEATURE_LOCATIONBAR = 8, 86 FEATURE_LOCATIONBAR = 8,
88 FEATURE_BOOKMARKBAR = 16, 87 FEATURE_BOOKMARKBAR = 16,
89 FEATURE_INFOBAR = 32, 88 FEATURE_INFOBAR = 32,
90 FEATURE_DOWNLOADSHELF = 64, 89 FEATURE_DOWNLOADSHELF = 64
91 FEATURE_EXTENSIONSHELF = 128
92 }; 90 };
93 91
94 // Maximized state on creation. 92 // Maximized state on creation.
95 enum MaximizedState { 93 enum MaximizedState {
96 // The maximized state is set to the default, which varies depending upon 94 // The maximized state is set to the default, which varies depending upon
97 // what the user has done. 95 // what the user has done.
98 MAXIMIZED_STATE_DEFAULT, 96 MAXIMIZED_STATE_DEFAULT,
99 97
100 // Maximized state is explicitly maximized. 98 // Maximized state is explicitly maximized.
101 MAXIMIZED_STATE_MAXIMIZED, 99 MAXIMIZED_STATE_MAXIMIZED,
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 void set_window(BrowserWindow* window) { 166 void set_window(BrowserWindow* window) {
169 DCHECK(!window_); 167 DCHECK(!window_);
170 window_ = window; 168 window_ = window;
171 } 169 }
172 #endif 170 #endif
173 171
174 BrowserWindow* window() const { return window_; } 172 BrowserWindow* window() const { return window_; }
175 ToolbarModel* toolbar_model() { return &toolbar_model_; } 173 ToolbarModel* toolbar_model() { return &toolbar_model_; }
176 const SessionID& session_id() const { return session_id_; } 174 const SessionID& session_id() const { return session_id_; }
177 CommandUpdater* command_updater() { return &command_updater_; } 175 CommandUpdater* command_updater() { return &command_updater_; }
178 ExtensionShelfModel* extension_shelf_model() {
179 return extension_shelf_model_.get();
180 }
181 176
182 // Get the FindBarController for this browser, creating it if it does not 177 // Get the FindBarController for this browser, creating it if it does not
183 // yet exist. 178 // yet exist.
184 FindBarController* GetFindBarController(); 179 FindBarController* GetFindBarController();
185 180
186 // Returns true if a FindBarController exists for this browser. 181 // Returns true if a FindBarController exists for this browser.
187 bool HasFindBarController() const; 182 bool HasFindBarController() const;
188 183
189 // Setters ///////////////////////////////////////////////////////////////// 184 // Setters /////////////////////////////////////////////////////////////////
190 185
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 void BrowserShowHtmlDialog(HtmlDialogUIDelegate* delegate, 372 void BrowserShowHtmlDialog(HtmlDialogUIDelegate* delegate,
378 gfx::NativeWindow parent_window); 373 gfx::NativeWindow parent_window);
379 374
380 // Called when a popup select is about to be displayed. 375 // Called when a popup select is about to be displayed.
381 void BrowserRenderWidgetShowing(); 376 void BrowserRenderWidgetShowing();
382 377
383 // Notification that some of our content has changed size as 378 // Notification that some of our content has changed size as
384 // part of an animation. 379 // part of an animation.
385 void ToolbarSizeChanged(bool is_animating); 380 void ToolbarSizeChanged(bool is_animating);
386 381
387 // Notification that the extension shelf has changed size (as a result of
388 // becoming detached or attached).
389 void ExtensionShelfSizeChanged();
390
391 // Replaces the state of the currently selected tab with the session 382 // Replaces the state of the currently selected tab with the session
392 // history restored from the SessionRestore system. 383 // history restored from the SessionRestore system.
393 void ReplaceRestoredTab( 384 void ReplaceRestoredTab(
394 const std::vector<TabNavigation>& navigations, 385 const std::vector<TabNavigation>& navigations,
395 int selected_navigation, 386 int selected_navigation,
396 bool from_last_session, 387 bool from_last_session,
397 const std::string& extension_app_id); 388 const std::string& extension_app_id);
398 389
399 // Navigate to an index in the tab history, opening a new tab depending on the 390 // Navigate to an index in the tab history, opening a new tab depending on the
400 // disposition. 391 // disposition.
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
501 void FocusPreviousPane(); 492 void FocusPreviousPane();
502 493
503 // Show various bits of UI 494 // Show various bits of UI
504 void OpenFile(); 495 void OpenFile();
505 void OpenCreateShortcutsDialog(); 496 void OpenCreateShortcutsDialog();
506 void ToggleDevToolsWindow(DevToolsToggleAction action); 497 void ToggleDevToolsWindow(DevToolsToggleAction action);
507 void OpenTaskManager(); 498 void OpenTaskManager();
508 void OpenBugReportDialog(); 499 void OpenBugReportDialog();
509 500
510 void ToggleBookmarkBar(); 501 void ToggleBookmarkBar();
511 void ToggleExtensionShelf();
512 502
513 void OpenBookmarkManager(); 503 void OpenBookmarkManager();
514 void ShowAppMenu(); 504 void ShowAppMenu();
515 void ShowBookmarkManagerTab(); 505 void ShowBookmarkManagerTab();
516 void ShowHistoryTab(); 506 void ShowHistoryTab();
517 void ShowDownloadsTab(); 507 void ShowDownloadsTab();
518 void ShowExtensionsTab(); 508 void ShowExtensionsTab();
519 void ShowBrokenPageTab(TabContents* contents); 509 void ShowBrokenPageTab(TabContents* contents);
520 void ShowOptionsTab(); 510 void ShowOptionsTab();
521 void OpenClearBrowsingDataDialog(); 511 void OpenClearBrowsingDataDialog();
(...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after
978 std::string app_name_; 968 std::string app_name_;
979 969
980 // Unique identifier of this browser for session restore. This id is only 970 // Unique identifier of this browser for session restore. This id is only
981 // unique within the current session, and is not guaranteed to be unique 971 // unique within the current session, and is not guaranteed to be unique
982 // across sessions. 972 // across sessions.
983 const SessionID session_id_; 973 const SessionID session_id_;
984 974
985 // The model for the toolbar view. 975 // The model for the toolbar view.
986 ToolbarModel toolbar_model_; 976 ToolbarModel toolbar_model_;
987 977
988 // The model for the extension shelf.
989 scoped_ptr<ExtensionShelfModel> extension_shelf_model_;
990
991 // UI update coalescing and handling //////////////////////////////////////// 978 // UI update coalescing and handling ////////////////////////////////////////
992 979
993 typedef std::map<const TabContents*, int> UpdateMap; 980 typedef std::map<const TabContents*, int> UpdateMap;
994 981
995 // Maps from TabContents to pending UI updates that need to be processed. 982 // Maps from TabContents to pending UI updates that need to be processed.
996 // We don't update things like the URL or tab title right away to avoid 983 // We don't update things like the URL or tab title right away to avoid
997 // flickering and extra painting. 984 // flickering and extra painting.
998 // See ScheduleUIUpdate and ProcessPendingUIUpdates. 985 // See ScheduleUIUpdate and ProcessPendingUIUpdates.
999 UpdateMap scheduled_updates_; 986 UpdateMap scheduled_updates_;
1000 987
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
1079 mutable BooleanPrefMember use_vertical_tabs_; 1066 mutable BooleanPrefMember use_vertical_tabs_;
1080 1067
1081 // The profile's tab restore service. The service is owned by the profile, 1068 // The profile's tab restore service. The service is owned by the profile,
1082 // and we install ourselves as an observer. 1069 // and we install ourselves as an observer.
1083 TabRestoreService* tab_restore_service_; 1070 TabRestoreService* tab_restore_service_;
1084 1071
1085 DISALLOW_COPY_AND_ASSIGN(Browser); 1072 DISALLOW_COPY_AND_ASSIGN(Browser);
1086 }; 1073 };
1087 1074
1088 #endif // CHROME_BROWSER_BROWSER_H_ 1075 #endif // CHROME_BROWSER_BROWSER_H_
OLDNEW
« no previous file with comments | « chrome/app/chrome_dll_resource.h ('k') | chrome/browser/browser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698