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

Side by Side Diff: chrome/browser/devtools/devtools_window.cc

Issue 1102733002: Remove most occurences of PrefRegistrySyncable::UNSYNCABLE_PREF (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@prefs-add-reg-funcs
Patch Set: Created 5 years, 8 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/devtools/devtools_window.h" 5 #include "chrome/browser/devtools/devtools_window.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/json/json_reader.h" 9 #include "base/json/json_reader.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 297
298 if (!close_callback_.is_null()) { 298 if (!close_callback_.is_null()) {
299 close_callback_.Run(); 299 close_callback_.Run();
300 close_callback_ = base::Closure(); 300 close_callback_ = base::Closure();
301 } 301 }
302 } 302 }
303 303
304 // static 304 // static
305 void DevToolsWindow::RegisterProfilePrefs( 305 void DevToolsWindow::RegisterProfilePrefs(
306 user_prefs::PrefRegistrySyncable* registry) { 306 user_prefs::PrefRegistrySyncable* registry) {
307 registry->RegisterDictionaryPref( 307 registry->RegisterDictionaryPref(prefs::kDevToolsEditedFiles);
308 prefs::kDevToolsEditedFiles, 308 registry->RegisterDictionaryPref(prefs::kDevToolsFileSystemPaths);
309 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 309 registry->RegisterStringPref(prefs::kDevToolsAdbKey, std::string());
310 registry->RegisterDictionaryPref(
311 prefs::kDevToolsFileSystemPaths,
312 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
313 registry->RegisterStringPref(
314 prefs::kDevToolsAdbKey, std::string(),
315 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
316 310
317 registry->RegisterBooleanPref( 311 registry->RegisterBooleanPref(prefs::kDevToolsDiscoverUsbDevicesEnabled,
318 prefs::kDevToolsDiscoverUsbDevicesEnabled, 312 true);
319 true, 313 registry->RegisterBooleanPref(prefs::kDevToolsPortForwardingEnabled, false);
320 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 314 registry->RegisterBooleanPref(prefs::kDevToolsPortForwardingDefaultSet,
321 registry->RegisterBooleanPref( 315 false);
322 prefs::kDevToolsPortForwardingEnabled, 316 registry->RegisterDictionaryPref(prefs::kDevToolsPortForwardingConfig);
323 false, 317 registry->RegisterDictionaryPref(prefs::kDevToolsPreferences);
324 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
325 registry->RegisterBooleanPref(
326 prefs::kDevToolsPortForwardingDefaultSet,
327 false,
328 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
329 registry->RegisterDictionaryPref(
330 prefs::kDevToolsPortForwardingConfig,
331 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
332 registry->RegisterDictionaryPref(
333 prefs::kDevToolsPreferences,
334 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
335 } 318 }
336 319
337 // static 320 // static
338 content::WebContents* DevToolsWindow::GetInTabWebContents( 321 content::WebContents* DevToolsWindow::GetInTabWebContents(
339 WebContents* inspected_web_contents, 322 WebContents* inspected_web_contents,
340 DevToolsContentsResizingStrategy* out_strategy) { 323 DevToolsContentsResizingStrategy* out_strategy) {
341 DevToolsWindow* window = GetInstanceForInspectedWebContents( 324 DevToolsWindow* window = GetInstanceForInspectedWebContents(
342 inspected_web_contents); 325 inspected_web_contents);
343 if (!window || window->life_stage_ == kClosing) 326 if (!window || window->life_stage_ == kClosing)
344 return NULL; 327 return NULL;
(...skipping 875 matching lines...) Expand 10 before | Expand all | Expand 10 after
1220 closure.Run(); 1203 closure.Run();
1221 return; 1204 return;
1222 } 1205 }
1223 load_completed_callback_ = closure; 1206 load_completed_callback_ = closure;
1224 } 1207 }
1225 1208
1226 bool DevToolsWindow::ForwardKeyboardEvent( 1209 bool DevToolsWindow::ForwardKeyboardEvent(
1227 const content::NativeWebKeyboardEvent& event) { 1210 const content::NativeWebKeyboardEvent& event) {
1228 return event_forwarder_->ForwardEvent(event); 1211 return event_forwarder_->ForwardEvent(event);
1229 } 1212 }
OLDNEW
« no previous file with comments | « chrome/browser/custom_handlers/protocol_handler_registry.cc ('k') | chrome/browser/download/download_prefs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698