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

Side by Side Diff: chrome/browser/dom_ui/new_tab_ui.cc

Issue 337034: Remove the browser_sync flag. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 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
OLDNEW
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 543 matching lines...) Expand 10 before | Expand all | Expand 10 after
554 &ChromeURLDataManager::AddDataSource, 554 &ChromeURLDataManager::AddDataSource,
555 html_source)); 555 html_source));
556 } else { 556 } else {
557 AddMessageHandler((new ShownSectionsHandler())->Attach(this)); 557 AddMessageHandler((new ShownSectionsHandler())->Attach(this));
558 AddMessageHandler((new MostVisitedHandler())->Attach(this)); 558 AddMessageHandler((new MostVisitedHandler())->Attach(this));
559 AddMessageHandler((new RecentlyClosedTabsHandler())->Attach(this)); 559 AddMessageHandler((new RecentlyClosedTabsHandler())->Attach(this));
560 AddMessageHandler((new MetricsHandler())->Attach(this)); 560 AddMessageHandler((new MetricsHandler())->Attach(this));
561 if (WebResourcesEnabled()) 561 if (WebResourcesEnabled())
562 AddMessageHandler((new TipsHandler())->Attach(this)); 562 AddMessageHandler((new TipsHandler())->Attach(this));
563 563
564 #if defined(BROWSER_SYNC) && !defined(OS_POSIX) 564 #if !defined(OS_POSIX)
565 if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisableSync)) { 565 if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisableSync)) {
566 AddMessageHandler((new NewTabPageSyncHandler())->Attach(this)); 566 AddMessageHandler((new NewTabPageSyncHandler())->Attach(this));
567 } 567 }
568 #endif 568 #endif
569 569
570 AddMessageHandler((new NewTabPageSetHomepageHandler())->Attach(this)); 570 AddMessageHandler((new NewTabPageSetHomepageHandler())->Attach(this));
571 571
572 // In testing mode there may not be an I/O thread. 572 // In testing mode there may not be an I/O thread.
573 if (g_browser_process->io_thread()) { 573 if (g_browser_process->io_thread()) {
574 InitializeCSSCaches(); 574 InitializeCSSCaches();
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after
906 std::string json_html; 906 std::string json_html;
907 jstemplate_builder::AppendJsonHtml(&localized_strings, &json_html); 907 jstemplate_builder::AppendJsonHtml(&localized_strings, &json_html);
908 908
909 static const std::string template_data_placeholder = 909 static const std::string template_data_placeholder =
910 "<!-- template data placeholder -->"; 910 "<!-- template data placeholder -->";
911 ReplaceFirstSubstringAfterOffset(&full_html_, 0, template_data_placeholder, 911 ReplaceFirstSubstringAfterOffset(&full_html_, 0, template_data_placeholder,
912 json_html); 912 json_html);
913 913
914 jstemplate_builder::AppendI18nTemplateProcessHtml(&full_html_); 914 jstemplate_builder::AppendI18nTemplateProcessHtml(&full_html_);
915 } 915 }
OLDNEW
« no previous file with comments | « chrome/browser/dom_ui/new_tab_page_sync_handler.cc ('k') | chrome/browser/gtk/bookmark_bar_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698