| OLD | NEW |
| 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_GOOGLE_GOOGLE_URL_TRACKER_H_ | 5 #ifndef CHROME_BROWSER_GOOGLE_GOOGLE_URL_TRACKER_H_ |
| 6 #define CHROME_BROWSER_GOOGLE_GOOGLE_URL_TRACKER_H_ | 6 #define CHROME_BROWSER_GOOGLE_GOOGLE_URL_TRACKER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 bool queue_wakeup_task_; | 141 bool queue_wakeup_task_; |
| 142 bool in_startup_sleep_; // True if we're in the five-second "no fetching" | 142 bool in_startup_sleep_; // True if we're in the five-second "no fetching" |
| 143 // period that begins at browser start. | 143 // period that begins at browser start. |
| 144 bool already_fetched_; // True if we've already fetched a URL once this run; | 144 bool already_fetched_; // True if we've already fetched a URL once this run; |
| 145 // we won't fetch again until after a restart. | 145 // we won't fetch again until after a restart. |
| 146 bool need_to_fetch_; // True if a consumer actually wants us to fetch an | 146 bool need_to_fetch_; // True if a consumer actually wants us to fetch an |
| 147 // updated URL. If this is never set, we won't | 147 // updated URL. If this is never set, we won't |
| 148 // bother to fetch anything. | 148 // bother to fetch anything. |
| 149 // Consumers should observe | 149 // Consumers should observe |
| 150 // NotificationType::GOOGLE_URL_UPDATED. | 150 // NotificationType::GOOGLE_URL_UPDATED. |
| 151 bool request_context_available_; | |
| 152 // True when the profile has been loaded and the | |
| 153 // default request context created, so we can | |
| 154 // actually do the fetch with the right data. | |
| 155 bool need_to_prompt_; // True if the last fetched Google URL is not | 151 bool need_to_prompt_; // True if the last fetched Google URL is not |
| 156 // matched with current user's default Google URL | 152 // matched with current user's default Google URL |
| 157 // nor the last prompted Google URL. | 153 // nor the last prompted Google URL. |
| 158 NavigationController* controller_; | 154 NavigationController* controller_; |
| 159 InfoBarDelegate* infobar_; | 155 InfoBarDelegate* infobar_; |
| 160 GURL search_url_; | 156 GURL search_url_; |
| 161 | 157 |
| 162 DISALLOW_COPY_AND_ASSIGN(GoogleURLTracker); | 158 DISALLOW_COPY_AND_ASSIGN(GoogleURLTracker); |
| 163 }; | 159 }; |
| 164 | 160 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 184 | 180 |
| 185 private: | 181 private: |
| 186 // ConfirmInfoBarDelegate: | 182 // ConfirmInfoBarDelegate: |
| 187 virtual string16 GetMessageText() const; | 183 virtual string16 GetMessageText() const; |
| 188 virtual string16 GetButtonLabel(InfoBarButton button) const; | 184 virtual string16 GetButtonLabel(InfoBarButton button) const; |
| 189 | 185 |
| 190 DISALLOW_COPY_AND_ASSIGN(GoogleURLTrackerInfoBarDelegate); | 186 DISALLOW_COPY_AND_ASSIGN(GoogleURLTrackerInfoBarDelegate); |
| 191 }; | 187 }; |
| 192 | 188 |
| 193 #endif // CHROME_BROWSER_GOOGLE_GOOGLE_URL_TRACKER_H_ | 189 #endif // CHROME_BROWSER_GOOGLE_GOOGLE_URL_TRACKER_H_ |
| OLD | NEW |