OLD | NEW |
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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 #include "build/build_config.h" | 5 #include "build/build_config.h" |
6 | 6 |
7 #include "chrome/browser/dom_ui/new_tab_ui.h" | 7 #include "chrome/browser/dom_ui/new_tab_ui.h" |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 | 10 |
(...skipping 18 matching lines...) Expand all Loading... |
29 #include "chrome/browser/history/page_usage_data.h" | 29 #include "chrome/browser/history/page_usage_data.h" |
30 #include "chrome/browser/metrics/user_metrics.h" | 30 #include "chrome/browser/metrics/user_metrics.h" |
31 #include "chrome/browser/profile.h" | 31 #include "chrome/browser/profile.h" |
32 #include "chrome/browser/renderer_host/render_view_host.h" | 32 #include "chrome/browser/renderer_host/render_view_host.h" |
33 #include "chrome/browser/search_engines/template_url_model.h" | 33 #include "chrome/browser/search_engines/template_url_model.h" |
34 #include "chrome/browser/sessions/session_types.h" | 34 #include "chrome/browser/sessions/session_types.h" |
35 #include "chrome/browser/tab_contents/navigation_entry.h" | 35 #include "chrome/browser/tab_contents/navigation_entry.h" |
36 #include "chrome/browser/tab_contents/tab_contents.h" | 36 #include "chrome/browser/tab_contents/tab_contents.h" |
37 #include "chrome/browser/search_engines/template_url.h" | 37 #include "chrome/browser/search_engines/template_url.h" |
38 #include "chrome/browser/sessions/tab_restore_service.h" | 38 #include "chrome/browser/sessions/tab_restore_service.h" |
| 39 #ifdef CHROME_PERSONALIZATION |
| 40 #include "chrome/browser/sync/personalization.h" |
| 41 #endif |
39 #include "chrome/browser/user_data_manager.h" | 42 #include "chrome/browser/user_data_manager.h" |
40 #include "chrome/common/chrome_switches.h" | 43 #include "chrome/common/chrome_switches.h" |
41 #include "chrome/common/jstemplate_builder.h" | 44 #include "chrome/common/jstemplate_builder.h" |
42 #include "chrome/common/notification_service.h" | 45 #include "chrome/common/notification_service.h" |
43 #include "chrome/common/pref_names.h" | 46 #include "chrome/common/pref_names.h" |
44 #include "chrome/common/pref_service.h" | 47 #include "chrome/common/pref_service.h" |
45 #include "chrome/common/url_constants.h" | 48 #include "chrome/common/url_constants.h" |
46 #ifdef CHROME_PERSONALIZATION | |
47 #include "chrome/personalization/personalization.h" | |
48 #endif | |
49 #include "grit/browser_resources.h" | 49 #include "grit/browser_resources.h" |
50 #include "grit/chromium_strings.h" | 50 #include "grit/chromium_strings.h" |
51 #include "grit/generated_resources.h" | 51 #include "grit/generated_resources.h" |
52 #include "grit/locale_settings.h" | 52 #include "grit/locale_settings.h" |
53 | 53 |
54 namespace { | 54 namespace { |
55 | 55 |
56 // The number of most visited pages we show. | 56 // The number of most visited pages we show. |
57 const size_t kMostVisitedPages = 8; | 57 const size_t kMostVisitedPages = 8; |
58 | 58 |
(...skipping 1565 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1624 bool NewTabUI::WebResourcesEnabled() { | 1624 bool NewTabUI::WebResourcesEnabled() { |
1625 const CommandLine* command_line = CommandLine::ForCurrentProcess(); | 1625 const CommandLine* command_line = CommandLine::ForCurrentProcess(); |
1626 return command_line->HasSwitch(switches::kEnableWebResources); | 1626 return command_line->HasSwitch(switches::kEnableWebResources); |
1627 } | 1627 } |
1628 | 1628 |
1629 // static | 1629 // static |
1630 bool NewTabUI::FirstRunDisabled() { | 1630 bool NewTabUI::FirstRunDisabled() { |
1631 const CommandLine* command_line = CommandLine::ForCurrentProcess(); | 1631 const CommandLine* command_line = CommandLine::ForCurrentProcess(); |
1632 return command_line->HasSwitch(switches::kDisableNewTabFirstRun); | 1632 return command_line->HasSwitch(switches::kDisableNewTabFirstRun); |
1633 } | 1633 } |
OLD | NEW |