summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync/sessions/sync_session_context.h
diff options
context:
space:
mode:
authorerg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-04 23:11:19 +0000
committererg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-04 23:11:19 +0000
commit9b2331d912b0a15c3eef290eaa617c54a87dc68e (patch)
tree6ca5f0248ce754b74b39112c17c2d9726c004e79 /chrome/browser/sync/sessions/sync_session_context.h
parent9f1e5d235d5bdb3a0fe626fe47f5468cddaf75e4 (diff)
downloadchromium_src-9b2331d912b0a15c3eef290eaa617c54a87dc68e.zip
chromium_src-9b2331d912b0a15c3eef290eaa617c54a87dc68e.tar.gz
chromium_src-9b2331d912b0a15c3eef290eaa617c54a87dc68e.tar.bz2
Reapply r61237: FBTF: Another big ctor/dtor cleanup found by automated tools.
Removes changes to code in webkit/ that broke chrome_frame. Will debug that portion later. (Shaves ~2MB off Linux Debug .a files) BUG=none TEST=compiles First Review URL: http://codereview.chromium.org/3563004 Review URL: http://codereview.chromium.org/3621003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@61435 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync/sessions/sync_session_context.h')
-rw-r--r--chrome/browser/sync/sessions/sync_session_context.h29
1 files changed, 7 insertions, 22 deletions
diff --git a/chrome/browser/sync/sessions/sync_session_context.h b/chrome/browser/sync/sessions/sync_session_context.h
index 4c6b63f..b782876 100644
--- a/chrome/browser/sync/sessions/sync_session_context.h
+++ b/chrome/browser/sync/sessions/sync_session_context.h
@@ -20,10 +20,10 @@
#pragma once
#include <string>
-#include "chrome/browser/chrome_thread.h"
+
+#include "base/scoped_ptr.h"
#include "chrome/browser/sync/engine/model_safe_worker.h"
#include "chrome/browser/sync/engine/syncer_types.h"
-#include "chrome/browser/sync/util/extensions_activity_monitor.h"
namespace syncable {
class DirectoryManager;
@@ -32,34 +32,21 @@ class DirectoryManager;
namespace browser_sync {
class ConflictResolver;
+class ExtensionsActivityMonitor;
class ModelSafeWorkerRegistrar;
class ServerConnectionManager;
namespace sessions {
class ScopedSessionContextConflictResolver;
class ScopedSessionContextSyncerEventChannel;
+struct SyncSessionSnapshot;
class SyncSessionContext {
public:
SyncSessionContext(ServerConnectionManager* connection_manager,
syncable::DirectoryManager* directory_manager,
- ModelSafeWorkerRegistrar* model_safe_worker_registrar)
- : resolver_(NULL),
- syncer_event_channel_(NULL),
- connection_manager_(connection_manager),
- directory_manager_(directory_manager),
- registrar_(model_safe_worker_registrar),
- extensions_activity_monitor_(new ExtensionsActivityMonitor()),
- notifications_enabled_(false) {
- }
-
- ~SyncSessionContext() {
- // In unittests, there may be no UI thread, so the above will fail.
- if (!ChromeThread::DeleteSoon(ChromeThread::UI, FROM_HERE,
- extensions_activity_monitor_)) {
- delete extensions_activity_monitor_;
- }
- }
+ ModelSafeWorkerRegistrar* model_safe_worker_registrar);
+ ~SyncSessionContext();
ConflictResolver* resolver() { return resolver_; }
ServerConnectionManager* connection_manager() {
@@ -103,9 +90,7 @@ class SyncSessionContext {
return previous_session_snapshot_.get();
}
- void set_last_snapshot(const SyncSessionSnapshot& snapshot) {
- previous_session_snapshot_.reset(new SyncSessionSnapshot(snapshot));
- }
+ void set_last_snapshot(const SyncSessionSnapshot& snapshot);
private:
// Rather than force clients to set and null-out various context members, we