| OLD | NEW |
| 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 #ifndef ASH_DISPLAY_DISPLAY_CHANGE_OBSERVER_X11_H | 5 #ifndef ASH_DISPLAY_DISPLAY_CHANGE_OBSERVER_X11_H |
| 6 #define ASH_DISPLAY_DISPLAY_CHANGE_OBSERVER_X11_H | 6 #define ASH_DISPLAY_DISPLAY_CHANGE_OBSERVER_X11_H |
| 7 | 7 |
| 8 #include <X11/Xlib.h> | 8 #include <X11/Xlib.h> |
| 9 | 9 |
| 10 // Xlib.h defines RootWindow. | 10 // Xlib.h defines RootWindow. |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 // update DisplayManagers. | 21 // update DisplayManagers. |
| 22 class DisplayChangeObserverX11 | 22 class DisplayChangeObserverX11 |
| 23 : public chromeos::OutputConfigurator::StateController, | 23 : public chromeos::OutputConfigurator::StateController, |
| 24 public chromeos::OutputConfigurator::Observer, | 24 public chromeos::OutputConfigurator::Observer, |
| 25 public ShellObserver { | 25 public ShellObserver { |
| 26 public: | 26 public: |
| 27 DisplayChangeObserverX11(); | 27 DisplayChangeObserverX11(); |
| 28 virtual ~DisplayChangeObserverX11(); | 28 virtual ~DisplayChangeObserverX11(); |
| 29 | 29 |
| 30 // chromeos::OutputConfigurator::StateController overrides: | 30 // chromeos::OutputConfigurator::StateController overrides: |
| 31 virtual chromeos::OutputState GetStateForOutputs( | 31 virtual chromeos::OutputState GetStateForDisplayIds( |
| 32 const std::vector<chromeos::OutputInfo>& outputs) const OVERRIDE; | 32 const std::vector<int64>& outputs) const OVERRIDE; |
| 33 | 33 |
| 34 // Overriden from chromeos::OutputConfigurator::Observer: | 34 // Overriden from chromeos::OutputConfigurator::Observer: |
| 35 virtual void OnDisplayModeChanged() OVERRIDE; | 35 virtual void OnDisplayModeChanged() OVERRIDE; |
| 36 | 36 |
| 37 // Overriden from ShellObserver: | 37 // Overriden from ShellObserver: |
| 38 virtual void OnAppTerminating() OVERRIDE; | 38 virtual void OnAppTerminating() OVERRIDE; |
| 39 | 39 |
| 40 private: | 40 private: |
| 41 Display* xdisplay_; | 41 Display* xdisplay_; |
| 42 | 42 |
| 43 ::Window x_root_window_; | 43 ::Window x_root_window_; |
| 44 | 44 |
| 45 int xrandr_event_base_; | 45 int xrandr_event_base_; |
| 46 | 46 |
| 47 DISALLOW_COPY_AND_ASSIGN(DisplayChangeObserverX11); | 47 DISALLOW_COPY_AND_ASSIGN(DisplayChangeObserverX11); |
| 48 }; | 48 }; |
| 49 | 49 |
| 50 } // namespace internal | 50 } // namespace internal |
| 51 } // namespace ash | 51 } // namespace ash |
| 52 | 52 |
| 53 #endif // ASH_DISPLAY_AURA_DISPLAY_CHANGE_OBSERVER_X11_H | 53 #endif // ASH_DISPLAY_AURA_DISPLAY_CHANGE_OBSERVER_X11_H |
| OLD | NEW |