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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_TOUCH_VIEW_CONTROLLER_DELEGATE_H_
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_TOUCH_VIEW_CONTROLLER_DELEGATE_H_
8 #include "ash/shell_observer.h"
9 #include "base/observer_list.h"
13 // An interface for ash::MaximizeModeController.
14 class TouchViewControllerDelegate
: public ash::ShellObserver
{
16 // Observer that reports changes to the state of MaximizeModeController's
20 // Invoked when maximize mode started/ended.
21 virtual void OnMaximizeModeStarted() {}
22 virtual void OnMaximizeModeEnded() {}
25 virtual ~Observer() {}
28 TouchViewControllerDelegate();
29 ~TouchViewControllerDelegate() override
;
31 // Add/Remove observers.
32 void AddObserver(Observer
* observer
);
33 void RemoveObserver(Observer
* observer
);
35 // Test if the Maximize Mode is enabled or not.
36 bool IsMaximizeModeEnabled() const;
40 // ash::ShellObserver implementation:
41 void OnMaximizeModeStarted() override
;
42 void OnMaximizeModeEnded() override
;
44 // Mode state change observers.
45 base::ObserverList
<Observer
> observers_
;
47 DISALLOW_COPY_AND_ASSIGN(TouchViewControllerDelegate
);
50 } // namespace chromeos
52 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_TOUCH_VIEW_CONTROLLER_DELEGATE_H_