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

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

Issue 796543002: Plugin Power Saver: Implement option in Settings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Show ASK as BLOCK in UI. Remove 'ask' from policy_test_cases.json Created 6 years 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 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 ContentSetting content_setting) { 76 ContentSetting content_setting) {
77 switch (content_setting) { 77 switch (content_setting) {
78 case CONTENT_SETTING_BLOCK: 78 case CONTENT_SETTING_BLOCK:
79 return "block"; 79 return "block";
80 case CONTENT_SETTING_ALLOW: 80 case CONTENT_SETTING_ALLOW:
81 return "allow"; 81 return "allow";
82 case CONTENT_SETTING_ASK: 82 case CONTENT_SETTING_ASK:
83 return "ask"; 83 return "ask";
84 case CONTENT_SETTING_SESSION_ONLY: 84 case CONTENT_SETTING_SESSION_ONLY:
85 return "session"; 85 return "session";
86 case CONTENT_SETTING_DETECT_IMPORTANT_CONTENT:
87 return "detect";
86 case CONTENT_SETTING_NUM_SETTINGS: 88 case CONTENT_SETTING_NUM_SETTINGS:
87 return "num_settings"; 89 return "num_settings";
88 case CONTENT_SETTING_DEFAULT: 90 case CONTENT_SETTING_DEFAULT:
89 default: 91 default:
90 return "default"; 92 return "default";
91 } 93 }
92 } 94 }
93 95
94 bool IsContentSettingManaged(HostContentSettingsMap* content_settings, 96 bool IsContentSettingManaged(HostContentSettingsMap* content_settings,
95 ContentSettingsType content_settings_type) { 97 ContentSettingsType content_settings_type) {
(...skipping 613 matching lines...) Expand 10 before | Expand all | Expand 10 after
709 jobject obj) { 711 jobject obj) {
710 return ConvertUTF8ToJavaString( 712 return ConvertUTF8ToJavaString(
711 env, 713 env,
712 GetPrefService()->GetString( 714 GetPrefService()->GetString(
713 prefs::kSupervisedUserSecondCustodianProfileImageURL)).Release(); 715 prefs::kSupervisedUserSecondCustodianProfileImageURL)).Release();
714 } 716 }
715 717
716 bool RegisterPrefServiceBridge(JNIEnv* env) { 718 bool RegisterPrefServiceBridge(JNIEnv* env) {
717 return RegisterNativesImpl(env); 719 return RegisterNativesImpl(env);
718 } 720 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698