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

Unified Diff: chrome/browser/sync/js_directory_change_listener.cc

Issue 7190001: [Sync] Split DirectoryChangeListener for thread-safety (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix copyright Created 9 years, 6 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/sync/js_directory_change_listener.h ('k') | chrome/browser/sync/js_transaction_observer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/js_directory_change_listener.cc
diff --git a/chrome/browser/sync/js_directory_change_listener.cc b/chrome/browser/sync/js_directory_change_listener.cc
deleted file mode 100644
index 9d60885f533b50a441c934b4f90b794bbbc6ea3b..0000000000000000000000000000000000000000
--- a/chrome/browser/sync/js_directory_change_listener.cc
+++ /dev/null
@@ -1,61 +0,0 @@
-// Copyright (c) 2011 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.
-
-#include "chrome/browser/sync/js_directory_change_listener.h"
-
-#include "base/logging.h"
-#include "base/values.h"
-#include "chrome/browser/sync/js_event_details.h"
-#include "chrome/browser/sync/js_event_router.h"
-
-namespace browser_sync {
-
-JsDirectoryChangeListener::JsDirectoryChangeListener(
- JsEventRouter* parent_router)
- : parent_router_(parent_router) {
- DCHECK(parent_router_);
-}
-
-JsDirectoryChangeListener::~JsDirectoryChangeListener() {}
-
-void JsDirectoryChangeListener::HandleCalculateChangesChangeEventFromSyncApi(
- const syncable::OriginalEntries& originals,
- const syncable::WriterTag& writer,
- syncable::BaseTransaction* trans) {
- DictionaryValue details;
- details.Set("originals", syncable::OriginalEntriesToValue(originals));
- details.SetString("writer", syncable::WriterTagToString(writer));
- parent_router_->RouteJsEvent("handleCalculateChangesChangeEventFromSyncApi",
- JsEventDetails(&details));
-}
-
-void JsDirectoryChangeListener::HandleCalculateChangesChangeEventFromSyncer(
- const syncable::OriginalEntries& originals,
- const syncable::WriterTag& writer,
- syncable::BaseTransaction* trans) {
- DictionaryValue details;
- details.Set("originals", syncable::OriginalEntriesToValue(originals));
- details.SetString("writer", syncable::WriterTagToString(writer));
- parent_router_->RouteJsEvent("handleCalculateChangesChangeEventFromSyncer",
- JsEventDetails(&details));
-}
-
-syncable::ModelTypeBitSet
- JsDirectoryChangeListener::HandleTransactionEndingChangeEvent(
- syncable::BaseTransaction* trans) {
- parent_router_->RouteJsEvent("handleTransactionEndingChangeEvent",
- JsEventDetails());
- return syncable::ModelTypeBitSet();
-}
-
-void JsDirectoryChangeListener::HandleTransactionCompleteChangeEvent(
- const syncable::ModelTypeBitSet& models_with_changes) {
- DictionaryValue details;
- details.Set("modelsWithChanges",
- syncable::ModelTypeBitSetToValue(models_with_changes));
- parent_router_->RouteJsEvent("handleTransactionCompleteChangeEvent",
- JsEventDetails(&details));
-}
-
-} // namespace browser_sync
« no previous file with comments | « chrome/browser/sync/js_directory_change_listener.h ('k') | chrome/browser/sync/js_transaction_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698