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

Side by Side Diff: chrome/browser/android/bookmarks/bookmarks_bridge.cc

Issue 490123003: Move bookmark_pref_names.* into bookmarks namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: REBASE Created 6 years, 3 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/autocomplete/chrome_autocomplete_provider_delegate.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/android/bookmarks/bookmarks_bridge.h" 5 #include "chrome/browser/android/bookmarks/bookmarks_bridge.h"
6 6
7 #include "base/android/jni_string.h" 7 #include "base/android/jni_string.h"
8 #include "base/containers/stack_container.h" 8 #include "base/containers/stack_container.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "chrome/browser/bookmarks/bookmark_model_factory.h" 10 #include "chrome/browser/bookmarks/bookmark_model_factory.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 static jlong GetNativeBookmarkModel(JNIEnv* env, 94 static jlong GetNativeBookmarkModel(JNIEnv* env,
95 jclass caller, 95 jclass caller,
96 jobject j_profile) { 96 jobject j_profile) {
97 Profile *profile = ProfileAndroid::FromProfileAndroid(j_profile); 97 Profile *profile = ProfileAndroid::FromProfileAndroid(j_profile);
98 BookmarkModel *bookmark_model_ = BookmarkModelFactory::GetForProfile(profile); 98 BookmarkModel *bookmark_model_ = BookmarkModelFactory::GetForProfile(profile);
99 return reinterpret_cast<jlong>(bookmark_model_); 99 return reinterpret_cast<jlong>(bookmark_model_);
100 } 100 }
101 101
102 static bool IsEditBookmarksEnabled() { 102 static bool IsEditBookmarksEnabled() {
103 return ProfileManager::GetLastUsedProfile()->GetPrefs()->GetBoolean( 103 return ProfileManager::GetLastUsedProfile()->GetPrefs()->GetBoolean(
104 prefs::kEditBookmarksEnabled); 104 bookmarks::prefs::kEditBookmarksEnabled);
105 } 105 }
106 106
107 static jboolean IsEditBookmarksEnabled(JNIEnv* env, jclass clazz) { 107 static jboolean IsEditBookmarksEnabled(JNIEnv* env, jclass clazz) {
108 return IsEditBookmarksEnabled(); 108 return IsEditBookmarksEnabled();
109 } 109 }
110 110
111 ScopedJavaLocalRef<jobject> BookmarksBridge::GetBookmarkByID(JNIEnv* env, 111 ScopedJavaLocalRef<jobject> BookmarksBridge::GetBookmarkByID(JNIEnv* env,
112 jobject obj, 112 jobject obj,
113 jlong id, 113 jlong id,
114 jint type) { 114 jint type) {
(...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after
652 BookmarkModelChanged(); 652 BookmarkModelChanged();
653 } 653 }
654 654
655 void BookmarksBridge::PartnerShimLoaded(PartnerBookmarksShim* shim) { 655 void BookmarksBridge::PartnerShimLoaded(PartnerBookmarksShim* shim) {
656 NotifyIfDoneLoading(); 656 NotifyIfDoneLoading();
657 } 657 }
658 658
659 void BookmarksBridge::ShimBeingDeleted(PartnerBookmarksShim* shim) { 659 void BookmarksBridge::ShimBeingDeleted(PartnerBookmarksShim* shim) {
660 partner_bookmarks_shim_ = NULL; 660 partner_bookmarks_shim_ = NULL;
661 } 661 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/autocomplete/chrome_autocomplete_provider_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698