#ifndef CHROME_BROWSER_CHROMEOS_POWER_POWER_BUTTON_OBSERVER_H_
#define CHROME_BROWSER_CHROMEOS_POWER_POWER_BUTTON_OBSERVER_H_
#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "chromeos/dbus/power_manager_client.h"
#include "chromeos/dbus/session_manager_client.h"
#include "content/public/browser/notification_observer.h"
#include "content/public/browser/notification_registrar.h"
namespace chromeos {
class PowerButtonObserver : public content::NotificationObserver,
public PowerManagerClient::Observer,
public SessionManagerClient::Observer {
public:
PowerButtonObserver();
virtual ~PowerButtonObserver();
private:
virtual void Observe(int type,
const content::NotificationSource& source,
const content::NotificationDetails& details) OVERRIDE;
virtual void PowerButtonEventReceived(
bool down, const base::TimeTicks& timestamp) OVERRIDE;
content::NotificationRegistrar registrar_;
DISALLOW_COPY_AND_ASSIGN(PowerButtonObserver);
};
}
#endif