| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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_DOM_UI_NEW_TAB_UI_H_ | 5 #ifndef CHROME_BROWSER_DOM_UI_NEW_TAB_UI_H_ |
| 6 #define CHROME_BROWSER_DOM_UI_NEW_TAB_UI_H_ | 6 #define CHROME_BROWSER_DOM_UI_NEW_TAB_UI_H_ |
| 7 | 7 |
| 8 #include "chrome/browser/dom_ui/dom_ui.h" | 8 #include "chrome/browser/dom_ui/dom_ui.h" |
| 9 #include "chrome/common/notification_registrar.h" | 9 #include "chrome/common/notification_registrar.h" |
| 10 | 10 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 ~NewTabUI(); | 24 ~NewTabUI(); |
| 25 | 25 |
| 26 static void RegisterUserPrefs(PrefService* prefs); | 26 static void RegisterUserPrefs(PrefService* prefs); |
| 27 | 27 |
| 28 // Whether we should use the old new tab page. | 28 // Whether we should use the old new tab page. |
| 29 static bool UseOldNewTabPage(); | 29 static bool UseOldNewTabPage(); |
| 30 | 30 |
| 31 // Whether we should disable the web resources backend service | 31 // Whether we should disable the web resources backend service |
| 32 static bool WebResourcesEnabled(); | 32 static bool WebResourcesEnabled(); |
| 33 | 33 |
| 34 private: | 34 // Whether we should disable the first run notification based on the command |
| 35 // line switch. |
| 36 static bool FirstRunDisabled(); |
| 37 |
| 38 private: |
| 35 void Observe(NotificationType type, | 39 void Observe(NotificationType type, |
| 36 const NotificationSource& source, | 40 const NotificationSource& source, |
| 37 const NotificationDetails& details); | 41 const NotificationDetails& details); |
| 38 | 42 |
| 39 NotificationRegistrar registrar_; | 43 NotificationRegistrar registrar_; |
| 40 | 44 |
| 41 // The message id that should be displayed in this NewTabUIContents | 45 // The message id that should be displayed in this NewTabUIContents |
| 42 // instance's motd area. | 46 // instance's motd area. |
| 43 int motd_message_id_; | 47 int motd_message_id_; |
| 44 | 48 |
| 45 // Whether the user is in incognito mode or not, used to determine | 49 // Whether the user is in incognito mode or not, used to determine |
| 46 // what HTML to load. | 50 // what HTML to load. |
| 47 bool incognito_; | 51 bool incognito_; |
| 48 | 52 |
| 49 DISALLOW_COPY_AND_ASSIGN(NewTabUI); | 53 DISALLOW_COPY_AND_ASSIGN(NewTabUI); |
| 50 }; | 54 }; |
| 51 | 55 |
| 52 #endif // CHROME_BROWSER_DOM_UI_NEW_TAB_UI_H_ | 56 #endif // CHROME_BROWSER_DOM_UI_NEW_TAB_UI_H_ |
| OLD | NEW |