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

Side by Side Diff: chrome/browser/chromeos/chrome_browser_main_chromeos.cc

Issue 11065008: Full Screen Magnifier: Add MagnificationManager (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix typo. Created 8 years, 2 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/chromeos/chrome_browser_main_chromeos.h" 5 #include "chrome/browser/chromeos/chrome_browser_main_chromeos.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/shell.h" 10 #include "ash/shell.h"
11 #include "base/bind.h" 11 #include "base/bind.h"
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/chromeos/chromeos_version.h" 13 #include "base/chromeos/chromeos_version.h"
14 #include "base/command_line.h" 14 #include "base/command_line.h"
15 #include "base/lazy_instance.h" 15 #include "base/lazy_instance.h"
16 #include "base/message_loop.h" 16 #include "base/message_loop.h"
17 #include "base/string_number_conversions.h" 17 #include "base/string_number_conversions.h"
18 #include "base/string_split.h" 18 #include "base/string_split.h"
19 #include "chrome/browser/browser_process.h" 19 #include "chrome/browser/browser_process.h"
20 #include "chrome/browser/chromeos/accessibility/magnification_manager.h"
20 #include "chrome/browser/chromeos/audio/audio_handler.h" 21 #include "chrome/browser/chromeos/audio/audio_handler.h"
21 #include "chrome/browser/chromeos/boot_times_loader.h" 22 #include "chrome/browser/chromeos/boot_times_loader.h"
22 #include "chrome/browser/chromeos/contacts/contact_manager.h" 23 #include "chrome/browser/chromeos/contacts/contact_manager.h"
23 #include "chrome/browser/chromeos/cros/cros_library.h" 24 #include "chrome/browser/chromeos/cros/cros_library.h"
24 #include "chrome/browser/chromeos/dbus/cros_dbus_service.h" 25 #include "chrome/browser/chromeos/dbus/cros_dbus_service.h"
25 #include "chrome/browser/chromeos/display/primary_display_switch_observer.h" 26 #include "chrome/browser/chromeos/display/primary_display_switch_observer.h"
26 #include "chrome/browser/chromeos/external_metrics.h" 27 #include "chrome/browser/chromeos/external_metrics.h"
27 #include "chrome/browser/chromeos/imageburner/burn_manager.h" 28 #include "chrome/browser/chromeos/imageburner/burn_manager.h"
28 #include "chrome/browser/chromeos/input_method/input_method_manager.h" 29 #include "chrome/browser/chromeos/input_method/input_method_manager.h"
29 #include "chrome/browser/chromeos/input_method/xkeyboard.h" 30 #include "chrome/browser/chromeos/input_method/xkeyboard.h"
(...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after
456 brightness_observer_.reset(new chromeos::BrightnessObserver()); 457 brightness_observer_.reset(new chromeos::BrightnessObserver());
457 media_transfer_protocol_device_observer_.reset( 458 media_transfer_protocol_device_observer_.reset(
458 new chromeos::mtp::MediaTransferProtocolDeviceObserverCros()); 459 new chromeos::mtp::MediaTransferProtocolDeviceObserverCros());
459 output_observer_.reset(new chromeos::OutputObserver()); 460 output_observer_.reset(new chromeos::OutputObserver());
460 resume_observer_.reset(new chromeos::ResumeObserver()); 461 resume_observer_.reset(new chromeos::ResumeObserver());
461 screen_lock_observer_.reset(new chromeos::ScreenLockObserver()); 462 screen_lock_observer_.reset(new chromeos::ScreenLockObserver());
462 if (chromeos::KioskModeSettings::Get()->IsKioskModeEnabled()) { 463 if (chromeos::KioskModeSettings::Get()->IsKioskModeEnabled()) {
463 power_state_override_.reset(new chromeos::PowerStateOverride( 464 power_state_override_.reset(new chromeos::PowerStateOverride(
464 chromeos::PowerStateOverride::BLOCK_DISPLAY_SLEEP)); 465 chromeos::PowerStateOverride::BLOCK_DISPLAY_SLEEP));
465 } 466 }
467 magnification_manager_.reset(
468 chromeos::MagnificationManager::CreateInstance());
466 469
467 primary_display_switch_observer_.reset( 470 primary_display_switch_observer_.reset(
468 new chromeos::PrimaryDisplaySwitchObserver()); 471 new chromeos::PrimaryDisplaySwitchObserver());
469 472
470 removable_device_notifications_ = 473 removable_device_notifications_ =
471 new chromeos::RemovableDeviceNotificationsCros(); 474 new chromeos::RemovableDeviceNotificationsCros();
472 475
473 ChromeBrowserMainPartsLinux::PostProfileInit(); 476 ChromeBrowserMainPartsLinux::PostProfileInit();
474 } 477 }
475 478
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 chromeos::DeviceSettingsService::Get()->Shutdown(); 542 chromeos::DeviceSettingsService::Get()->Shutdown();
540 543
541 // We should remove observers attached to D-Bus clients before 544 // We should remove observers attached to D-Bus clients before
542 // DBusThreadManager is shut down. 545 // DBusThreadManager is shut down.
543 screen_lock_observer_.reset(); 546 screen_lock_observer_.reset();
544 resume_observer_.reset(); 547 resume_observer_.reset();
545 brightness_observer_.reset(); 548 brightness_observer_.reset();
546 media_transfer_protocol_device_observer_.reset(); 549 media_transfer_protocol_device_observer_.reset();
547 output_observer_.reset(); 550 output_observer_.reset();
548 power_state_override_.reset(); 551 power_state_override_.reset();
552 magnification_manager_.reset();
549 553
550 // The XInput2 event listener needs to be shut down earlier than when 554 // The XInput2 event listener needs to be shut down earlier than when
551 // Singletons are finally destroyed in AtExitManager. 555 // Singletons are finally destroyed in AtExitManager.
552 chromeos::XInputHierarchyChangedEventListener::GetInstance()->Stop(); 556 chromeos::XInputHierarchyChangedEventListener::GetInstance()->Stop();
553 557
554 // chromeos::SystemKeyEventListener::Shutdown() is always safe to call, 558 // chromeos::SystemKeyEventListener::Shutdown() is always safe to call,
555 // even if Initialize() wasn't called. 559 // even if Initialize() wasn't called.
556 chromeos::SystemKeyEventListener::Shutdown(); 560 chromeos::SystemKeyEventListener::Shutdown();
557 chromeos::imageburner::BurnManager::Shutdown(); 561 chromeos::imageburner::BurnManager::Shutdown();
558 chromeos::AudioHandler::Shutdown(); 562 chromeos::AudioHandler::Shutdown();
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
617 LOG(WARNING) << "low_mem: Part of '100MB' experiment"; 621 LOG(WARNING) << "low_mem: Part of '100MB' experiment";
618 chromeos::LowMemoryObserver::SetLowMemoryMargin(100); 622 chromeos::LowMemoryObserver::SetLowMemoryMargin(100);
619 } else if (trial->group() == margin_200mb) { 623 } else if (trial->group() == margin_200mb) {
620 LOG(WARNING) << "low_mem: Part of '200MB' experiment"; 624 LOG(WARNING) << "low_mem: Part of '200MB' experiment";
621 chromeos::LowMemoryObserver::SetLowMemoryMargin(200); 625 chromeos::LowMemoryObserver::SetLowMemoryMargin(200);
622 } else { 626 } else {
623 LOG(WARNING) << "low_mem: Part of 'default' experiment"; 627 LOG(WARNING) << "low_mem: Part of 'default' experiment";
624 } 628 }
625 } 629 }
626 } 630 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698