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

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

Issue 8642006: base::bind migrations for browser.cc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/ui/browser.cc » ('j') | chrome/browser/ui/browser.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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>
11 #include <string> 11 #include <string>
12 #include <vector> 12 #include <vector>
13 13
14 #include "base/basictypes.h" 14 #include "base/basictypes.h"
15 #include "base/compiler_specific.h" 15 #include "base/compiler_specific.h"
16 #include "base/gtest_prod_util.h" 16 #include "base/gtest_prod_util.h"
17 #include "base/memory/scoped_ptr.h" 17 #include "base/memory/scoped_ptr.h"
18 #include "base/memory/weak_ptr.h"
18 #include "base/string16.h" 19 #include "base/string16.h"
19 #include "base/task.h"
20 #include "chrome/browser/command_updater.h" 20 #include "chrome/browser/command_updater.h"
21 #include "chrome/browser/debugger/devtools_toggle_action.h" 21 #include "chrome/browser/debugger/devtools_toggle_action.h"
22 #include "chrome/browser/event_disposition.h" 22 #include "chrome/browser/event_disposition.h"
23 #include "chrome/browser/instant/instant_delegate.h" 23 #include "chrome/browser/instant/instant_delegate.h"
24 #include "chrome/browser/prefs/pref_member.h" 24 #include "chrome/browser/prefs/pref_member.h"
25 #include "chrome/browser/prefs/pref_change_registrar.h" 25 #include "chrome/browser/prefs/pref_change_registrar.h"
26 #include "chrome/browser/sessions/session_id.h" 26 #include "chrome/browser/sessions/session_id.h"
27 #include "chrome/browser/sessions/tab_restore_service_observer.h" 27 #include "chrome/browser/sessions/tab_restore_service_observer.h"
28 #include "chrome/browser/sync/profile_sync_service_observer.h" 28 #include "chrome/browser/sync/profile_sync_service_observer.h"
29 #include "chrome/browser/tabs/tab_handler.h" 29 #include "chrome/browser/tabs/tab_handler.h"
(...skipping 1294 matching lines...) Expand 10 before | Expand all | Expand 10 after
1324 1324
1325 typedef std::map<const TabContents*, int> UpdateMap; 1325 typedef std::map<const TabContents*, int> UpdateMap;
1326 1326
1327 // Maps from TabContents to pending UI updates that need to be processed. 1327 // Maps from TabContents to pending UI updates that need to be processed.
1328 // We don't update things like the URL or tab title right away to avoid 1328 // We don't update things like the URL or tab title right away to avoid
1329 // flickering and extra painting. 1329 // flickering and extra painting.
1330 // See ScheduleUIUpdate and ProcessPendingUIUpdates. 1330 // See ScheduleUIUpdate and ProcessPendingUIUpdates.
1331 UpdateMap scheduled_updates_; 1331 UpdateMap scheduled_updates_;
1332 1332
1333 // The following factory is used for chrome update coalescing. 1333 // The following factory is used for chrome update coalescing.
1334 ScopedRunnableMethodFactory<Browser> chrome_updater_factory_; 1334 base::WeakPtrFactory<Browser> chrome_updater_factory_;
James Hawkins 2011/11/22 21:26:30 Why do we need two WeakPtrFactory's? Nevermind, I
1335 1335
1336 // OnBeforeUnload handling ////////////////////////////////////////////////// 1336 // OnBeforeUnload handling //////////////////////////////////////////////////
1337 1337
1338 // Tracks tabs that need there beforeunload event fired before we can 1338 // Tracks tabs that need there beforeunload event fired before we can
1339 // close the browser. Only gets populated when we try to close the browser. 1339 // close the browser. Only gets populated when we try to close the browser.
1340 UnloadListenerSet tabs_needing_before_unload_fired_; 1340 UnloadListenerSet tabs_needing_before_unload_fired_;
1341 1341
1342 // Tracks tabs that need there unload event fired before we can 1342 // Tracks tabs that need there unload event fired before we can
1343 // close the browser. Only gets populated when we try to close the browser. 1343 // close the browser. Only gets populated when we try to close the browser.
1344 UnloadListenerSet tabs_needing_unload_fired_; 1344 UnloadListenerSet tabs_needing_unload_fired_;
(...skipping 23 matching lines...) Expand all
1368 // The default values are typically loaded from local state (last session), 1368 // The default values are typically loaded from local state (last session),
1369 // obtained from the last window of the same type, or obtained from the 1369 // obtained from the last window of the same type, or obtained from the
1370 // shell shortcut's startup info. 1370 // shell shortcut's startup info.
1371 gfx::Rect override_bounds_; 1371 gfx::Rect override_bounds_;
1372 ui::WindowShowState show_state_; 1372 ui::WindowShowState show_state_;
1373 1373
1374 // Tracks when this browser is being created by session restore. 1374 // Tracks when this browser is being created by session restore.
1375 bool is_session_restore_; 1375 bool is_session_restore_;
1376 1376
1377 // The following factory is used to close the frame at a later time. 1377 // The following factory is used to close the frame at a later time.
1378 ScopedRunnableMethodFactory<Browser> method_factory_; 1378 base::WeakPtrFactory<Browser> weak_factory_;
1379 1379
1380 // The Find Bar. This may be NULL if there is no Find Bar, and if it is 1380 // The Find Bar. This may be NULL if there is no Find Bar, and if it is
1381 // non-NULL, it may or may not be visible. 1381 // non-NULL, it may or may not be visible.
1382 scoped_ptr<FindBarController> find_bar_controller_; 1382 scoped_ptr<FindBarController> find_bar_controller_;
1383 1383
1384 // Dialog box used for opening and saving files. 1384 // Dialog box used for opening and saving files.
1385 scoped_refptr<SelectFileDialog> select_file_dialog_; 1385 scoped_refptr<SelectFileDialog> select_file_dialog_;
1386 1386
1387 // Keep track of the encoding auto detect pref. 1387 // Keep track of the encoding auto detect pref.
1388 BooleanPrefMember encoding_auto_detect_; 1388 BooleanPrefMember encoding_auto_detect_;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
1425 1425
1426 scoped_refptr<FullscreenController> fullscreen_controller_; 1426 scoped_refptr<FullscreenController> fullscreen_controller_;
1427 1427
1428 // True if the browser window has been shown at least once. 1428 // True if the browser window has been shown at least once.
1429 bool window_has_shown_; 1429 bool window_has_shown_;
1430 1430
1431 DISALLOW_COPY_AND_ASSIGN(Browser); 1431 DISALLOW_COPY_AND_ASSIGN(Browser);
1432 }; 1432 };
1433 1433
1434 #endif // CHROME_BROWSER_UI_BROWSER_H_ 1434 #endif // CHROME_BROWSER_UI_BROWSER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/browser.cc » ('j') | chrome/browser/ui/browser.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698