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

Unified Diff: chrome/browser/bookmarks/bookmark_model_factory.cc

Issue 265743004: Always install a BookmarkUndoService as a BookmarkModelObserver on iOS (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address blundell comments Created 6 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/bookmarks/bookmark_model_factory.cc
diff --git a/chrome/browser/bookmarks/bookmark_model_factory.cc b/chrome/browser/bookmarks/bookmark_model_factory.cc
index 92e0e35cea818abc462ed40bc5e8d499d8ac6a1b..0b068fe55899aba849fdf002c4884f5a08170e2d 100644
--- a/chrome/browser/bookmarks/bookmark_model_factory.cc
+++ b/chrome/browser/bookmarks/bookmark_model_factory.cc
@@ -65,8 +65,13 @@ KeyedService* BookmarkModelFactory::BuildServiceInstanceFor(
content::BrowserThread::GetMessageLoopProxyForThread(
content::BrowserThread::UI));
#if !defined(OS_ANDROID)
- if (CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kEnableBookmarkUndo)) {
+ bool register_bookmark_undo_service_as_observer = true;
+#if !defined(OS_IOS)
+ register_bookmark_undo_service_as_observer =
+ CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableBookmarkUndo);
+#endif // !defined(OS_IOS)
+ if (register_bookmark_undo_service_as_observer) {
bookmark_client->model()->AddObserver(
BookmarkUndoServiceFactory::GetForProfile(profile));
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698