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

Side by Side Diff: chrome/browser/ui/webui/options/browser_options_handler.cc

Issue 11642014: Re-introduce the partial magnifier (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review fix (comment #4) Created 7 years, 11 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 | Annotate | Revision Log
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/ui/webui/options/browser_options_handler.h" 5 #include "chrome/browser/ui/webui/options/browser_options_handler.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 #include "third_party/skia/include/core/SkBitmap.h" 78 #include "third_party/skia/include/core/SkBitmap.h"
79 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h" 79 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h"
80 #include "ui/base/l10n/l10n_util.h" 80 #include "ui/base/l10n/l10n_util.h"
81 81
82 #if !defined(OS_CHROMEOS) 82 #if !defined(OS_CHROMEOS)
83 #include "chrome/browser/printing/cloud_print/cloud_print_setup_handler.h" 83 #include "chrome/browser/printing/cloud_print/cloud_print_setup_handler.h"
84 #include "chrome/browser/ui/webui/options/advanced_options_utils.h" 84 #include "chrome/browser/ui/webui/options/advanced_options_utils.h"
85 #endif 85 #endif
86 86
87 #if defined(OS_CHROMEOS) 87 #if defined(OS_CHROMEOS)
88 #include "ash/magnifier/magnifier_constants.h"
88 #include "chrome/browser/chromeos/accessibility/accessibility_util.h" 89 #include "chrome/browser/chromeos/accessibility/accessibility_util.h"
89 #include "chrome/browser/chromeos/extensions/wallpaper_manager_util.h" 90 #include "chrome/browser/chromeos/extensions/wallpaper_manager_util.h"
90 #include "chrome/browser/chromeos/login/user_manager.h" 91 #include "chrome/browser/chromeos/login/user_manager.h"
91 #include "chrome/browser/chromeos/settings/cros_settings.h" 92 #include "chrome/browser/chromeos/settings/cros_settings.h"
92 #include "chrome/browser/policy/browser_policy_connector.h" 93 #include "chrome/browser/policy/browser_policy_connector.h"
93 #include "chrome/browser/ui/browser_window.h" 94 #include "chrome/browser/ui/browser_window.h"
94 #include "chrome/browser/ui/webui/options/chromeos/timezone_options_util.h" 95 #include "chrome/browser/ui/webui/options/chromeos/timezone_options_util.h"
95 #include "chromeos/dbus/dbus_thread_manager.h" 96 #include "chromeos/dbus/dbus_thread_manager.h"
96 #include "chromeos/dbus/power_manager_client.h" 97 #include "chromeos/dbus/power_manager_client.h"
97 #include "ui/gfx/image/image_skia.h" 98 #include "ui/gfx/image/image_skia.h"
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after
420 421
421 #if defined(OS_CHROMEOS) 422 #if defined(OS_CHROMEOS)
422 values->SetString("cloudPrintLearnMoreURL", chrome::kCloudPrintLearnMoreURL); 423 values->SetString("cloudPrintLearnMoreURL", chrome::kCloudPrintLearnMoreURL);
423 424
424 // TODO(pastarmovj): replace this with a call to the CrosSettings list 425 // TODO(pastarmovj): replace this with a call to the CrosSettings list
425 // handling functionality to come. 426 // handling functionality to come.
426 values->Set("timezoneList", GetTimezoneList().release()); 427 values->Set("timezoneList", GetTimezoneList().release());
427 428
428 values->SetString("accessibilityLearnMoreURL", 429 values->SetString("accessibilityLearnMoreURL",
429 chrome::kChromeAccessibilityHelpURL); 430 chrome::kChromeAccessibilityHelpURL);
431
432 // Creates magnifierList.
433 base::ListValue* magnifierList = new base::ListValue();
Dan Beam 2013/01/11 00:34:23 nit: magnifier_list (C++ is var_name not varName)
434 base::ListValue* option_full = new base::ListValue();
435 option_full->Append(base::Value::CreateIntegerValue(ash::MAGNIFIER_FULL));
Dan Beam 2013/01/11 00:34:23 nit: I think base::Value::Create* functions are de
436 option_full->Append(new base::StringValue(l10n_util::GetStringUTF16(
437 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_SCREEN_MAGNIFIER_FULL)));
438 base::ListValue* option_partial = new base::ListValue();
439 option_partial->Append(base::Value::CreateIntegerValue(
440 ash::MAGNIFIER_PARTIAL));
441 option_partial->Append(new base::StringValue(l10n_util::GetStringUTF16(
442 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_SCREEN_MAGNIFIER_PARTIAL)));
443 magnifierList->Append(option_full);
Dan Beam 2013/01/11 00:34:23 totally optional nit: I'd put some visual separati
444 magnifierList->Append(option_partial);
445 values->Set("magnifierList", magnifierList);
446
430 #endif 447 #endif
431 #if defined(OS_MACOSX) 448 #if defined(OS_MACOSX)
432 values->SetString("macPasswordsWarning", 449 values->SetString("macPasswordsWarning",
433 l10n_util::GetStringUTF16(IDS_OPTIONS_PASSWORDS_MAC_WARNING)); 450 l10n_util::GetStringUTF16(IDS_OPTIONS_PASSWORDS_MAC_WARNING));
434 values->SetBoolean("multiple_profiles", 451 values->SetBoolean("multiple_profiles",
435 g_browser_process->profile_manager()->GetNumberOfProfiles() > 1); 452 g_browser_process->profile_manager()->GetNumberOfProfiles() > 1);
436 #endif 453 #endif
437 454
438 if (multiprofile_) 455 if (multiprofile_)
439 values->Set("profilesInfo", GetProfilesInfoList().release()); 456 values->Set("profilesInfo", GetProfilesInfoList().release());
(...skipping 956 matching lines...) Expand 10 before | Expand all | Expand 10 after
1396 l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)); 1413 l10n_util::GetStringUTF16(IDS_PRODUCT_NAME));
1397 } 1414 }
1398 StringValue label(label_str); 1415 StringValue label(label_str);
1399 1416
1400 web_ui()->CallJavascriptFunction( 1417 web_ui()->CallJavascriptFunction(
1401 "BrowserOptions.setupProxySettingsSection", disabled, label); 1418 "BrowserOptions.setupProxySettingsSection", disabled, label);
1402 #endif // !defined(OS_CHROMEOS) 1419 #endif // !defined(OS_CHROMEOS)
1403 } 1420 }
1404 1421
1405 } // namespace options 1422 } // namespace options
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698