summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/browser/automation/automation_profile_impl.h4
-rw-r--r--chrome/browser/browser.cc6
-rw-r--r--chrome/browser/browser.h2
-rw-r--r--chrome/browser/browser_about_handler.cc6
-rw-r--r--chrome/browser/dom_ui/new_tab_page_sync_handler.cc4
-rw-r--r--chrome/browser/dom_ui/new_tab_page_sync_handler.h3
-rw-r--r--chrome/browser/dom_ui/new_tab_ui.cc2
-rw-r--r--chrome/browser/gtk/bookmark_bar_gtk.cc10
-rw-r--r--chrome/browser/gtk/bookmark_bar_gtk.h6
-rw-r--r--chrome/browser/gtk/standard_menus.cc2
-rw-r--r--chrome/browser/profile.cc6
-rw-r--r--chrome/browser/profile.h2
-rw-r--r--chrome/browser/sync/glue/bookmark_model_worker.cc4
-rw-r--r--chrome/browser/sync/glue/bookmark_model_worker.h4
-rw-r--r--chrome/browser/sync/glue/bookmark_model_worker_unittest.cc3
-rw-r--r--chrome/browser/sync/glue/change_processor.cc4
-rw-r--r--chrome/browser/sync/glue/change_processor.h4
-rw-r--r--chrome/browser/sync/glue/http_bridge.cc4
-rw-r--r--chrome/browser/sync/glue/http_bridge.h4
-rw-r--r--chrome/browser/sync/glue/http_bridge_unittest.cc4
-rw-r--r--chrome/browser/sync/glue/model_associator.cc4
-rw-r--r--chrome/browser/sync/glue/model_associator.h3
-rw-r--r--chrome/browser/sync/glue/sync_backend_host.cc4
-rw-r--r--chrome/browser/sync/glue/sync_backend_host.h3
-rw-r--r--chrome/browser/sync/profile_sync_service.cc5
-rw-r--r--chrome/browser/sync/profile_sync_service.h4
-rw-r--r--chrome/browser/sync/profile_sync_service_unittest.cc4
-rw-r--r--chrome/browser/sync/sync_setup_flow.cc4
-rw-r--r--chrome/browser/sync/sync_setup_flow.h3
-rw-r--r--chrome/browser/sync/sync_setup_wizard.cc4
-rw-r--r--chrome/browser/sync/sync_setup_wizard_unittest.cc4
-rw-r--r--chrome/browser/sync/sync_status_ui_helper.cc4
-rw-r--r--chrome/browser/sync/sync_status_ui_helper.h3
-rw-r--r--chrome/browser/views/bookmark_bar_view.cc28
-rw-r--r--chrome/browser/views/bookmark_bar_view.h9
-rw-r--r--chrome/browser/views/bookmark_manager_view.cc16
-rw-r--r--chrome/browser/views/bookmark_manager_view.h10
-rw-r--r--chrome/browser/views/options/content_page_view.cc25
-rw-r--r--chrome/browser/views/options/content_page_view.h12
-rw-r--r--chrome/browser/views/toolbar_view.cc2
-rwxr-xr-xchrome/chrome.gyp828
-rw-r--r--chrome/test/live_sync/bookmark_model_verifier.cc4
-rw-r--r--chrome/test/live_sync/bookmark_model_verifier.h4
-rw-r--r--chrome/test/live_sync/live_bookmarks_sync_test.cc3
-rw-r--r--chrome/test/live_sync/live_bookmarks_sync_test.h4
-rw-r--r--chrome/test/live_sync/profile_sync_service_test_harness.cc3
-rw-r--r--chrome/test/live_sync/profile_sync_service_test_harness.h3
-rw-r--r--chrome/test/live_sync/single_client_live_bookmarks_sync_unittest.cc4
-rw-r--r--chrome/test/live_sync/two_client_live_bookmarks_sync_test.cc5
-rw-r--r--chrome/test/sync/test_http_bridge_factory.h4
-rw-r--r--chrome/test/testing_profile.cc5
-rw-r--r--chrome/test/testing_profile.h2
52 files changed, 410 insertions, 694 deletions
diff --git a/chrome/browser/automation/automation_profile_impl.h b/chrome/browser/automation/automation_profile_impl.h
index b549aca..77401dc 100644
--- a/chrome/browser/automation/automation_profile_impl.h
+++ b/chrome/browser/automation/automation_profile_impl.h
@@ -174,13 +174,9 @@ class AutomationProfileImpl : public Profile {
virtual DesktopNotificationService* GetDesktopNotificationService() {
return original_profile_->GetDesktopNotificationService();
}
-
-#if defined(BROWSER_SYNC)
virtual ProfileSyncService* GetProfileSyncService() {
return original_profile_->GetProfileSyncService();
}
-#endif
-
virtual bool IsSameProfile(Profile* profile) {
return original_profile_->IsSameProfile(profile);
}
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc
index 934ba8e..292cea5 100644
--- a/chrome/browser/browser.cc
+++ b/chrome/browser/browser.cc
@@ -653,11 +653,9 @@ void Browser::UpdateCommandsForFullscreenMode(bool is_fullscreen) {
command_updater_.UpdateCommandEnabled(IDC_REPORT_BUG, show_main_ui);
command_updater_.UpdateCommandEnabled(IDC_SHOW_BOOKMARK_BAR, show_main_ui);
command_updater_.UpdateCommandEnabled(IDC_IMPORT_SETTINGS, show_main_ui);
-#if defined(BROWSER_SYNC)
command_updater_.UpdateCommandEnabled(
IDC_SYNC_BOOKMARKS,
show_main_ui && profile_->GetProfileSyncService() != NULL);
-#endif
command_updater_.UpdateCommandEnabled(IDC_OPTIONS, show_main_ui);
command_updater_.UpdateCommandEnabled(IDC_EDIT_SEARCH_ENGINES, show_main_ui);
command_updater_.UpdateCommandEnabled(IDC_VIEW_PASSWORDS, show_main_ui);
@@ -1202,7 +1200,6 @@ void Browser::OpenImportSettingsDialog() {
window_->ShowImportDialog();
}
-#if defined(BROWSER_SYNC)
void Browser::OpenSyncMyBookmarksDialog() {
ProfileSyncService* service = profile_->GetProfileSyncService();
// TODO(timsteele): Incognito has no sync service for the time being,
@@ -1216,7 +1213,6 @@ void Browser::OpenSyncMyBookmarksDialog() {
ProfileSyncService::SyncEvent(ProfileSyncService::START_FROM_WRENCH);
}
}
-#endif // defined(BROWSER_SYNC)
void Browser::OpenAboutChromeDialog() {
UserMetrics::RecordAction(L"AboutChrome", profile_);
@@ -1462,9 +1458,7 @@ void Browser::ExecuteCommandWithDisposition(
case IDC_SHOW_DOWNLOADS: ShowDownloadsTab(); break;
case IDC_SHOW_APP_MENU: ShowAppMenu(); break;
case IDC_SHOW_PAGE_MENU: ShowPageMenu(); break;
-#if defined(BROWSER_SYNC)
case IDC_SYNC_BOOKMARKS: OpenSyncMyBookmarksDialog(); break;
-#endif
case IDC_OPTIONS: OpenOptionsDialog(); break;
case IDC_EDIT_SEARCH_ENGINES: OpenKeywordEditor(); break;
case IDC_VIEW_PASSWORDS: OpenPasswordManager(); break;
diff --git a/chrome/browser/browser.h b/chrome/browser/browser.h
index 73852e1..c7d91e4 100644
--- a/chrome/browser/browser.h
+++ b/chrome/browser/browser.h
@@ -401,9 +401,7 @@ class Browser : public TabStripModelDelegate,
void OpenOptionsDialog();
void OpenKeywordEditor();
void OpenPasswordManager();
-#if defined(BROWSER_SYNC)
void OpenSyncMyBookmarksDialog();
-#endif
void OpenImportSettingsDialog();
void OpenAboutChromeDialog();
void OpenHelpTab();
diff --git a/chrome/browser/browser_about_handler.cc b/chrome/browser/browser_about_handler.cc
index 9a9e94b..eb5e3a3 100644
--- a/chrome/browser/browser_about_handler.cc
+++ b/chrome/browser/browser_about_handler.cc
@@ -61,9 +61,7 @@
#include "third_party/tcmalloc/tcmalloc/src/google/malloc_extension.h"
#endif
-#if defined(BROWSER_SYNC)
using sync_api::SyncManager;
-#endif
using base::Time;
using base::TimeDelta;
@@ -469,7 +467,6 @@ std::string AboutVersion(DictionaryValue* localized_strings) {
return output;
}
-#if defined(BROWSER_SYNC)
static void AddBoolSyncDetail(ListValue* details, const std::wstring& stat_name,
bool stat_value) {
DictionaryValue* val = new DictionaryValue;
@@ -560,7 +557,6 @@ std::string AboutSync() {
return jstemplate_builder::GetTemplateHtml(
sync_html, &strings , "t" /* template root node id */);
}
-#endif // defined(BROWSER_SYNC)
// AboutSource -----------------------------------------------------------------
@@ -624,9 +620,7 @@ void AboutSource::StartDataRequest(const std::string& path_raw,
} else if (path == kTermsPath) {
response = AboutTerms();
} else if (path == kSyncPath) {
-#if defined(BROWSER_SYNC)
response = AboutSync();
-#endif
}
FinishDataRequest(response, request_id);
diff --git a/chrome/browser/dom_ui/new_tab_page_sync_handler.cc b/chrome/browser/dom_ui/new_tab_page_sync_handler.cc
index c792445..3a05ed1 100644
--- a/chrome/browser/dom_ui/new_tab_page_sync_handler.cc
+++ b/chrome/browser/dom_ui/new_tab_page_sync_handler.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/dom_ui/new_tab_page_sync_handler.h"
#include "app/l10n_util.h"
@@ -227,5 +225,3 @@ void NewTabPageSyncHandler::SendSyncMessageToPage(
}
dom_ui_->CallJavascriptFunction(L"syncMessageChanged", value);
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/dom_ui/new_tab_page_sync_handler.h b/chrome/browser/dom_ui/new_tab_page_sync_handler.h
index 3e120ad..cde61da 100644
--- a/chrome/browser/dom_ui/new_tab_page_sync_handler.h
+++ b/chrome/browser/dom_ui/new_tab_page_sync_handler.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_DOM_UI_NEW_TAB_PAGE_SYNC_HANDLER_H_
#define CHROME_BROWSER_DOM_UI_NEW_TAB_PAGE_SYNC_HANDLER_H_
@@ -68,4 +66,3 @@ class NewTabPageSyncHandler : public DOMMessageHandler,
};
#endif // CHROME_BROWSER_DOM_UI_NEW_TAB_PAGE_SYNC_HANDLER_H_
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/dom_ui/new_tab_ui.cc b/chrome/browser/dom_ui/new_tab_ui.cc
index 1e3bfa7..76c44ae 100644
--- a/chrome/browser/dom_ui/new_tab_ui.cc
+++ b/chrome/browser/dom_ui/new_tab_ui.cc
@@ -561,7 +561,7 @@ NewTabUI::NewTabUI(TabContents* contents)
if (WebResourcesEnabled())
AddMessageHandler((new TipsHandler())->Attach(this));
-#if defined(BROWSER_SYNC) && !defined(OS_POSIX)
+#if !defined(OS_POSIX)
if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisableSync)) {
AddMessageHandler((new NewTabPageSyncHandler())->Attach(this));
}
diff --git a/chrome/browser/gtk/bookmark_bar_gtk.cc b/chrome/browser/gtk/bookmark_bar_gtk.cc
index 60a372a..752f56c 100644
--- a/chrome/browser/gtk/bookmark_bar_gtk.cc
+++ b/chrome/browser/gtk/bookmark_bar_gtk.cc
@@ -118,10 +118,8 @@ BookmarkBarGtk::BookmarkBarGtk(BrowserWindowGtk* window,
model_(NULL),
instructions_label_(NULL),
instructions_(NULL),
-#if defined(BROWSER_SYNC)
sync_error_button_(NULL),
sync_service_(NULL),
-#endif
dragged_node_(NULL),
toolbar_drop_item_(NULL),
theme_provider_(GtkThemeProvider::GetFrom(profile)),
@@ -130,14 +128,12 @@ BookmarkBarGtk::BookmarkBarGtk(BrowserWindowGtk* window,
floating_(false),
last_allocation_width_(-1),
event_box_paint_factory_(this) {
-#if defined(BROWSER_SYNC)
if (profile->GetProfileSyncService()) {
// Obtain a pointer to the profile sync service and add our instance as an
// observer.
sync_service_ = profile->GetProfileSyncService();
sync_service_->AddObserver(this);
}
-#endif
Init(profile);
SetProfile(profile);
@@ -157,10 +153,8 @@ BookmarkBarGtk::~BookmarkBarGtk() {
bookmark_toolbar_.Destroy();
event_box_.Destroy();
-#if defined(BROWSER_SYNC)
if (sync_service_)
sync_service_->RemoveObserver(this);
-#endif
}
void BookmarkBarGtk::SetProfile(Profile* profile) {
@@ -267,12 +261,10 @@ void BookmarkBarGtk::Init(Profile* profile) {
g_signal_connect(vseparator, "expose-event",
G_CALLBACK(OnSeparatorExpose), this);
-#if defined(BROWSER_SYNC)
sync_error_button_ = theme_provider_->BuildChromeButton();
ConnectFolderButtonEvents(sync_error_button_);
gtk_box_pack_start(GTK_BOX(bookmark_hbox_), sync_error_button_,
FALSE, FALSE, 0);
-#endif
// We pack the button manually (rather than using gtk_button_set_*) so that
// we can have finer control over its label.
@@ -337,11 +329,9 @@ void BookmarkBarGtk::Hide(bool animate) {
}
}
-#if defined(BROWSER_SYNC)
void BookmarkBarGtk::OnStateChanged() {
// TODO(zork): TODO
}
-#endif
void BookmarkBarGtk::EnterFullscreen() {
if (ShouldBeFloating())
diff --git a/chrome/browser/gtk/bookmark_bar_gtk.h b/chrome/browser/gtk/bookmark_bar_gtk.h
index 9745fd7..4f4b7b7 100644
--- a/chrome/browser/gtk/bookmark_bar_gtk.h
+++ b/chrome/browser/gtk/bookmark_bar_gtk.h
@@ -33,9 +33,7 @@ class TabstripOriginProvider;
struct GtkThemeProvider;
class BookmarkBarGtk : public AnimationDelegate,
-#if defined(BROWSER_SYNC)
public ProfileSyncServiceObserver,
-#endif
public BookmarkModelObserver,
public MenuBarHelper::Delegate,
public NotificationObserver {
@@ -264,7 +262,6 @@ class BookmarkBarGtk : public AnimationDelegate,
GtkAllocation* allocation,
BookmarkBarGtk* bar);
-#if defined(BROWSER_SYNC)
// ProfileSyncServiceObserver method.
virtual void OnStateChanged();
@@ -274,7 +271,6 @@ class BookmarkBarGtk : public AnimationDelegate,
// Creates the sync error button and adds it as a child view.
GtkWidget* CreateSyncErrorButton();
-#endif
Profile* profile_;
@@ -320,14 +316,12 @@ class BookmarkBarGtk : public AnimationDelegate,
// The other bookmarks button.
GtkWidget* other_bookmarks_button_;
-#if defined(BROWSER_SYNC)
// The sync re-login indicator which appears when the user needs to re-enter
// credentials in order to continue syncing.
GtkWidget* sync_error_button_;
// A pointer to the ProfileSyncService instance if one exists.
ProfileSyncService* sync_service_;
-#endif
// The BookmarkNode from the model being dragged. NULL when we aren't
// dragging.
diff --git a/chrome/browser/gtk/standard_menus.cc b/chrome/browser/gtk/standard_menus.cc
index 8342408..7c8205f 100644
--- a/chrome/browser/gtk/standard_menus.cc
+++ b/chrome/browser/gtk/standard_menus.cc
@@ -94,10 +94,8 @@ struct MenuCreateMaterial standard_app_menu_materials[] = {
GDK_j, GDK_CONTROL_MASK },
{ MENU_NORMAL, IDC_MANAGE_EXTENSIONS, IDS_SHOW_EXTENSIONS },
{ MENU_SEPARATOR },
-#if defined(BROWSER_SYNC)
{ MENU_NORMAL, IDC_SYNC_BOOKMARKS, IDS_SYNC_MY_BOOKMARKS_LABEL},
{ MENU_SEPARATOR },
-#endif
{ MENU_NORMAL, IDC_OPTIONS, IDS_OPTIONS, IDS_PRODUCT_NAME },
{ MENU_NORMAL, IDC_ABOUT, IDS_ABOUT, IDS_PRODUCT_NAME },
{ MENU_NORMAL, IDC_HELP_PAGE, IDS_HELP_PAGE, 0, NULL, GDK_F1 },
diff --git a/chrome/browser/profile.cc b/chrome/browser/profile.cc
index e44a61c..82c4d26 100644
--- a/chrome/browser/profile.cc
+++ b/chrome/browser/profile.cc
@@ -727,9 +727,7 @@ ProfileImpl::~ProfileImpl() {
prefs->RemovePrefObserver(prefs::kEnableSpellCheck, this);
prefs->RemovePrefObserver(prefs::kEnableAutoSpellCorrect, this);
-#if defined(BROWSER_SYNC)
sync_service_.reset();
-#endif
// Both HistoryService and WebDataService maintain threads for background
// processing. Its possible each thread still has tasks on it that have
@@ -1355,7 +1353,7 @@ void ProfileImpl::StopCreateSessionServiceTimer() {
}
ProfileSyncService* ProfileImpl::GetProfileSyncService() {
-#if defined(BROWSER_SYNC) && !defined(OS_POSIX)
+#if !defined(OS_POSIX)
if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisableSync)) {
if (!sync_service_.get())
InitSyncService();
@@ -1366,8 +1364,6 @@ ProfileSyncService* ProfileImpl::GetProfileSyncService() {
}
void ProfileImpl::InitSyncService() {
-#if defined(BROWSER_SYNC)
sync_service_.reset(new ProfileSyncService(this));
sync_service_->Initialize();
-#endif
}
diff --git a/chrome/browser/profile.h b/chrome/browser/profile.h
index 741b5cf..77abf02 100644
--- a/chrome/browser/profile.h
+++ b/chrome/browser/profile.h
@@ -500,9 +500,7 @@ class ProfileImpl : public Profile,
scoped_ptr<BookmarkModel> bookmark_bar_model_;
scoped_refptr<WebResourceService> web_resource_service_;
-#if defined(BROWSER_SYNC)
scoped_ptr<ProfileSyncService> sync_service_;
-#endif
ChromeURLRequestContextGetter* request_context_;
diff --git a/chrome/browser/sync/glue/bookmark_model_worker.cc b/chrome/browser/sync/glue/bookmark_model_worker.cc
index 2425269..d358bfd 100644
--- a/chrome/browser/sync/glue/bookmark_model_worker.cc
+++ b/chrome/browser/sync/glue/bookmark_model_worker.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/glue/bookmark_model_worker.h"
#include "base/message_loop.h"
@@ -110,5 +108,3 @@ void BookmarkModelWorker::CallDoWorkAndSignalTask::Run() {
}
} // namespace browser_sync
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/bookmark_model_worker.h b/chrome/browser/sync/glue/bookmark_model_worker.h
index 8b47729..f2c80a1 100644
--- a/chrome/browser/sync/glue/bookmark_model_worker.h
+++ b/chrome/browser/sync/glue/bookmark_model_worker.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_GLUE_BOOKMARK_MODEL_WORKER_H_
#define CHROME_BROWSER_SYNC_GLUE_BOOKMARK_MODEL_WORKER_H_
@@ -130,5 +128,3 @@ class BookmarkModelWorker
} // namespace browser_sync
#endif // CHROME_BROWSER_SYNC_GLUE_BOOKMARK_MODEL_WORKER_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/bookmark_model_worker_unittest.cc b/chrome/browser/sync/glue/bookmark_model_worker_unittest.cc
index 0576732..183e2f5 100644
--- a/chrome/browser/sync/glue/bookmark_model_worker_unittest.cc
+++ b/chrome/browser/sync/glue/bookmark_model_worker_unittest.cc
@@ -1,7 +1,6 @@
// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
#include "base/thread.h"
#include "chrome/browser/sync/engine/syncapi.h"
@@ -220,5 +219,3 @@ TEST_F(BookmarkModelWorkerTest, HypotheticalManualPumpFlooding) {
EXPECT_FALSE(syncer_thread()->IsRunning());
core_thread()->Stop();
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/change_processor.cc b/chrome/browser/sync/glue/change_processor.cc
index ccc65043..5bf0e1a 100644
--- a/chrome/browser/sync/glue/change_processor.cc
+++ b/chrome/browser/sync/glue/change_processor.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/glue/change_processor.h"
#include "app/gfx/codec/png_codec.h"
@@ -545,5 +543,3 @@ void ChangeProcessor::SetSyncNodeFavicon(
}
} // namespace browser_sync
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/change_processor.h b/chrome/browser/sync/glue/change_processor.h
index 355c058..55c0c66 100644
--- a/chrome/browser/sync/glue/change_processor.h
+++ b/chrome/browser/sync/glue/change_processor.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_GLUE_CHANGE_PROCESSOR_H_
#define CHROME_BROWSER_SYNC_GLUE_CHANGE_PROCESSOR_H_
@@ -184,5 +182,3 @@ class ChangeProcessor : public BookmarkModelObserver,
} // namespace browser_sync
#endif // CHROME_BROWSER_SYNC_GLUE_CHANGE_APPLICATOR_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/http_bridge.cc b/chrome/browser/sync/glue/http_bridge.cc
index c019cba..56d3ebf9 100644
--- a/chrome/browser/sync/glue/http_bridge.cc
+++ b/chrome/browser/sync/glue/http_bridge.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/glue/http_bridge.h"
#include "base/message_loop.h"
@@ -238,5 +236,3 @@ void HttpBridge::OnURLFetchComplete(const URLFetcher *source, const GURL &url,
}
} // namespace browser_sync
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/http_bridge.h b/chrome/browser/sync/glue/http_bridge.h
index 12500ec..7164bd5 100644
--- a/chrome/browser/sync/glue/http_bridge.h
+++ b/chrome/browser/sync/glue/http_bridge.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_GLUE_HTTP_BRIDGE_H_
#define CHROME_BROWSER_SYNC_GLUE_HTTP_BRIDGE_H_
@@ -200,5 +198,3 @@ class HttpBridgeFactory
} // namespace browser_sync
#endif // CHROME_BROWSER_SYNC_GLUE_HTTP_BRIDGE_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/http_bridge_unittest.cc b/chrome/browser/sync/glue/http_bridge_unittest.cc
index c34ad25..b64f5e3 100644
--- a/chrome/browser/sync/glue/http_bridge_unittest.cc
+++ b/chrome/browser/sync/glue/http_bridge_unittest.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "base/thread.h"
#include "chrome/browser/chrome_thread.h"
#include "chrome/browser/sync/glue/http_bridge.h"
@@ -224,5 +222,3 @@ TEST_F(HttpBridgeTest, TestExtraRequestHeaders) {
EXPECT_NE(std::string::npos, response.find("fnord"));
EXPECT_NE(std::string::npos, response.find(test_payload.c_str()));
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/model_associator.cc b/chrome/browser/sync/glue/model_associator.cc
index 53cb5acc..c481da5 100644
--- a/chrome/browser/sync/glue/model_associator.cc
+++ b/chrome/browser/sync/glue/model_associator.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/glue/model_associator.h"
#include <stack>
@@ -509,5 +507,3 @@ bool ModelAssociator::LoadAssociations() {
}
} // namespace browser_sync
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/model_associator.h b/chrome/browser/sync/glue/model_associator.h
index dc6aaba..0304bf5 100644
--- a/chrome/browser/sync/glue/model_associator.h
+++ b/chrome/browser/sync/glue/model_associator.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_GLUE_MODEL_ASSOCIATOR_H_
#define CHROME_BROWSER_SYNC_GLUE_MODEL_ASSOCIATOR_H_
@@ -140,4 +138,3 @@ class ModelAssociator
} // namespace browser_sync
#endif // CHROME_BROWSER_SYNC_GLUE_MODEL_ASSOCIATOR_H_
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/sync_backend_host.cc b/chrome/browser/sync/glue/sync_backend_host.cc
index 4c38711..b10659c 100644
--- a/chrome/browser/sync/glue/sync_backend_host.cc
+++ b/chrome/browser/sync/glue/sync_backend_host.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "build/build_config.h"
#include "base/file_version_info.h"
#include "base/file_util.h"
@@ -313,5 +311,3 @@ void SyncBackendHost::Core::SaveChanges() {
}
} // namespace browser_sync
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/glue/sync_backend_host.h b/chrome/browser/sync/glue/sync_backend_host.h
index f0a1cd4..8697e0d 100644
--- a/chrome/browser/sync/glue/sync_backend_host.h
+++ b/chrome/browser/sync/glue/sync_backend_host.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_
#define CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_
@@ -288,4 +286,3 @@ class SyncBackendHost {
} // namespace browser_sync
#endif // CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_H_
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/profile_sync_service.cc b/chrome/browser/sync/profile_sync_service.cc
index 08d486c..0a0e9f9 100644
--- a/chrome/browser/sync/profile_sync_service.cc
+++ b/chrome/browser/sync/profile_sync_service.cc
@@ -2,7 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
#include "chrome/browser/sync/profile_sync_service.h"
#include <stack>
@@ -212,7 +211,7 @@ void ProfileSyncService::UpdateLastSyncedTime() {
void ProfileSyncService::OnUnrecoverableError() {
unrecoverable_error_detected_ = true;
change_processor_->Stop();
-
+
// Tell the wizard so it can inform the user only if it is already open.
wizard_.Step(SyncSetupWizard::FATAL_ERROR);
FOR_EACH_OBSERVER(Observer, observers_, OnStateChanged());
@@ -427,5 +426,3 @@ bool ProfileSyncService::ShouldPushChanges() {
// consistent with one another, and no unrecoverable error has transpired.
return change_processor_->IsRunning();
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/profile_sync_service.h b/chrome/browser/sync/profile_sync_service.h
index eca2480..8976703f 100644
--- a/chrome/browser/sync/profile_sync_service.h
+++ b/chrome/browser/sync/profile_sync_service.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
#define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
@@ -313,5 +311,3 @@ class ProfileSyncService : public NotificationObserver,
};
#endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/profile_sync_service_unittest.cc b/chrome/browser/sync/profile_sync_service_unittest.cc
index 994bc83..760f51f 100644
--- a/chrome/browser/sync/profile_sync_service_unittest.cc
+++ b/chrome/browser/sync/profile_sync_service_unittest.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include <stack>
#include <vector>
@@ -1282,5 +1280,3 @@ TEST_F(ProfileSyncServiceTestWithData, RecoverAfterDeletingSyncDataDirectory) {
ExpectBookmarkModelMatchesTestData();
ExpectModelMatch();
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/sync_setup_flow.cc b/chrome/browser/sync/sync_setup_flow.cc
index 50ab515..4f60825 100644
--- a/chrome/browser/sync/sync_setup_flow.cc
+++ b/chrome/browser/sync/sync_setup_flow.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/sync_setup_flow.h"
#include "app/gfx/font.h"
@@ -300,5 +298,3 @@ SyncSetupFlow* SyncSetupFlow::Run(ProfileSyncService* service,
b->BrowserShowHtmlDialog(flow, NULL);
return flow;
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/sync_setup_flow.h b/chrome/browser/sync/sync_setup_flow.h
index 20668ee..98345fc 100644
--- a/chrome/browser/sync/sync_setup_flow.h
+++ b/chrome/browser/sync/sync_setup_flow.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_SYNC_SETUP_FLOW_H_
#define CHROME_BROWSER_SYNC_SYNC_SETUP_FLOW_H_
@@ -186,4 +184,3 @@ class FlowHandler : public DOMMessageHandler {
};
#endif // CHROME_BROWSER_SYNC_SYNC_SETUP_FLOW_H_
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/sync_setup_wizard.cc b/chrome/browser/sync/sync_setup_wizard.cc
index 5c55730..e738b14 100644
--- a/chrome/browser/sync/sync_setup_wizard.cc
+++ b/chrome/browser/sync/sync_setup_wizard.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/sync_setup_wizard.h"
#include "app/resource_bundle.h"
@@ -196,5 +194,3 @@ SyncSetupWizard::State SyncSetupWizard::GetEndStateForDiscreteRun(
"Invalid start state for discrete run: " << start_state;
return result;
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/sync_setup_wizard_unittest.cc b/chrome/browser/sync/sync_setup_wizard_unittest.cc
index 847750f..10f5a7a 100644
--- a/chrome/browser/sync/sync_setup_wizard_unittest.cc
+++ b/chrome/browser/sync/sync_setup_wizard_unittest.cc
@@ -1,8 +1,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "testing/gtest/include/gtest/gtest.h"
#include "base/json/json_writer.h"
@@ -372,5 +370,3 @@ TEST_F(SyncSetupWizardTest, DiscreteRun) {
wizard_->Step(SyncSetupWizard::GAIA_SUCCESS);
EXPECT_TRUE(test_window_->TestAndResetWasShowHTMLDialogCalled());
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/sync_status_ui_helper.cc b/chrome/browser/sync/sync_status_ui_helper.cc
index 8ec8a17..37b790a 100644
--- a/chrome/browser/sync/sync_status_ui_helper.cc
+++ b/chrome/browser/sync/sync_status_ui_helper.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/sync_status_ui_helper.h"
#include "app/l10n_util.h"
@@ -116,5 +114,3 @@ SyncStatusUIHelper::MessageType SyncStatusUIHelper::GetLabels(
}
return result_type;
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/sync/sync_status_ui_helper.h b/chrome/browser/sync/sync_status_ui_helper.h
index e5da495..e54db5d 100644
--- a/chrome/browser/sync/sync_status_ui_helper.h
+++ b/chrome/browser/sync/sync_status_ui_helper.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_BROWSER_SYNC_SYNC_STATUS_UI_HELPER_H_
#define CHROME_BROWSER_SYNC_SYNC_STATUS_UI_HELPER_H_
@@ -31,4 +29,3 @@ class SyncStatusUIHelper {
};
#endif // CHROME_BROWSER_SYNC_SYNC_STATUS_UI_HELPER_H_
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/views/bookmark_bar_view.cc b/chrome/browser/views/bookmark_bar_view.cc
index 2bb0fc8..2e9b167 100644
--- a/chrome/browser/views/bookmark_bar_view.cc
+++ b/chrome/browser/views/bookmark_bar_view.cc
@@ -114,10 +114,8 @@ static const SkColor kInstructionsColor = SkColorSetRGB(128, 128, 142);
// Tag for the 'Other bookmarks' button.
static const int kOtherFolderButtonTag = 1;
-#if defined(BROWSER_SYNC)
// Tag for the sync error button.
static const int kSyncErrorButtonTag = 2;
-#endif
namespace {
@@ -370,23 +368,19 @@ BookmarkBarView::BookmarkBarView(Profile* profile, Browser* browser)
other_bookmarked_button_(NULL),
model_changed_listener_(NULL),
show_folder_drop_menu_task_(NULL),
-#if defined(BROWSER_SYNC)
sync_error_button_(NULL),
sync_service_(NULL),
-#endif
overflow_button_(NULL),
instructions_(NULL),
bookmarks_separator_view_(NULL),
browser_(browser),
throbbing_view_(NULL) {
-#if defined(BROWSER_SYNC)
if (profile->GetProfileSyncService()) {
// Obtain a pointer to the profile sync service and add our instance as an
// observer.
sync_service_ = profile->GetProfileSyncService();
sync_service_->AddObserver(this);
}
-#endif
SetID(VIEW_ID_BOOKMARK_BAR);
Init();
@@ -404,10 +398,8 @@ BookmarkBarView::~BookmarkBarView() {
model_->RemoveObserver(this);
StopShowFolderDropMenuTimer();
-#if defined(BROWSER_SYNC)
if (sync_service_)
sync_service_->RemoveObserver(this);
-#endif
}
void BookmarkBarView::SetProfile(Profile* profile) {
@@ -466,11 +458,9 @@ gfx::Size BookmarkBarView::GetMinimumSize() {
}
int sync_error_total_width = 0;
-#if defined(BROWSER_SYNC)
gfx::Size sync_error_button_pref = sync_error_button_->GetPreferredSize();
if (ShouldShowSyncErrorButton())
sync_error_total_width += kButtonPadding + sync_error_button_pref.width();
-#endif
gfx::Size other_bookmarked_pref =
other_bookmarked_button_->GetPreferredSize();
@@ -718,7 +708,6 @@ void BookmarkBarView::SetAccessibleName(const std::wstring& name) {
accessible_name_.assign(name);
}
-#if defined(BROWSER_SYNC)
void BookmarkBarView::OnStateChanged() {
// When the sync state changes, it is sufficient to invoke View::Layout since
// during layout we query the profile sync service and determine whether the
@@ -732,7 +721,6 @@ void BookmarkBarView::OnStateChanged() {
Layout();
SchedulePaint();
}
-#endif // defined(BROWSER_SYNC)
void BookmarkBarView::OnFullscreenToggled(bool fullscreen) {
if (!fullscreen)
@@ -878,10 +866,8 @@ void BookmarkBarView::Init() {
other_bookmarked_button_ = CreateOtherBookmarkedButton();
AddChildView(other_bookmarked_button_);
-#if defined(BROWSER_SYNC)
sync_error_button_ = CreateSyncErrorButton();
AddChildView(sync_error_button_);
-#endif
overflow_button_ = CreateOverflowButton();
AddChildView(overflow_button_);
@@ -937,16 +923,10 @@ MenuButton* BookmarkBarView::CreateOverflowButton() {
}
int BookmarkBarView::GetBookmarkButtonCount() {
-#if defined(BROWSER_SYNC)
// We contain at least four non-bookmark button views: other bookmarks,
// bookmarks separator, chevrons (for overflow), the instruction label and
// the sync error button.
return GetChildViewCount() - 5;
-#else
- // We contain at least four non-bookmark button views: other bookmarks,
- // bookmarks separator, chevrons (for overflow) and the instruction label.
- return GetChildViewCount() - 4;
-#endif
}
void BookmarkBarView::Loaded(BookmarkModel* model) {
@@ -1161,7 +1141,6 @@ void BookmarkBarView::RunMenu(views::View* view, const gfx::Point& pt) {
void BookmarkBarView::ButtonPressed(views::Button* sender,
const views::Event& event) {
-#if defined(BROWSER_SYNC)
// Show the login wizard if the user clicked the re-login button.
if (sender->tag() == kSyncErrorButtonTag) {
DCHECK(sender == sync_error_button_);
@@ -1169,7 +1148,6 @@ void BookmarkBarView::ButtonPressed(views::Button* sender,
sync_service_->ShowLoginDialog();
return;
}
-#endif
const BookmarkNode* node;
if (sender->tag() == kOtherFolderButtonTag) {
@@ -1592,13 +1570,11 @@ gfx::Size BookmarkBarView::LayoutItems(bool compute_bounds_only) {
bookmarks_separator_view_->GetPreferredSize();
int sync_error_total_width = 0;
-#if defined(BROWSER_SYNC)
gfx::Size sync_error_button_pref = sync_error_button_->GetPreferredSize();
const bool should_show_sync_error_button = ShouldShowSyncErrorButton();
if (should_show_sync_error_button) {
sync_error_total_width += kButtonPadding + sync_error_button_pref.width();
}
-#endif
const int max_x = width - other_bookmarked_pref.width() - kButtonPadding -
overflow_pref.width() - kButtonPadding -
bookmarks_separator_pref.width() - sync_error_total_width;
@@ -1667,7 +1643,6 @@ gfx::Size BookmarkBarView::LayoutItems(bool compute_bounds_only) {
}
x += other_bookmarked_pref.width() + kButtonPadding;
-#if defined(BROWSER_SYNC)
// Set the real bounds of the sync error button only if it needs to appear on
// the bookmarks bar.
if (should_show_sync_error_button) {
@@ -1682,7 +1657,6 @@ gfx::Size BookmarkBarView::LayoutItems(bool compute_bounds_only) {
sync_error_button_->SetBounds(x, y, 0, height);
sync_error_button_->SetVisible(false);
}
-#endif // defined(BROWSER_SYNC)
// Set the preferred size computed so far.
if (compute_bounds_only) {
@@ -1702,7 +1676,6 @@ gfx::Size BookmarkBarView::LayoutItems(bool compute_bounds_only) {
return prefsize;
}
-#if defined(BROWSER_SYNC)
// The sync state reported by the profile sync service determines whether or
// not the re-login indicator button should be visible.
bool BookmarkBarView::ShouldShowSyncErrorButton() {
@@ -1736,4 +1709,3 @@ views::TextButton* BookmarkBarView::CreateSyncErrorButton() {
*ResourceBundle::GetSharedInstance().GetBitmapNamed(IDR_WARNING));
return sync_error_button;
}
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/views/bookmark_bar_view.h b/chrome/browser/views/bookmark_bar_view.h
index 0d79cc6..49ac37f 100644
--- a/chrome/browser/views/bookmark_bar_view.h
+++ b/chrome/browser/views/bookmark_bar_view.h
@@ -36,9 +36,7 @@ class TextButton;
// waits until the HistoryService for the profile has been loaded before
// creating the BookmarkModel.
class BookmarkBarView : public DetachableToolbarView,
-#if defined(BROWSER_SYNC)
public ProfileSyncServiceObserver,
-#endif
public BookmarkModelObserver,
public views::ViewMenuDelegate,
public views::ButtonListener,
@@ -118,10 +116,8 @@ class BookmarkBarView : public DetachableToolbarView,
virtual bool GetAccessibleRole(AccessibilityTypes::Role* role);
virtual void SetAccessibleName(const std::wstring& name);
-#if defined(BROWSER_SYNC)
// ProfileSyncServiceObserver method.
virtual void OnStateChanged();
-#endif
// Called when fullscreen mode toggles on or off; this affects our layout.
void OnFullscreenToggled(bool fullscreen);
@@ -418,14 +414,13 @@ class BookmarkBarView : public DetachableToolbarView,
// desired bounds. If |compute_bounds_only| = FALSE, the bounds are set.
gfx::Size LayoutItems(bool compute_bounds_only);
-#if defined(BROWSER_SYNC)
// Determines whether the sync error button should appear on the bookmarks
// bar.
bool ShouldShowSyncErrorButton();
// Creates the sync error button and adds it as a child view.
views::TextButton* CreateSyncErrorButton();
-#endif
+
NotificationRegistrar registrar_;
Profile* profile_;
@@ -458,14 +453,12 @@ class BookmarkBarView : public DetachableToolbarView,
// Used to track drops on the bookmark bar view.
scoped_ptr<DropInfo> drop_info_;
-#if defined(BROWSER_SYNC)
// The sync re-login indicator which appears when the user needs to re-enter
// credentials in order to continue syncing.
views::TextButton* sync_error_button_;
// A pointer to the ProfileSyncService instance if one exists.
ProfileSyncService* sync_service_;
-#endif
// Visible if not all the bookmark buttons fit.
views::MenuButton* overflow_button_;
diff --git a/chrome/browser/views/bookmark_manager_view.cc b/chrome/browser/views/bookmark_manager_view.cc
index ce40b28..5cb0375 100644
--- a/chrome/browser/views/bookmark_manager_view.cc
+++ b/chrome/browser/views/bookmark_manager_view.cc
@@ -165,10 +165,8 @@ BookmarkManagerView::BookmarkManagerView(Profile* profile)
: profile_(profile->GetOriginalProfile()),
table_view_(NULL),
tree_view_(NULL),
-#if defined(BROWSER_SYNC)
sync_status_button_(NULL),
sync_service_(NULL),
-#endif
ALLOW_THIS_IN_INITIALIZER_LIST(search_factory_(this)) {
search_tf_ = new views::Textfield();
search_tf_->set_default_width_in_chars(30);
@@ -207,10 +205,8 @@ BookmarkManagerView::BookmarkManagerView(Profile* profile)
0, views::GridLayout::USE_PREF, 0, 0);
column_set->AddColumn(views::GridLayout::LEADING, views::GridLayout::CENTER,
0, views::GridLayout::USE_PREF, 0, 0);
-#if defined(BROWSER_SYNC)
column_set->AddColumn(views::GridLayout::LEADING, views::GridLayout::CENTER,
0, views::GridLayout::USE_PREF, 0, 0);
-#endif
column_set->AddPaddingColumn(1, kUnrelatedControlHorizontalSpacing);
column_set->AddColumn(views::GridLayout::LEADING, views::GridLayout::CENTER,
0, views::GridLayout::USE_PREF, 0, 0);
@@ -226,10 +222,8 @@ BookmarkManagerView::BookmarkManagerView(Profile* profile)
layout->StartRow(0, top_id);
layout->AddView(organize_menu_button);
layout->AddView(tools_menu_button);
-#if defined(BROWSER_SYNC)
sync_status_button_ = new views::TextButton(this, std::wstring());
layout->AddView(sync_status_button_);
-#endif
layout->AddView(new views::Label(
l10n_util::GetString(IDS_BOOKMARK_MANAGER_SEARCH_TITLE)));
layout->AddView(search_tf_);
@@ -246,13 +240,11 @@ BookmarkManagerView::BookmarkManagerView(Profile* profile)
if (!bookmark_model->IsLoaded())
bookmark_model->AddObserver(this);
-#if defined(BROWSER_SYNC)
if (profile->GetProfileSyncService()) {
sync_service_ = profile_->GetProfileSyncService();
sync_service_->AddObserver(this);
UpdateSyncStatus();
}
-#endif
}
BookmarkManagerView::~BookmarkManagerView() {
@@ -271,10 +263,8 @@ BookmarkManagerView::~BookmarkManagerView() {
manager = NULL;
open_window = NULL;
-#if defined(BROWSER_SYNC)
if (sync_service_)
sync_service_->RemoveObserver(this);
-#endif
}
// static
@@ -383,11 +373,9 @@ void BookmarkManagerView::WindowClosing() {
prefs::kBookmarkManagerSplitLocation, split_view_->divider_offset());
}
-#if defined(BROWSER_SYNC)
void BookmarkManagerView::OnStateChanged() {
UpdateSyncStatus();
}
-#endif
bool BookmarkManagerView::AcceleratorPressed(
const views::Accelerator& accelerator) {
@@ -521,7 +509,6 @@ void BookmarkManagerView::OnTreeViewKeyDown(base::KeyboardCode keycode) {
}
}
-#if defined(BROWSER_SYNC)
void BookmarkManagerView::ButtonPressed(views::Button* sender,
const views::Event& event) {
if (sender == sync_status_button_) {
@@ -529,7 +516,6 @@ void BookmarkManagerView::ButtonPressed(views::Button* sender,
OpenSyncMyBookmarksDialog();
}
}
-#endif
void BookmarkManagerView::Loaded(BookmarkModel* model) {
model->RemoveObserver(this);
@@ -832,7 +818,6 @@ void BookmarkManagerView::ShowExportBookmarksFileChooser() {
reinterpret_cast<void*>(IDS_BOOKMARK_MANAGER_EXPORT_MENU));
}
-#if defined(BROWSER_SYNC)
void BookmarkManagerView::UpdateSyncStatus() {
DCHECK(sync_service_);
std::wstring status_label;
@@ -862,4 +847,3 @@ void BookmarkManagerView::OpenSyncMyBookmarksDialog() {
ProfileSyncService::START_FROM_BOOKMARK_MANAGER);
}
}
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/views/bookmark_manager_view.h b/chrome/browser/views/bookmark_manager_view.h
index 37bc746..c8de962 100644
--- a/chrome/browser/views/bookmark_manager_view.h
+++ b/chrome/browser/views/bookmark_manager_view.h
@@ -44,10 +44,8 @@ class BookmarkManagerView : public views::View,
public views::TreeViewController,
public views::ViewMenuDelegate,
public views::WindowDelegate,
-#if defined(BROWSER_SYNC)
public views::ButtonListener,
public ProfileSyncServiceObserver,
-#endif
public BookmarkModelObserver,
public SelectFileDialog::Listener {
public:
@@ -95,10 +93,8 @@ class BookmarkManagerView : public views::View,
//virtual bool ShouldShowWindowIcon() const { return true; }
virtual void WindowClosing();
-#if defined(BROWSER_SYNC)
// ProfileSyncServiceObserver method.
virtual void OnStateChanged();
-#endif
Profile* profile() const { return profile_; }
@@ -119,10 +115,8 @@ class BookmarkManagerView : public views::View,
virtual void OnTreeViewSelectionChanged(views::TreeView* tree_view);
virtual void OnTreeViewKeyDown(base::KeyboardCode keycode);
-#if defined(BROWSER_SYNC)
// views::ButtonListener method.
virtual void ButtonPressed(views::Button* sender, const views::Event& event);
-#endif
// BookmarkModelObserver. We're only installed as an observer until the
// bookmarks are loaded.
@@ -214,10 +208,8 @@ class BookmarkManagerView : public views::View,
void ShowImportBookmarksFileChooser();
void ShowExportBookmarksFileChooser();
-#if defined(BROWSER_SYNC)
void UpdateSyncStatus();
void OpenSyncMyBookmarksDialog();
-#endif
Profile* profile_;
BookmarkTableView* table_view_;
@@ -230,14 +222,12 @@ class BookmarkManagerView : public views::View,
// Import/export file dialog.
scoped_refptr<SelectFileDialog> select_file_dialog_;
-#if defined(BROWSER_SYNC)
// The sync status button that notifies the user about the current status of
// bookmarks synchronization.
views::TextButton* sync_status_button_;
// A pointer to the ProfileSyncService instance if one exists.
ProfileSyncService* sync_service_;
-#endif
// Factory used for delaying search.
ScopedRunnableMethodFactory<BookmarkManagerView> search_factory_;
diff --git a/chrome/browser/views/options/content_page_view.cc b/chrome/browser/views/options/content_page_view.cc
index d378565..f5e99ff 100644
--- a/chrome/browser/views/options/content_page_view.cc
+++ b/chrome/browser/views/options/content_page_view.cc
@@ -36,14 +36,13 @@ namespace {
const int kPasswordSavingRadioGroup = 1;
const int kFormAutofillRadioGroup = 2;
-#if defined(BROWSER_SYNC)
// Background color for the status label when it's showing an error.
static const SkColor kSyncLabelErrorBgColor = SkColorSetRGB(0xff, 0x9a, 0x9a);
static views::Background* CreateErrorBackground() {
return views::Background::CreateSolidBackground(kSyncLabelErrorBgColor);
}
-#endif
+
} // namespace
ContentPageView::ContentPageView(Profile* profile)
@@ -60,27 +59,21 @@ ContentPageView::ContentPageView(Profile* profile)
browsing_data_group_(NULL),
import_button_(NULL),
clear_data_button_(NULL),
-#if defined(BROWSER_SYNC)
sync_group_(NULL),
sync_status_label_(NULL),
sync_action_link_(NULL),
sync_start_stop_button_(NULL),
sync_service_(NULL),
-#endif
OptionsPageView(profile) {
-#if defined(BROWSER_SYNC)
if (profile->GetProfileSyncService()) {
sync_service_ = profile->GetProfileSyncService();
sync_service_->AddObserver(this);
-#endif
}
}
ContentPageView::~ContentPageView() {
-#if defined(BROWSER_SYNC)
if (sync_service_)
sync_service_->RemoveObserver(this);
-#endif
}
///////////////////////////////////////////////////////////////////////////////
@@ -126,7 +119,6 @@ void ContentPageView::ButtonPressed(
GetWindow()->GetNativeWindow(),
gfx::Rect(),
new ClearBrowsingDataView(profile()))->Show();
-#if defined(BROWSER_SYNC)
} else if (sender == sync_start_stop_button_) {
DCHECK(sync_service_);
@@ -146,7 +138,6 @@ void ContentPageView::ButtonPressed(
sync_service_->EnableForUser();
ProfileSyncService::SyncEvent(ProfileSyncService::START_FROM_OPTIONS);
}
-#endif
}
}
@@ -159,11 +150,9 @@ void ContentPageView::LinkActivated(views::Link* source, int event_flags) {
browser->window()->Activate();
return;
}
-#if defined(BROWSER_SYNC)
DCHECK_EQ(source, sync_action_link_);
DCHECK(sync_service_);
sync_service_->ShowLoginDialog();
-#endif
}
////////////////////////////////////////////////////////////////////////////////
@@ -182,14 +171,12 @@ void ContentPageView::InitControlLayout() {
column_set->AddColumn(GridLayout::FILL, GridLayout::FILL, 1,
GridLayout::USE_PREF, 0, 0);
-#if defined(BROWSER_SYNC)
if (sync_service_) {
layout->StartRow(0, single_column_view_set_id);
InitSyncGroup();
layout->AddView(sync_group_);
layout->AddPaddingRow(0, kRelatedControlVerticalSpacing);
}
-#endif
layout->StartRow(0, single_column_view_set_id);
InitPasswordSavingGroup();
@@ -245,10 +232,8 @@ void ContentPageView::NotifyPrefChanged(const std::wstring* pref_name) {
// ContentsPageView, views::View overrides:
void ContentPageView::Layout() {
-#if defined(BROWSER_SYNC)
if (is_initialized())
UpdateSyncControls();
-#endif
// We need to Layout twice - once to get the width of the contents box...
View::Layout();
passwords_asktosave_radio_->SetBounds(
@@ -257,12 +242,10 @@ void ContentPageView::Layout() {
0, 0, passwords_group_->GetContentsWidth(), 0);
browsing_data_label_->SetBounds(
0, 0, browsing_data_group_->GetContentsWidth(), 0);
-#if defined(BROWSER_SYNC)
if (is_initialized()) {
sync_status_label_->SetBounds(
0, 0, sync_group_->GetContentsWidth(), 0);
}
-#endif
// ... and twice to get the height of multi-line items correct.
View::Layout();
}
@@ -270,7 +253,7 @@ void ContentPageView::Layout() {
///////////////////////////////////////////////////////////////////////////////
// ContentsPageView, ProfileSyncServiceObserver implementation:
-#if defined(BROWSER_SYNC)
+
void ContentPageView::OnStateChanged() {
// If the UI controls are not yet initialized, then don't do anything. This
// can happen if the Options dialog is up, but the Content tab is not yet
@@ -278,7 +261,6 @@ void ContentPageView::OnStateChanged() {
if (is_initialized())
Layout();
}
-#endif
///////////////////////////////////////////////////////////////////////////////
// ContentPageView, private:
@@ -439,7 +421,6 @@ void ContentPageView::OnConfirmMessageAccept() {
ProfileSyncService::SyncEvent(ProfileSyncService::STOP_FROM_OPTIONS);
}
-#if defined(BROWSER_SYNC)
void ContentPageView::InitSyncGroup() {
sync_status_label_ = new views::Label;
sync_status_label_->SetMultiLine(true);
@@ -503,5 +484,3 @@ void ContentPageView::UpdateSyncControls() {
sync_action_link_->set_background(NULL);
}
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/browser/views/options/content_page_view.h b/chrome/browser/views/options/content_page_view.h
index 91febde..d79ede6 100644
--- a/chrome/browser/views/options/content_page_view.h
+++ b/chrome/browser/views/options/content_page_view.h
@@ -27,10 +27,8 @@ class PrefService;
// ContentPageView
class ContentPageView : public OptionsPageView,
-#if defined(BROWSER_SYNC)
public views::LinkController,
public ProfileSyncServiceObserver,
-#endif
public views::ButtonListener,
public ConfirmMessageBoxObserver {
public:
@@ -46,10 +44,8 @@ class ContentPageView : public OptionsPageView,
// ConfirmMessageBoxObserver implementation.
virtual void OnConfirmMessageAccept();
-#if defined(BROWSER_SYNC)
// ProfileSyncServiceObserver method.
virtual void OnStateChanged();
-#endif
protected:
// OptionsPageView implementation:
@@ -60,7 +56,6 @@ class ContentPageView : public OptionsPageView,
virtual void Layout();
private:
-#if defined(BROWSER_SYNC)
// Updates various sync controls based on the current sync state.
void UpdateSyncControls();
@@ -71,16 +66,13 @@ class ContentPageView : public OptionsPageView,
// are already initialized or not.
return sync_group_ != NULL;
}
-#endif
// Init all the dialog controls.
void InitPasswordSavingGroup();
void InitFormAutofillGroup();
void InitBrowsingDataGroup();
void InitThemesGroup();
-#if defined(BROWSER_SYNC)
void InitSyncGroup();
-#endif
// Controls for the Password Saving group
views::NativeButton* passwords_exceptions_button_;
@@ -104,23 +96,19 @@ class ContentPageView : public OptionsPageView,
views::NativeButton* import_button_;
views::NativeButton* clear_data_button_;
-#if defined(BROWSER_SYNC)
// Controls for the Sync group.
OptionsGroupView* sync_group_;
views::Label* sync_status_label_;
views::Link* sync_action_link_;
views::NativeButton* sync_start_stop_button_;
-#endif
BooleanPrefMember ask_to_save_passwords_;
BooleanPrefMember ask_to_save_form_autofill_;
StringPrefMember is_using_default_theme_;
-#if defined(BROWSER_SYNC)
// Cached pointer to ProfileSyncService, if it exists. Kept up to date
// and NULL-ed out on destruction.
ProfileSyncService* sync_service_;
-#endif
DISALLOW_COPY_AND_ASSIGN(ContentPageView);
};
diff --git a/chrome/browser/views/toolbar_view.cc b/chrome/browser/views/toolbar_view.cc
index 68159f8..8194729 100644
--- a/chrome/browser/views/toolbar_view.cc
+++ b/chrome/browser/views/toolbar_view.cc
@@ -1173,7 +1173,6 @@ void ToolbarView::CreateAppMenu() {
IDS_SHOW_EXTENSIONS);
app_menu_contents_->AddSeparator();
-#if defined(BROWSER_SYNC)
if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisableSync)) {
string16 label;
string16 link;
@@ -1189,7 +1188,6 @@ void ToolbarView::CreateAppMenu() {
app_menu_contents_->AddItem(IDC_SYNC_BOOKMARKS, label);
app_menu_contents_->AddSeparator();
}
-#endif
app_menu_contents_->AddItem(IDC_OPTIONS,
l10n_util::GetStringFUTF16(
IDS_OPTIONS,
diff --git a/chrome/chrome.gyp b/chrome/chrome.gyp
index f2734f2..8d0bb7e 100755
--- a/chrome/chrome.gyp
+++ b/chrome/chrome.gyp
@@ -127,7 +127,6 @@
'../views/controls/table/table_view_unittest.cc',
'../views/grid_layout_unittest.cc',
],
- 'browser_sync%': 1,
'conditions': [
['OS=="win"', {
'nacl_defines': [
@@ -205,11 +204,6 @@
['OS=="linux" and toolkit_views==1', {'sources/': [
['include', '_views\\.cc$'],
]}],
- ['browser_sync==0', {'sources/': [
- ['exclude', '^(browser/sync|browser/views/sync).*cc$'],
- ]}, {'defines': [
- 'BROWSER_SYNC=1',
- ]}],
],
},
'targets': [
@@ -2992,7 +2986,7 @@
'../third_party/WebKit/WebCore/WebCore.gyp/WebCore.gyp:webcore',
],
}],
- ['OS=="linux" and browser_sync==1', {
+ ['OS=="linux"', {
'sources': [
'browser/gtk/sync_setup_wizard_gtk.cc',
'browser/gtk/sync_setup_wizard_gtk.h',
@@ -4919,38 +4913,29 @@
# Provides a syncapi dynamic library target from checked-in binaries,
# or from compiling a stub implementation.
'target_name': 'syncapi',
-
- 'conditions': [
- ['browser_sync==0', {
- # Empty target.
- 'type': 'none',
- }, {
- # Build sync.
- 'type': '<(library)',
- 'sources': [
- 'browser/sync/engine/syncapi.cc',
- ],
- 'include_dirs': [
- '..',
- '<(protoc_out_dir)',
- ],
- 'defines' : [
- '_CRT_SECURE_NO_WARNINGS',
- '_USE_32BIT_TIME_T',
- ],
- 'dependencies': [
- '../base/base.gyp:base',
- '../build/temp_gyp/googleurl.gyp:googleurl',
- '../net/net.gyp:net_base',
- '../third_party/icu/icu.gyp:icuuc',
- '../third_party/libjingle/libjingle.gyp:libjingle',
- '../third_party/sqlite/sqlite.gyp:sqlite',
- 'common_constants',
- 'notifier',
- 'sync',
- 'sync_proto',
- ],
- }],
+ 'type': '<(library)',
+ 'sources': [
+ 'browser/sync/engine/syncapi.cc',
+ ],
+ 'include_dirs': [
+ '..',
+ '<(protoc_out_dir)',
+ ],
+ 'defines' : [
+ '_CRT_SECURE_NO_WARNINGS',
+ '_USE_32BIT_TIME_T',
+ ],
+ 'dependencies': [
+ '../base/base.gyp:base',
+ '../build/temp_gyp/googleurl.gyp:googleurl',
+ '../net/net.gyp:net_base',
+ '../third_party/icu/icu.gyp:icuuc',
+ '../third_party/libjingle/libjingle.gyp:libjingle',
+ '../third_party/sqlite/sqlite.gyp:sqlite',
+ 'common_constants',
+ 'notifier',
+ 'sync',
+ 'sync_proto',
],
},
{
@@ -5084,6 +5069,386 @@
}], # OS="win"
], # conditions
},
+ {
+ # Protobuf compiler / generate rule for sync.proto
+ 'target_name': 'sync_proto',
+ 'type': 'none',
+ 'actions': [
+ {
+ 'action_name': 'compiling sync.proto',
+ 'inputs': [
+ '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)protoc<(EXECUTABLE_SUFFIX)',
+ 'browser/sync/protocol/sync.proto',
+ ],
+ 'outputs': [
+ '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.cc',
+ '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.h',
+ ],
+ 'action': [
+ '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)protoc<(EXECUTABLE_SUFFIX)',
+ '--proto_path=browser/sync/protocol',
+ 'browser/sync/protocol/sync.proto',
+ '--cpp_out=<(protoc_out_dir)/chrome/browser/sync/protocol',
+ ],
+ },
+ ],
+ 'dependencies': [
+ '../third_party/protobuf2/protobuf.gyp:protobuf_lite',
+ '../third_party/protobuf2/protobuf.gyp:protoc',
+ ],
+ 'export_dependent_settings': [
+ '../third_party/protobuf2/protobuf.gyp:protobuf_lite',
+ ],
+ },
+ {
+ 'target_name': 'notifier',
+ 'type': '<(library)',
+ 'sources': [
+ 'browser/sync/notifier/base/async_dns_lookup.cc',
+ 'browser/sync/notifier/base/async_dns_lookup.h',
+ 'browser/sync/notifier/base/async_network_alive.h',
+ 'browser/sync/notifier/base/fastalloc.h',
+ 'browser/sync/notifier/base/linux/network_status_detector_task_linux.cc',
+ 'browser/sync/notifier/base/linux/time_linux.cc',
+ 'browser/sync/notifier/base/mac/network_status_detector_task_mac.cc',
+ 'browser/sync/notifier/base/mac/time_mac.cc',
+ 'browser/sync/notifier/base/nethelpers.cc',
+ 'browser/sync/notifier/base/nethelpers.h',
+ 'browser/sync/notifier/base/network_status_detector_task.cc',
+ 'browser/sync/notifier/base/network_status_detector_task.h',
+ 'browser/sync/notifier/base/network_status_detector_task_mt.cc',
+ 'browser/sync/notifier/base/network_status_detector_task_mt.h',
+ 'browser/sync/notifier/base/posix/time_posix.cc',
+ 'browser/sync/notifier/base/signal_thread_task.h',
+ 'browser/sync/notifier/base/static_assert.h',
+ 'browser/sync/notifier/base/task_pump.cc',
+ 'browser/sync/notifier/base/task_pump.h',
+ 'browser/sync/notifier/base/time.cc',
+ 'browser/sync/notifier/base/time.h',
+ 'browser/sync/notifier/base/timer.cc',
+ 'browser/sync/notifier/base/timer.h',
+ 'browser/sync/notifier/base/utils.h',
+ 'browser/sync/notifier/base/win/async_network_alive_win32.cc',
+ 'browser/sync/notifier/base/win/time_win32.cc',
+ 'browser/sync/notifier/communicator/auth_task.cc',
+ 'browser/sync/notifier/communicator/auth_task.h',
+ 'browser/sync/notifier/communicator/auto_reconnect.cc',
+ 'browser/sync/notifier/communicator/auto_reconnect.h',
+ 'browser/sync/notifier/communicator/connection_options.cc',
+ 'browser/sync/notifier/communicator/connection_options.h',
+ 'browser/sync/notifier/communicator/connection_settings.cc',
+ 'browser/sync/notifier/communicator/connection_settings.h',
+ 'browser/sync/notifier/communicator/const_communicator.h',
+ 'browser/sync/notifier/communicator/login.cc',
+ 'browser/sync/notifier/communicator/login.h',
+ 'browser/sync/notifier/communicator/login_failure.cc',
+ 'browser/sync/notifier/communicator/login_failure.h',
+ 'browser/sync/notifier/communicator/login_settings.cc',
+ 'browser/sync/notifier/communicator/login_settings.h',
+ 'browser/sync/notifier/communicator/product_info.cc',
+ 'browser/sync/notifier/communicator/product_info.h',
+ 'browser/sync/notifier/communicator/single_login_attempt.cc',
+ 'browser/sync/notifier/communicator/single_login_attempt.h',
+ 'browser/sync/notifier/communicator/ssl_socket_adapter.cc',
+ 'browser/sync/notifier/communicator/ssl_socket_adapter.h',
+ 'browser/sync/notifier/communicator/talk_auth_task.cc',
+ 'browser/sync/notifier/communicator/talk_auth_task.h',
+ 'browser/sync/notifier/communicator/xmpp_connection_generator.cc',
+ 'browser/sync/notifier/communicator/xmpp_connection_generator.h',
+ 'browser/sync/notifier/communicator/xmpp_log.cc',
+ 'browser/sync/notifier/communicator/xmpp_log.h',
+ 'browser/sync/notifier/communicator/xmpp_socket_adapter.cc',
+ 'browser/sync/notifier/communicator/xmpp_socket_adapter.h',
+ 'browser/sync/notifier/gaia_auth/gaiaauth.cc',
+ 'browser/sync/notifier/gaia_auth/gaiaauth.h',
+ 'browser/sync/notifier/gaia_auth/gaiahelper.cc',
+ 'browser/sync/notifier/gaia_auth/gaiahelper.h',
+ 'browser/sync/notifier/gaia_auth/inet_aton.h',
+ 'browser/sync/notifier/gaia_auth/sigslotrepeater.h',
+ 'browser/sync/notifier/gaia_auth/win/win32window.cc',
+ 'browser/sync/notifier/listener/listen_task.cc',
+ 'browser/sync/notifier/listener/listen_task.h',
+ 'browser/sync/notifier/listener/mediator_thread.h',
+ 'browser/sync/notifier/listener/mediator_thread_impl.cc',
+ 'browser/sync/notifier/listener/mediator_thread_impl.h',
+ 'browser/sync/notifier/listener/mediator_thread_mock.h',
+ 'browser/sync/notifier/listener/send_update_task.cc',
+ 'browser/sync/notifier/listener/send_update_task.h',
+ 'browser/sync/notifier/listener/subscribe_task.cc',
+ 'browser/sync/notifier/listener/subscribe_task.h',
+ 'browser/sync/notifier/listener/talk_mediator.h',
+ 'browser/sync/notifier/listener/talk_mediator_impl.cc',
+ 'browser/sync/notifier/listener/talk_mediator_impl.h',
+ ],
+ 'include_dirs': [
+ '..',
+ '<(protoc_out_dir)',
+ ],
+ 'defines' : [
+ '_CRT_SECURE_NO_WARNINGS',
+ '_USE_32BIT_TIME_T',
+ 'kXmppProductName="chromium-sync"',
+ ],
+ 'dependencies': [
+ '../third_party/expat/expat.gyp:expat',
+ '../third_party/libjingle/libjingle.gyp:libjingle',
+ 'sync_proto',
+ ],
+ 'conditions': [
+ ['OS=="linux"', {
+ 'defines': [
+ 'POSIX',
+ 'OS_LINUX',
+ ],
+ 'dependencies': [
+ '../build/linux/system.gyp:gtk'
+ ],
+ }],
+ ],
+ },
+ {
+ 'target_name': 'sync_unit_tests',
+ 'type': 'executable',
+ 'sources': [
+ 'browser/sync/engine/all_status_unittest.cc',
+ 'browser/sync/engine/apply_updates_command_unittest.cc',
+ 'browser/sync/engine/auth_watcher_unittest.cc',
+ 'browser/sync/engine/net/gaia_authenticator_unittest.cc',
+ 'browser/sync/engine/syncer_proto_util_unittest.cc',
+ 'browser/sync/engine/syncer_thread_unittest.cc',
+ 'browser/sync/engine/syncer_unittest.cc',
+ 'browser/sync/engine/syncproto_unittest.cc',
+ 'browser/sync/notifier/listener/talk_mediator_unittest.cc',
+ 'browser/sync/syncable/syncable_id_unittest.cc',
+ 'browser/sync/syncable/syncable_unittest.cc',
+ 'browser/sync/util/character_set_converters_unittest.cc',
+ 'browser/sync/util/crypto_helpers_unittest.cc',
+ 'browser/sync/util/event_sys_unittest.cc',
+ 'browser/sync/util/highres_timer_unittest.cc',
+ 'browser/sync/util/path_helpers_unittest.cc',
+ 'browser/sync/util/query_helpers_unittest.cc',
+ 'browser/sync/util/user_settings_unittest.cc',
+ 'test/sync/engine/mock_gaia_authenticator.cc',
+ 'test/sync/engine/mock_gaia_authenticator.h',
+ 'test/sync/engine/mock_gaia_authenticator_unittest.cc',
+ 'test/sync/engine/mock_server_connection.cc',
+ 'test/sync/engine/mock_server_connection.h',
+ 'test/sync/engine/test_directory_setter_upper.cc',
+ 'test/sync/engine/test_directory_setter_upper.h',
+ 'test/sync/engine/test_id_factory.h',
+ ],
+ 'include_dirs': [
+ '..',
+ '<(protoc_out_dir)',
+ ],
+ 'defines' : [
+ 'SYNC_ENGINE_VERSION_STRING="Unknown"',
+ '_CRT_SECURE_NO_WARNINGS',
+ '_USE_32BIT_TIME_T',
+ ],
+ 'dependencies': [
+ '../testing/gtest.gyp:gtest',
+ '../third_party/libjingle/libjingle.gyp:libjingle',
+ 'notifier',
+ 'sync',
+ 'sync_proto',
+ 'test_support_unit',
+ ],
+ 'conditions': [
+ ['OS=="win"', {
+ 'sources' : [
+ 'browser/sync/util/data_encryption_unittest.cc',
+ ],
+ 'dependencies': [
+ '../third_party/tcmalloc/tcmalloc.gyp:tcmalloc',
+ ],
+ 'link_settings': {
+ 'libraries': [
+ '-lcrypt32.lib',
+ '-lws2_32.lib',
+ '-lsecur32.lib',
+ ],
+ },
+ }, { # else: OS != "win"
+ 'sources!': [
+ 'browser/sync/util/data_encryption_unittest.cc',
+ ],
+ }],
+ ['OS=="linux"', {
+ 'defines': [
+ 'POSIX',
+ ],
+ 'dependencies': [
+ '../build/linux/system.gyp:gtk'
+ ],
+ }],
+ ],
+ },
+ {
+ 'target_name': 'sync',
+ 'type': '<(library)',
+ 'sources': [
+ '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.cc',
+ '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.h',
+ 'browser/sync/engine/all_status.cc',
+ 'browser/sync/engine/all_status.h',
+ 'browser/sync/engine/apply_updates_command.cc',
+ 'browser/sync/engine/apply_updates_command.h',
+ 'browser/sync/engine/auth_watcher.cc',
+ 'browser/sync/engine/auth_watcher.h',
+ 'browser/sync/engine/authenticator.cc',
+ 'browser/sync/engine/authenticator.h',
+ 'browser/sync/engine/build_and_process_conflict_sets_command.cc',
+ 'browser/sync/engine/build_and_process_conflict_sets_command.h',
+ 'browser/sync/engine/build_commit_command.cc',
+ 'browser/sync/engine/build_commit_command.h',
+ 'browser/sync/engine/change_reorder_buffer.cc',
+ 'browser/sync/engine/change_reorder_buffer.h',
+ 'browser/sync/engine/client_command_channel.h',
+ 'browser/sync/engine/conflict_resolution_view.cc',
+ 'browser/sync/engine/conflict_resolution_view.h',
+ 'browser/sync/engine/conflict_resolver.cc',
+ 'browser/sync/engine/conflict_resolver.h',
+ 'browser/sync/engine/download_updates_command.cc',
+ 'browser/sync/engine/download_updates_command.h',
+ 'browser/sync/engine/get_commit_ids_command.cc',
+ 'browser/sync/engine/get_commit_ids_command.h',
+ 'browser/sync/engine/model_changing_syncer_command.cc',
+ 'browser/sync/engine/model_changing_syncer_command.h',
+ 'browser/sync/engine/model_safe_worker.h',
+ 'browser/sync/engine/net/gaia_authenticator.cc',
+ 'browser/sync/engine/net/gaia_authenticator.h',
+ 'browser/sync/engine/net/http_return.h',
+ 'browser/sync/engine/net/server_connection_manager.cc',
+ 'browser/sync/engine/net/server_connection_manager.h',
+ 'browser/sync/engine/net/syncapi_server_connection_manager.cc',
+ 'browser/sync/engine/net/syncapi_server_connection_manager.h',
+ 'browser/sync/engine/net/url_translator.cc',
+ 'browser/sync/engine/net/url_translator.h',
+ 'browser/sync/engine/post_commit_message_command.cc',
+ 'browser/sync/engine/post_commit_message_command.h',
+ 'browser/sync/engine/process_commit_response_command.cc',
+ 'browser/sync/engine/process_commit_response_command.h',
+ 'browser/sync/engine/process_updates_command.cc',
+ 'browser/sync/engine/process_updates_command.h',
+ 'browser/sync/engine/resolve_conflicts_command.cc',
+ 'browser/sync/engine/resolve_conflicts_command.h',
+ 'browser/sync/engine/sync_cycle_state.h',
+ 'browser/sync/engine/sync_process_state.cc',
+ 'browser/sync/engine/sync_process_state.h',
+ 'browser/sync/engine/syncapi.h',
+ 'browser/sync/engine/syncer.cc',
+ 'browser/sync/engine/syncer.h',
+ 'browser/sync/engine/syncer_command.cc',
+ 'browser/sync/engine/syncer_command.h',
+ 'browser/sync/engine/syncer_end_command.cc',
+ 'browser/sync/engine/syncer_end_command.h',
+ 'browser/sync/engine/syncer_proto_util.cc',
+ 'browser/sync/engine/syncer_proto_util.h',
+ 'browser/sync/engine/syncer_session.h',
+ 'browser/sync/engine/syncer_status.cc',
+ 'browser/sync/engine/syncer_status.h',
+ 'browser/sync/engine/syncer_thread.cc',
+ 'browser/sync/engine/syncer_thread.h',
+ 'browser/sync/engine/syncer_thread_timed_stop.cc',
+ 'browser/sync/engine/syncer_thread_timed_stop.h',
+ 'browser/sync/engine/syncer_types.h',
+ 'browser/sync/engine/syncer_util.cc',
+ 'browser/sync/engine/syncer_util.h',
+ 'browser/sync/engine/syncproto.h',
+ 'browser/sync/engine/update_applicator.cc',
+ 'browser/sync/engine/update_applicator.h',
+ 'browser/sync/engine/verify_updates_command.cc',
+ 'browser/sync/engine/verify_updates_command.h',
+ 'browser/sync/protocol/service_constants.h',
+ 'browser/sync/syncable/blob.h',
+ 'browser/sync/syncable/dir_open_result.h',
+ 'browser/sync/syncable/directory_backing_store.cc',
+ 'browser/sync/syncable/directory_backing_store.h',
+ 'browser/sync/syncable/directory_event.h',
+ 'browser/sync/syncable/directory_manager.cc',
+ 'browser/sync/syncable/directory_manager.h',
+ 'browser/sync/syncable/path_name_cmp.h',
+ 'browser/sync/syncable/syncable-inl.h',
+ 'browser/sync/syncable/syncable.cc',
+ 'browser/sync/syncable/syncable.h',
+ 'browser/sync/syncable/syncable_changes_version.h',
+ 'browser/sync/syncable/syncable_columns.h',
+ 'browser/sync/syncable/syncable_id.cc',
+ 'browser/sync/syncable/syncable_id.h',
+ 'browser/sync/util/character_set_converters.cc',
+ 'browser/sync/util/character_set_converters.h',
+ 'browser/sync/util/character_set_converters_posix.cc',
+ 'browser/sync/util/character_set_converters_win.cc',
+ 'browser/sync/util/closure.h',
+ 'browser/sync/util/compat_file.h',
+ 'browser/sync/util/compat_file_posix.cc',
+ 'browser/sync/util/compat_file_win.cc',
+ 'browser/sync/util/crypto_helpers.cc',
+ 'browser/sync/util/crypto_helpers.h',
+ 'browser/sync/util/dbgq.h',
+ 'browser/sync/util/event_sys-inl.h',
+ 'browser/sync/util/event_sys.h',
+ 'browser/sync/util/fast_dump.h',
+ 'browser/sync/util/highres_timer.h',
+ 'browser/sync/util/highres_timer_linux.cc',
+ 'browser/sync/util/highres_timer_linux.h',
+ 'browser/sync/util/highres_timer_mac.cc',
+ 'browser/sync/util/highres_timer_mac.h',
+ 'browser/sync/util/highres_timer_win.cc',
+ 'browser/sync/util/highres_timer_win.h',
+ 'browser/sync/util/path_helpers.h',
+ 'browser/sync/util/path_helpers_linux.cc',
+ 'browser/sync/util/path_helpers_mac.cc',
+ 'browser/sync/util/path_helpers_posix.cc',
+ 'browser/sync/util/query_helpers.cc',
+ 'browser/sync/util/query_helpers.h',
+ 'browser/sync/util/row_iterator.h',
+ 'browser/sync/util/signin.h',
+ 'browser/sync/util/sync_types.h',
+ 'browser/sync/util/user_settings.cc',
+ 'browser/sync/util/user_settings.h',
+ 'browser/sync/util/user_settings_posix.cc',
+ 'browser/sync/util/user_settings_win.cc',
+ ],
+ 'include_dirs': [
+ '..',
+ '<(protoc_out_dir)',
+ ],
+ 'defines' : [
+ 'SYNC_ENGINE_VERSION_STRING="Unknown"',
+ '_CRT_SECURE_NO_WARNINGS',
+ '_USE_32BIT_TIME_T',
+ ],
+ 'dependencies': [
+ '../third_party/libjingle/libjingle.gyp:libjingle',
+ 'sync_proto',
+ ],
+ 'conditions': [
+ ['OS=="win"', {
+ 'sources' : [
+ 'browser/sync/util/data_encryption.cc',
+ 'browser/sync/util/data_encryption.h',
+ 'browser/sync/util/path_helpers.cc',
+ ],
+ }],
+ ['OS=="linux"', {
+ 'defines': [
+ 'POSIX',
+ ],
+ 'dependencies': [
+ '../build/linux/system.gyp:gtk'
+ ],
+ }],
+ ['OS=="mac"', {
+ 'link_settings': {
+ 'libraries': [
+ '$(SDKROOT)/System/Library/Frameworks/IOKit.framework',
+ ],
+ },
+ }],
+ ],
+ },
],
'conditions': [
['OS=="mac" or OS=="win"', {
@@ -6579,391 +6944,6 @@
},
]
}],
- ['browser_sync==1', {
- # These targets get built only where sync is supported.
- 'targets': [
- {
- # Protobuf compiler / generate rule for sync.proto
- 'target_name': 'sync_proto',
- 'type': 'none',
- 'actions': [
- {
- 'action_name': 'compiling sync.proto',
- 'inputs': [
- '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)protoc<(EXECUTABLE_SUFFIX)',
- 'browser/sync/protocol/sync.proto',
- ],
- 'outputs': [
- '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.cc',
- '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.h',
- ],
- 'action': [
- '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)protoc<(EXECUTABLE_SUFFIX)',
- '--proto_path=browser/sync/protocol',
- 'browser/sync/protocol/sync.proto',
- '--cpp_out=<(protoc_out_dir)/chrome/browser/sync/protocol',
- ],
- },
- ],
- 'dependencies': [
- '../third_party/protobuf2/protobuf.gyp:protobuf_lite',
- '../third_party/protobuf2/protobuf.gyp:protoc',
- ],
- 'export_dependent_settings': [
- '../third_party/protobuf2/protobuf.gyp:protobuf_lite',
- ],
- },
- {
- 'target_name': 'notifier',
- 'type': '<(library)',
- 'sources': [
- 'browser/sync/notifier/base/async_dns_lookup.cc',
- 'browser/sync/notifier/base/async_dns_lookup.h',
- 'browser/sync/notifier/base/async_network_alive.h',
- 'browser/sync/notifier/base/fastalloc.h',
- 'browser/sync/notifier/base/linux/network_status_detector_task_linux.cc',
- 'browser/sync/notifier/base/linux/time_linux.cc',
- 'browser/sync/notifier/base/mac/network_status_detector_task_mac.cc',
- 'browser/sync/notifier/base/mac/time_mac.cc',
- 'browser/sync/notifier/base/nethelpers.cc',
- 'browser/sync/notifier/base/nethelpers.h',
- 'browser/sync/notifier/base/network_status_detector_task.cc',
- 'browser/sync/notifier/base/network_status_detector_task.h',
- 'browser/sync/notifier/base/network_status_detector_task_mt.cc',
- 'browser/sync/notifier/base/network_status_detector_task_mt.h',
- 'browser/sync/notifier/base/posix/time_posix.cc',
- 'browser/sync/notifier/base/signal_thread_task.h',
- 'browser/sync/notifier/base/static_assert.h',
- 'browser/sync/notifier/base/task_pump.cc',
- 'browser/sync/notifier/base/task_pump.h',
- 'browser/sync/notifier/base/time.cc',
- 'browser/sync/notifier/base/time.h',
- 'browser/sync/notifier/base/timer.cc',
- 'browser/sync/notifier/base/timer.h',
- 'browser/sync/notifier/base/utils.h',
- 'browser/sync/notifier/base/win/async_network_alive_win32.cc',
- 'browser/sync/notifier/base/win/time_win32.cc',
- 'browser/sync/notifier/communicator/auth_task.cc',
- 'browser/sync/notifier/communicator/auth_task.h',
- 'browser/sync/notifier/communicator/auto_reconnect.cc',
- 'browser/sync/notifier/communicator/auto_reconnect.h',
- 'browser/sync/notifier/communicator/connection_options.cc',
- 'browser/sync/notifier/communicator/connection_options.h',
- 'browser/sync/notifier/communicator/connection_settings.cc',
- 'browser/sync/notifier/communicator/connection_settings.h',
- 'browser/sync/notifier/communicator/const_communicator.h',
- 'browser/sync/notifier/communicator/login.cc',
- 'browser/sync/notifier/communicator/login.h',
- 'browser/sync/notifier/communicator/login_failure.cc',
- 'browser/sync/notifier/communicator/login_failure.h',
- 'browser/sync/notifier/communicator/login_settings.cc',
- 'browser/sync/notifier/communicator/login_settings.h',
- 'browser/sync/notifier/communicator/product_info.cc',
- 'browser/sync/notifier/communicator/product_info.h',
- 'browser/sync/notifier/communicator/single_login_attempt.cc',
- 'browser/sync/notifier/communicator/single_login_attempt.h',
- 'browser/sync/notifier/communicator/ssl_socket_adapter.cc',
- 'browser/sync/notifier/communicator/ssl_socket_adapter.h',
- 'browser/sync/notifier/communicator/talk_auth_task.cc',
- 'browser/sync/notifier/communicator/talk_auth_task.h',
- 'browser/sync/notifier/communicator/xmpp_connection_generator.cc',
- 'browser/sync/notifier/communicator/xmpp_connection_generator.h',
- 'browser/sync/notifier/communicator/xmpp_log.cc',
- 'browser/sync/notifier/communicator/xmpp_log.h',
- 'browser/sync/notifier/communicator/xmpp_socket_adapter.cc',
- 'browser/sync/notifier/communicator/xmpp_socket_adapter.h',
- 'browser/sync/notifier/gaia_auth/gaiaauth.cc',
- 'browser/sync/notifier/gaia_auth/gaiaauth.h',
- 'browser/sync/notifier/gaia_auth/gaiahelper.cc',
- 'browser/sync/notifier/gaia_auth/gaiahelper.h',
- 'browser/sync/notifier/gaia_auth/inet_aton.h',
- 'browser/sync/notifier/gaia_auth/sigslotrepeater.h',
- 'browser/sync/notifier/gaia_auth/win/win32window.cc',
- 'browser/sync/notifier/listener/listen_task.cc',
- 'browser/sync/notifier/listener/listen_task.h',
- 'browser/sync/notifier/listener/mediator_thread.h',
- 'browser/sync/notifier/listener/mediator_thread_impl.cc',
- 'browser/sync/notifier/listener/mediator_thread_impl.h',
- 'browser/sync/notifier/listener/mediator_thread_mock.h',
- 'browser/sync/notifier/listener/send_update_task.cc',
- 'browser/sync/notifier/listener/send_update_task.h',
- 'browser/sync/notifier/listener/subscribe_task.cc',
- 'browser/sync/notifier/listener/subscribe_task.h',
- 'browser/sync/notifier/listener/talk_mediator.h',
- 'browser/sync/notifier/listener/talk_mediator_impl.cc',
- 'browser/sync/notifier/listener/talk_mediator_impl.h',
- ],
- 'include_dirs': [
- '..',
- '<(protoc_out_dir)',
- ],
- 'defines' : [
- '_CRT_SECURE_NO_WARNINGS',
- '_USE_32BIT_TIME_T',
- 'kXmppProductName="chromium-sync"',
- ],
- 'dependencies': [
- '../third_party/expat/expat.gyp:expat',
- '../third_party/libjingle/libjingle.gyp:libjingle',
- 'sync_proto',
- ],
- 'conditions': [
- ['OS=="linux"', {
- 'defines': [
- 'POSIX',
- 'OS_LINUX',
- ],
- 'dependencies': [
- '../build/linux/system.gyp:gtk'
- ],
- }],
- ],
- },
- {
- 'target_name': 'sync_unit_tests',
- 'type': 'executable',
- 'sources': [
- 'browser/sync/engine/all_status_unittest.cc',
- 'browser/sync/engine/apply_updates_command_unittest.cc',
- 'browser/sync/engine/auth_watcher_unittest.cc',
- 'browser/sync/engine/net/gaia_authenticator_unittest.cc',
- 'browser/sync/engine/syncer_proto_util_unittest.cc',
- 'browser/sync/engine/syncer_thread_unittest.cc',
- 'browser/sync/engine/syncer_unittest.cc',
- 'browser/sync/engine/syncproto_unittest.cc',
- 'browser/sync/notifier/listener/talk_mediator_unittest.cc',
- 'browser/sync/syncable/syncable_id_unittest.cc',
- 'browser/sync/syncable/syncable_unittest.cc',
- 'browser/sync/util/character_set_converters_unittest.cc',
- 'browser/sync/util/crypto_helpers_unittest.cc',
- 'browser/sync/util/event_sys_unittest.cc',
- 'browser/sync/util/highres_timer_unittest.cc',
- 'browser/sync/util/path_helpers_unittest.cc',
- 'browser/sync/util/query_helpers_unittest.cc',
- 'browser/sync/util/user_settings_unittest.cc',
- 'test/sync/engine/mock_gaia_authenticator.cc',
- 'test/sync/engine/mock_gaia_authenticator.h',
- 'test/sync/engine/mock_gaia_authenticator_unittest.cc',
- 'test/sync/engine/mock_server_connection.cc',
- 'test/sync/engine/mock_server_connection.h',
- 'test/sync/engine/test_directory_setter_upper.cc',
- 'test/sync/engine/test_directory_setter_upper.h',
- 'test/sync/engine/test_id_factory.h',
- ],
- 'include_dirs': [
- '..',
- '<(protoc_out_dir)',
- ],
- 'defines' : [
- 'SYNC_ENGINE_VERSION_STRING="Unknown"',
- '_CRT_SECURE_NO_WARNINGS',
- '_USE_32BIT_TIME_T',
- ],
- 'dependencies': [
- '../testing/gtest.gyp:gtest',
- '../third_party/libjingle/libjingle.gyp:libjingle',
- 'notifier',
- 'sync',
- 'sync_proto',
- 'test_support_unit',
- ],
- 'conditions': [
- ['OS=="win"', {
- 'sources' : [
- 'browser/sync/util/data_encryption_unittest.cc',
- ],
- 'dependencies': [
- '../third_party/tcmalloc/tcmalloc.gyp:tcmalloc',
- ],
- 'link_settings': {
- 'libraries': [
- '-lcrypt32.lib',
- '-lws2_32.lib',
- '-lsecur32.lib',
- ],
- },
- }, { # else: OS != "win"
- 'sources!': [
- 'browser/sync/util/data_encryption_unittest.cc',
- ],
- }],
- ['OS=="linux"', {
- 'defines': [
- 'POSIX',
- ],
- 'dependencies': [
- '../build/linux/system.gyp:gtk'
- ],
- }],
- ],
- },
- {
- 'target_name': 'sync',
- 'type': '<(library)',
- 'sources': [
- '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.cc',
- '<(protoc_out_dir)/chrome/browser/sync/protocol/sync.pb.h',
- 'browser/sync/engine/all_status.cc',
- 'browser/sync/engine/all_status.h',
- 'browser/sync/engine/apply_updates_command.cc',
- 'browser/sync/engine/apply_updates_command.h',
- 'browser/sync/engine/auth_watcher.cc',
- 'browser/sync/engine/auth_watcher.h',
- 'browser/sync/engine/authenticator.cc',
- 'browser/sync/engine/authenticator.h',
- 'browser/sync/engine/build_and_process_conflict_sets_command.cc',
- 'browser/sync/engine/build_and_process_conflict_sets_command.h',
- 'browser/sync/engine/build_commit_command.cc',
- 'browser/sync/engine/build_commit_command.h',
- 'browser/sync/engine/change_reorder_buffer.cc',
- 'browser/sync/engine/change_reorder_buffer.h',
- 'browser/sync/engine/client_command_channel.h',
- 'browser/sync/engine/conflict_resolution_view.cc',
- 'browser/sync/engine/conflict_resolution_view.h',
- 'browser/sync/engine/conflict_resolver.cc',
- 'browser/sync/engine/conflict_resolver.h',
- 'browser/sync/engine/download_updates_command.cc',
- 'browser/sync/engine/download_updates_command.h',
- 'browser/sync/engine/get_commit_ids_command.cc',
- 'browser/sync/engine/get_commit_ids_command.h',
- 'browser/sync/engine/model_changing_syncer_command.cc',
- 'browser/sync/engine/model_changing_syncer_command.h',
- 'browser/sync/engine/model_safe_worker.h',
- 'browser/sync/engine/net/gaia_authenticator.cc',
- 'browser/sync/engine/net/gaia_authenticator.h',
- 'browser/sync/engine/net/http_return.h',
- 'browser/sync/engine/net/server_connection_manager.cc',
- 'browser/sync/engine/net/server_connection_manager.h',
- 'browser/sync/engine/net/syncapi_server_connection_manager.cc',
- 'browser/sync/engine/net/syncapi_server_connection_manager.h',
- 'browser/sync/engine/net/url_translator.cc',
- 'browser/sync/engine/net/url_translator.h',
- 'browser/sync/engine/post_commit_message_command.cc',
- 'browser/sync/engine/post_commit_message_command.h',
- 'browser/sync/engine/process_commit_response_command.cc',
- 'browser/sync/engine/process_commit_response_command.h',
- 'browser/sync/engine/process_updates_command.cc',
- 'browser/sync/engine/process_updates_command.h',
- 'browser/sync/engine/resolve_conflicts_command.cc',
- 'browser/sync/engine/resolve_conflicts_command.h',
- 'browser/sync/engine/sync_cycle_state.h',
- 'browser/sync/engine/sync_process_state.cc',
- 'browser/sync/engine/sync_process_state.h',
- 'browser/sync/engine/syncapi.h',
- 'browser/sync/engine/syncer.cc',
- 'browser/sync/engine/syncer.h',
- 'browser/sync/engine/syncer_command.cc',
- 'browser/sync/engine/syncer_command.h',
- 'browser/sync/engine/syncer_end_command.cc',
- 'browser/sync/engine/syncer_end_command.h',
- 'browser/sync/engine/syncer_proto_util.cc',
- 'browser/sync/engine/syncer_proto_util.h',
- 'browser/sync/engine/syncer_session.h',
- 'browser/sync/engine/syncer_status.cc',
- 'browser/sync/engine/syncer_status.h',
- 'browser/sync/engine/syncer_thread.cc',
- 'browser/sync/engine/syncer_thread.h',
- 'browser/sync/engine/syncer_thread_timed_stop.cc',
- 'browser/sync/engine/syncer_thread_timed_stop.h',
- 'browser/sync/engine/syncer_types.h',
- 'browser/sync/engine/syncer_util.cc',
- 'browser/sync/engine/syncer_util.h',
- 'browser/sync/engine/syncproto.h',
- 'browser/sync/engine/update_applicator.cc',
- 'browser/sync/engine/update_applicator.h',
- 'browser/sync/engine/verify_updates_command.cc',
- 'browser/sync/engine/verify_updates_command.h',
- 'browser/sync/protocol/service_constants.h',
- 'browser/sync/syncable/blob.h',
- 'browser/sync/syncable/dir_open_result.h',
- 'browser/sync/syncable/directory_backing_store.cc',
- 'browser/sync/syncable/directory_backing_store.h',
- 'browser/sync/syncable/directory_event.h',
- 'browser/sync/syncable/directory_manager.cc',
- 'browser/sync/syncable/directory_manager.h',
- 'browser/sync/syncable/path_name_cmp.h',
- 'browser/sync/syncable/syncable-inl.h',
- 'browser/sync/syncable/syncable.cc',
- 'browser/sync/syncable/syncable.h',
- 'browser/sync/syncable/syncable_changes_version.h',
- 'browser/sync/syncable/syncable_columns.h',
- 'browser/sync/syncable/syncable_id.cc',
- 'browser/sync/syncable/syncable_id.h',
- 'browser/sync/util/character_set_converters.cc',
- 'browser/sync/util/character_set_converters.h',
- 'browser/sync/util/character_set_converters_posix.cc',
- 'browser/sync/util/character_set_converters_win.cc',
- 'browser/sync/util/closure.h',
- 'browser/sync/util/compat_file.h',
- 'browser/sync/util/compat_file_posix.cc',
- 'browser/sync/util/compat_file_win.cc',
- 'browser/sync/util/crypto_helpers.cc',
- 'browser/sync/util/crypto_helpers.h',
- 'browser/sync/util/dbgq.h',
- 'browser/sync/util/event_sys-inl.h',
- 'browser/sync/util/event_sys.h',
- 'browser/sync/util/fast_dump.h',
- 'browser/sync/util/highres_timer.h',
- 'browser/sync/util/highres_timer_linux.cc',
- 'browser/sync/util/highres_timer_linux.h',
- 'browser/sync/util/highres_timer_mac.cc',
- 'browser/sync/util/highres_timer_mac.h',
- 'browser/sync/util/highres_timer_win.cc',
- 'browser/sync/util/highres_timer_win.h',
- 'browser/sync/util/path_helpers.h',
- 'browser/sync/util/path_helpers_linux.cc',
- 'browser/sync/util/path_helpers_mac.cc',
- 'browser/sync/util/path_helpers_posix.cc',
- 'browser/sync/util/query_helpers.cc',
- 'browser/sync/util/query_helpers.h',
- 'browser/sync/util/row_iterator.h',
- 'browser/sync/util/signin.h',
- 'browser/sync/util/sync_types.h',
- 'browser/sync/util/user_settings.cc',
- 'browser/sync/util/user_settings.h',
- 'browser/sync/util/user_settings_posix.cc',
- 'browser/sync/util/user_settings_win.cc',
- ],
- 'include_dirs': [
- '..',
- '<(protoc_out_dir)',
- ],
- 'defines' : [
- 'SYNC_ENGINE_VERSION_STRING="Unknown"',
- '_CRT_SECURE_NO_WARNINGS',
- '_USE_32BIT_TIME_T',
- ],
- 'dependencies': [
- '../third_party/libjingle/libjingle.gyp:libjingle',
- 'sync_proto',
- ],
- 'conditions': [
- ['OS=="win"', {
- 'sources' : [
- 'browser/sync/util/data_encryption.cc',
- 'browser/sync/util/data_encryption.h',
- 'browser/sync/util/path_helpers.cc',
- ],
- }],
- ['OS=="linux"', {
- 'defines': [
- 'POSIX',
- ],
- 'dependencies': [
- '../build/linux/system.gyp:gtk'
- ],
- }],
- ['OS=="mac"', {
- 'link_settings': {
- 'libraries': [
- '$(SDKROOT)/System/Library/Frameworks/IOKit.framework',
- ],
- },
- }],
- ],
- },
- ], # targets when browser_sync==1
- }],
], # 'conditions'
}
diff --git a/chrome/test/live_sync/bookmark_model_verifier.cc b/chrome/test/live_sync/bookmark_model_verifier.cc
index 7face7b..8dd0164 100644
--- a/chrome/test/live_sync/bookmark_model_verifier.cc
+++ b/chrome/test/live_sync/bookmark_model_verifier.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "chrome/test/live_sync/bookmark_model_verifier.h"
#include <vector>
@@ -251,5 +249,3 @@ const BookmarkNode* BookmarkModelVerifier::SetURL(BookmarkModel* model,
BookmarkEditor::EditDetails(v_node), v_node->GetTitle(), new_url, NULL);
return result;
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/bookmark_model_verifier.h b/chrome/test/live_sync/bookmark_model_verifier.h
index de6d4c7..9961f3a5 100644
--- a/chrome/test/live_sync/bookmark_model_verifier.h
+++ b/chrome/test/live_sync/bookmark_model_verifier.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_TEST_LIVE_SYNC_BOOKMARK_MODEL_VERIFIER_H_
#define CHROME_TEST_LIVE_SYNC_BOOKMARK_MODEL_VERIFIER_H_
@@ -112,5 +110,3 @@ class BookmarkModelVerifier {
};
#endif // CHROME_TEST_LIVE_SYNC_BOOKMARK_MODEL_VERIFIER_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/live_bookmarks_sync_test.cc b/chrome/test/live_sync/live_bookmarks_sync_test.cc
index 6189965..59b99c2 100644
--- a/chrome/test/live_sync/live_bookmarks_sync_test.cc
+++ b/chrome/test/live_sync/live_bookmarks_sync_test.cc
@@ -1,7 +1,6 @@
// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
#include "chrome/test/live_sync/live_bookmarks_sync_test.h"
@@ -95,5 +94,3 @@ void LiveBookmarksSyncTest::SetUpInProcessBrowserTestFixture() {
void LiveBookmarksSyncTest::TearDownInProcessBrowserTestFixture() {
mock_host_resolver_override_.reset();
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/live_bookmarks_sync_test.h b/chrome/test/live_sync/live_bookmarks_sync_test.h
index f23a117..1502569 100644
--- a/chrome/test/live_sync/live_bookmarks_sync_test.h
+++ b/chrome/test/live_sync/live_bookmarks_sync_test.h
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#ifndef CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_
#define CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_
@@ -81,5 +79,3 @@ class LiveBookmarksSyncTest : public InProcessBrowserTest {
};
#endif // CHROME_TEST_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/profile_sync_service_test_harness.cc b/chrome/test/live_sync/profile_sync_service_test_harness.cc
index 738654d..d047151 100644
--- a/chrome/test/live_sync/profile_sync_service_test_harness.cc
+++ b/chrome/test/live_sync/profile_sync_service_test_harness.cc
@@ -1,7 +1,6 @@
// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
#include "base/message_loop.h"
#include "chrome/browser/browser.h"
@@ -249,5 +248,3 @@ bool ProfileSyncServiceTestHarness::WaitForServiceInit() {
}
return service_->sync_initialized();
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/profile_sync_service_test_harness.h b/chrome/test/live_sync/profile_sync_service_test_harness.h
index ff51bd1..f242be3 100644
--- a/chrome/test/live_sync/profile_sync_service_test_harness.h
+++ b/chrome/test/live_sync/profile_sync_service_test_harness.h
@@ -1,7 +1,6 @@
// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
#ifndef CHROME_TEST_LIVE_SYNC_PROFILE_SYNC_SERVICE_TEST_HARNESS_H_
#define CHROME_TEST_LIVE_SYNC_PROFILE_SYNC_SERVICE_TEST_HARNESS_H_
@@ -107,5 +106,3 @@ class ProfileSyncServiceTestHarness : public ProfileSyncServiceObserver {
};
#endif // CHROME_TEST_SYNC_PROFILE_SYNC_SERVICE_TEST_HARNESS_H_
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/single_client_live_bookmarks_sync_unittest.cc b/chrome/test/live_sync/single_client_live_bookmarks_sync_unittest.cc
index 8e751cf..5e81e23 100644
--- a/chrome/test/live_sync/single_client_live_bookmarks_sync_unittest.cc
+++ b/chrome/test/live_sync/single_client_live_bookmarks_sync_unittest.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include "base/command_line.h"
#include "chrome/browser/bookmarks/bookmark_model.h"
#include "chrome/browser/browser.h"
@@ -152,5 +150,3 @@ IN_PROC_BROWSER_TEST_F(SingleClientLiveBookmarksSyncTest, DISABLED_GetUpdates) {
EXPECT_EQ(status.summary, ProfileSyncService::Status::READY);
EXPECT_EQ(status.unsynced_count, 0);
}
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/live_sync/two_client_live_bookmarks_sync_test.cc b/chrome/test/live_sync/two_client_live_bookmarks_sync_test.cc
index 49abebf..f82ee85 100644
--- a/chrome/test/live_sync/two_client_live_bookmarks_sync_test.cc
+++ b/chrome/test/live_sync/two_client_live_bookmarks_sync_test.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if defined(BROWSER_SYNC)
-
#include <stdlib.h>
#include "base/string16.h"
@@ -2483,6 +2481,3 @@ IN_PROC_BROWSER_TEST_F(TwoClientLiveBookmarksSyncTest,
Cleanup();
}
-
-
-#endif // defined(BROWSER_SYNC)
diff --git a/chrome/test/sync/test_http_bridge_factory.h b/chrome/test/sync/test_http_bridge_factory.h
index 83ad6c4..21f24d7 100644
--- a/chrome/test/sync/test_http_bridge_factory.h
+++ b/chrome/test/sync/test_http_bridge_factory.h
@@ -5,8 +5,6 @@
#ifndef CHROME_TEST_SYNC_TEST_HTTP_BRIDGE_FACTORY_H_
#define CHROME_TEST_SYNC_TEST_HTTP_BRIDGE_FACTORY_H_
-#if defined(BROWSER_SYNC)
-
#include "chrome/browser/sync/engine/syncapi.h"
namespace browser_sync {
@@ -64,6 +62,4 @@ class TestHttpBridgeFactory : public sync_api::HttpPostProviderFactory {
} // namespace browser_sync
-
-#endif // defined(BROWSER_SYNC)
#endif // CHROME_TEST_SYNC_TEST_HTTP_BRIDGE_FACTORY_H_
diff --git a/chrome/test/testing_profile.cc b/chrome/test/testing_profile.cc
index 460b3c5..e787a6b 100644
--- a/chrome/test/testing_profile.cc
+++ b/chrome/test/testing_profile.cc
@@ -202,17 +202,12 @@ void TestingProfile::BlockUntilHistoryProcessesPendingRequests() {
}
void TestingProfile::CreateProfileSyncService() {
-#if defined(BROWSER_SYNC)
if (!profile_sync_service_.get()) {
profile_sync_service_.reset(new ProfileSyncService(this));
profile_sync_service_->Initialize();
}
-#endif
}
ProfileSyncService* TestingProfile::GetProfileSyncService() {
-#if defined(BROWSER_SYNC)
return profile_sync_service_.get();
-#endif
- return NULL;
}
diff --git a/chrome/test/testing_profile.h b/chrome/test/testing_profile.h
index 2aa3971..8791295 100644
--- a/chrome/test/testing_profile.h
+++ b/chrome/test/testing_profile.h
@@ -209,9 +209,7 @@ class TestingProfile : public Profile {
scoped_ptr<BookmarkModel> bookmark_bar_model_;
// The ProfileSyncService. Created by CreateProfileSyncService.
-#if defined(BROWSER_SYNC)
scoped_ptr<ProfileSyncService> profile_sync_service_;
-#endif
// The TemplateURLFetcher. Only created if CreateTemplateURLModel is invoked.
scoped_ptr<TemplateURLModel> template_url_model_;