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

Unified Diff: chrome/browser/undo/undo_manager_utils.h

Issue 19287013: Bookmark Undo service for multiple level undo/redo of bookmarks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 5 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
Index: chrome/browser/undo/undo_manager_utils.h
diff --git a/chrome/browser/undo/undo_manager_utils.h b/chrome/browser/undo/undo_manager_utils.h
new file mode 100644
index 0000000000000000000000000000000000000000..ae740b26efb8e8912fe93c60d77c3124a534c879
--- /dev/null
+++ b/chrome/browser/undo/undo_manager_utils.h
@@ -0,0 +1,41 @@
+// Copyright 2013 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.
+
+#ifndef CHROME_BROWSER_UNDO_UNDO_MANAGER_UTILS_H_
+#define CHROME_BROWSER_UNDO_UNDO_MANAGER_UTILS_H_
+
+#include "base/basictypes.h"
+
+class UndoManager;
+
+// ScopedSuspendUndoTracking --------------------------------------------------
+
+// Scopes the suspension of the undo tracking for non-user initiated changes
+// such as those occuring during profile synchronization.
+class ScopedSuspendUndoTracking {
+ public:
+ explicit ScopedSuspendUndoTracking(UndoManager* undo_manager);
+ ~ScopedSuspendUndoTracking();
+
+ private:
+ UndoManager* undo_manager_;
+
+ DISALLOW_COPY_AND_ASSIGN(ScopedSuspendUndoTracking);
+};
+
+// ScopedGroupingAction -------------------------------------------------------
+
+// Scopes the grouping of a set of changes into one undoable action.
+class ScopedGroupingAction {
+ public:
+ explicit ScopedGroupingAction(UndoManager* undo_manager);
+ ~ScopedGroupingAction();
+
+ private:
+ UndoManager* undo_manager_;
+
+ DISALLOW_COPY_AND_ASSIGN(ScopedGroupingAction);
+};
+
+#endif // CHROME_BROWSER_UNDO_UNDO_MANAGER_UTILS_H_

Powered by Google App Engine
This is Rietveld 408576698