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

Side by Side Diff: chrome/browser/undo/undo_manager_utils.h

Issue 20571004: Helper classes to scope undo action. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/undo/undo_manager_utils.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UNDO_UNDO_MANAGER_UTILS_H_
6 #define CHROME_BROWSER_UNDO_UNDO_MANAGER_UTILS_H_
7
8 #include "base/basictypes.h"
9
10 class UndoManager;
11
12 // ScopedSuspendUndoTracking ---------------------------------------------------
13
14 // Scopes the suspension of the undo tracking for non-user initiated changes
15 // such as those occuring during profile synchronization.
16 class ScopedSuspendUndoTracking {
17 public:
18 explicit ScopedSuspendUndoTracking(UndoManager* undo_manager);
19 ~ScopedSuspendUndoTracking();
20
21 private:
22 UndoManager* undo_manager_;
23
24 DISALLOW_COPY_AND_ASSIGN(ScopedSuspendUndoTracking);
25 };
26
27 // ScopedGroupingAction --------------------------------------------------------
28
29 // Scopes the grouping of a set of changes into one undoable action.
30 class ScopedGroupingAction {
31 public:
32 explicit ScopedGroupingAction(UndoManager* undo_manager);
33 ~ScopedGroupingAction();
34
35 private:
36 UndoManager* undo_manager_;
37
38 DISALLOW_COPY_AND_ASSIGN(ScopedGroupingAction);
39 };
40
41 #endif // CHROME_BROWSER_UNDO_UNDO_MANAGER_UTILS_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/undo/undo_manager_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698