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

Side by Side Diff: chrome/browser/android/preferences/pref_service_bridge.cc

Issue 884213005: Update {virtual,override,final} to follow C++11 style. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 10 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/preferences/pref_service_bridge.h" 5 #include "chrome/browser/android/preferences/pref_service_bridge.h"
6 6
7 #include <jni.h> 7 #include <jni.h>
8 8
9 #include "base/android/build_info.h" 9 #include "base/android/build_info.h"
10 #include "base/android/jni_android.h" 10 #include "base/android/jni_android.h"
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 277
278 // Redirects a BrowsingDataRemover completion callback back into Java. 278 // Redirects a BrowsingDataRemover completion callback back into Java.
279 class ClearBrowsingDataObserver : public BrowsingDataRemover::Observer { 279 class ClearBrowsingDataObserver : public BrowsingDataRemover::Observer {
280 public: 280 public:
281 // |obj| is expected to be the object passed into ClearBrowsingData(); e.g. a 281 // |obj| is expected to be the object passed into ClearBrowsingData(); e.g. a
282 // ChromePreference. 282 // ChromePreference.
283 ClearBrowsingDataObserver(JNIEnv* env, jobject obj) 283 ClearBrowsingDataObserver(JNIEnv* env, jobject obj)
284 : weak_chrome_native_preferences_(env, obj) { 284 : weak_chrome_native_preferences_(env, obj) {
285 } 285 }
286 286
287 virtual void OnBrowsingDataRemoverDone() override { 287 void OnBrowsingDataRemoverDone() override {
288 // Just as a BrowsingDataRemover deletes itself when done, we delete ourself 288 // Just as a BrowsingDataRemover deletes itself when done, we delete ourself
289 // when done. No need to remove ourself as an observer given the lifetime 289 // when done. No need to remove ourself as an observer given the lifetime
290 // of BrowsingDataRemover. 290 // of BrowsingDataRemover.
291 scoped_ptr<ClearBrowsingDataObserver> auto_delete(this); 291 scoped_ptr<ClearBrowsingDataObserver> auto_delete(this);
292 292
293 JNIEnv* env = AttachCurrentThread(); 293 JNIEnv* env = AttachCurrentThread();
294 if (weak_chrome_native_preferences_.get(env).is_null()) 294 if (weak_chrome_native_preferences_.get(env).is_null())
295 return; 295 return;
296 296
297 Java_PrefServiceBridge_browsingDataCleared( 297 Java_PrefServiceBridge_browsingDataCleared(
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after
698 jobject obj) { 698 jobject obj) {
699 return ConvertUTF8ToJavaString( 699 return ConvertUTF8ToJavaString(
700 env, 700 env,
701 GetPrefService()->GetString( 701 GetPrefService()->GetString(
702 prefs::kSupervisedUserSecondCustodianProfileImageURL)).Release(); 702 prefs::kSupervisedUserSecondCustodianProfileImageURL)).Release();
703 } 703 }
704 704
705 bool RegisterPrefServiceBridge(JNIEnv* env) { 705 bool RegisterPrefServiceBridge(JNIEnv* env) {
706 return RegisterNativesImpl(env); 706 return RegisterNativesImpl(env);
707 } 707 }
OLDNEW
« no previous file with comments | « chrome/browser/android/password_ui_view_android.h ('k') | chrome/browser/android/preferences/website_preference_bridge.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698