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

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

Issue 23708028: Reduce calling count of UpdateAppState() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 3 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
« chrome/browser/ui/browser.cc ('K') | « chrome/browser/ui/browser.cc ('k') | no next file » | 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) 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_TABS_TAB_STRIP_MODEL_OBSERVER_H_ 5 #ifndef CHROME_BROWSER_UI_TABS_TAB_STRIP_MODEL_OBSERVER_H_
6 #define CHROME_BROWSER_UI_TABS_TAB_STRIP_MODEL_OBSERVER_H_ 6 #define CHROME_BROWSER_UI_TABS_TAB_STRIP_MODEL_OBSERVER_H_
7 7
8 class TabStripModel; 8 class TabStripModel;
9 9
10 namespace content { 10 namespace content {
(...skipping 22 matching lines...) Expand all
33 class TabStripModelObserver { 33 class TabStripModelObserver {
34 public: 34 public:
35 // Enumeration of the possible values supplied to TabChangedAt. 35 // Enumeration of the possible values supplied to TabChangedAt.
36 enum TabChangeType { 36 enum TabChangeType {
37 // Only the loading state changed. 37 // Only the loading state changed.
38 LOADING_ONLY, 38 LOADING_ONLY,
39 39
40 // Only the title changed and page isn't loading. 40 // Only the title changed and page isn't loading.
41 TITLE_NOT_LOADING, 41 TITLE_NOT_LOADING,
42 42
43 // Change not characterized by LOADING_ONLY or TITLE_NOT_LOADING. 43 // Only the url changed and loading state isn't changed.
44 URL_CHANGING_ONLY,
45
46 // Change not characterized by LOADING_ONLY, TITLE_NOT_LOADING or
47 // URL_CHANGING_ONLY.
44 ALL 48 ALL
45 }; 49 };
46 50
47 enum ChangeReason { 51 enum ChangeReason {
48 // Used to indicate that none of the reasons below are responsible for the 52 // Used to indicate that none of the reasons below are responsible for the
49 // active tab change. 53 // active tab change.
50 CHANGE_REASON_NONE = 0, 54 CHANGE_REASON_NONE = 0,
51 // The active tab changed because the tab's web contents was replaced. 55 // The active tab changed because the tab's web contents was replaced.
52 CHANGE_REASON_REPLACED = 1 << 0, 56 CHANGE_REASON_REPLACED = 1 << 0,
53 // The active tab changed due to a user input event. 57 // The active tab changed due to a user input event.
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 152
149 // Sent when the tabstrip model is about to be deleted and any reference held 153 // Sent when the tabstrip model is about to be deleted and any reference held
150 // must be dropped. 154 // must be dropped.
151 virtual void TabStripModelDeleted(); 155 virtual void TabStripModelDeleted();
152 156
153 protected: 157 protected:
154 virtual ~TabStripModelObserver() {} 158 virtual ~TabStripModelObserver() {}
155 }; 159 };
156 160
157 #endif // CHROME_BROWSER_UI_TABS_TAB_STRIP_MODEL_OBSERVER_H_ 161 #endif // CHROME_BROWSER_UI_TABS_TAB_STRIP_MODEL_OBSERVER_H_
OLDNEW
« chrome/browser/ui/browser.cc ('K') | « chrome/browser/ui/browser.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698