| OLD | NEW | 
|---|
| 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 #ifndef CHROME_BROWSER_EXTENSIONS_DISPLAY_INFO_PROVIDER_CHROMEOS_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_DISPLAY_INFO_PROVIDER_CHROMEOS_H_ | 
| 6 #define CHROME_BROWSER_EXTENSIONS_DISPLAY_INFO_PROVIDER_CHROMEOS_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_DISPLAY_INFO_PROVIDER_CHROMEOS_H_ | 
| 7 | 7 | 
| 8 #include <map> | 8 #include <map> | 
| 9 #include <memory> | 9 #include <memory> | 
| 10 | 10 | 
| 11 #include "base/macros.h" | 11 #include "base/macros.h" | 
| 12 #include "extensions/browser/api/system_display/display_info_provider.h" | 12 #include "extensions/browser/api/system_display/display_info_provider.h" | 
| 13 | 13 | 
| 14 namespace chromeos { | 14 namespace chromeos { | 
| 15 class OverscanCalibrator; | 15 class OverscanCalibrator; | 
| 16 } | 16 } | 
| 17 | 17 | 
| 18 namespace extensions { | 18 namespace extensions { | 
| 19 | 19 | 
| 20 class DisplayInfoProviderChromeOS : public DisplayInfoProvider { | 20 class DisplayInfoProviderChromeOS : public DisplayInfoProvider { | 
| 21  public: | 21  public: | 
| 22   DisplayInfoProviderChromeOS(); | 22   DisplayInfoProviderChromeOS(); | 
| 23   ~DisplayInfoProviderChromeOS() override; | 23   ~DisplayInfoProviderChromeOS() override; | 
| 24 | 24 | 
| 25   // DisplayInfoProvider implementation. | 25   // DisplayInfoProvider implementation. | 
| 26   bool SetInfo(const std::string& display_id, | 26   bool SetInfo(const std::string& display_id, | 
| 27                const api::system_display::DisplayProperties& info, | 27                const api::system_display::DisplayProperties& info, | 
| 28                std::string* error) override; | 28                std::string* error) override; | 
|  | 29   bool SetDisplayLayout(const DisplayLayoutList& layouts) override; | 
| 29   void UpdateDisplayUnitInfoForPlatform( | 30   void UpdateDisplayUnitInfoForPlatform( | 
| 30       const display::Display& display, | 31       const display::Display& display, | 
| 31       api::system_display::DisplayUnitInfo* unit) override; | 32       api::system_display::DisplayUnitInfo* unit) override; | 
| 32   void EnableUnifiedDesktop(bool enable) override; | 33   void EnableUnifiedDesktop(bool enable) override; | 
| 33   DisplayUnitInfoList GetAllDisplaysInfo() override; | 34   DisplayUnitInfoList GetAllDisplaysInfo() override; | 
|  | 35   DisplayLayoutList GetDisplayLayout() override; | 
| 34   bool OverscanCalibrationStart(const std::string& id) override; | 36   bool OverscanCalibrationStart(const std::string& id) override; | 
| 35   bool OverscanCalibrationAdjust( | 37   bool OverscanCalibrationAdjust( | 
| 36       const std::string& id, | 38       const std::string& id, | 
| 37       const api::system_display::Insets& delta) override; | 39       const api::system_display::Insets& delta) override; | 
| 38   bool OverscanCalibrationReset(const std::string& id) override; | 40   bool OverscanCalibrationReset(const std::string& id) override; | 
| 39   bool OverscanCalibrationComplete(const std::string& id) override; | 41   bool OverscanCalibrationComplete(const std::string& id) override; | 
| 40 | 42 | 
| 41  private: | 43  private: | 
| 42   std::map<std::string, std::unique_ptr<chromeos::OverscanCalibrator>> | 44   std::map<std::string, std::unique_ptr<chromeos::OverscanCalibrator>> | 
| 43       overscan_calibrators_; | 45       overscan_calibrators_; | 
| 44 | 46 | 
| 45   chromeos::OverscanCalibrator* GetCalibrator(const std::string& id); | 47   chromeos::OverscanCalibrator* GetCalibrator(const std::string& id); | 
| 46 | 48 | 
| 47   DISALLOW_COPY_AND_ASSIGN(DisplayInfoProviderChromeOS); | 49   DISALLOW_COPY_AND_ASSIGN(DisplayInfoProviderChromeOS); | 
| 48 }; | 50 }; | 
| 49 | 51 | 
| 50 }  // namespace extensions | 52 }  // namespace extensions | 
| 51 | 53 | 
| 52 #endif  // CHROME_BROWSER_EXTENSIONS_DISPLAY_INFO_PROVIDER_CHROMEOS_H_ | 54 #endif  // CHROME_BROWSER_EXTENSIONS_DISPLAY_INFO_PROVIDER_CHROMEOS_H_ | 
| OLD | NEW | 
|---|