This source file includes following definitions.
- GetInstance
- StartListening
- StopListening
- RegisterAcceleratorImpl
- UnregisterAcceleratorImpl
#include "chrome/browser/extensions/global_shortcut_listener_chromeos.h"
#include "content/public/browser/browser_thread.h"
using content::BrowserThread;
namespace extensions {
GlobalShortcutListener* GlobalShortcutListener::GetInstance() {
CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
static GlobalShortcutListenerChromeOS* instance =
new GlobalShortcutListenerChromeOS();
return instance;
}
GlobalShortcutListenerChromeOS::GlobalShortcutListenerChromeOS()
: is_listening_(false) {
CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
LOG(ERROR) << "GlobalShortcutListenerChromeOS object created";
}
GlobalShortcutListenerChromeOS::~GlobalShortcutListenerChromeOS() {
if (is_listening_)
StopListening();
}
void GlobalShortcutListenerChromeOS::StartListening() {
DCHECK(!is_listening_);
NOTIMPLEMENTED();
is_listening_ = true;
}
void GlobalShortcutListenerChromeOS::StopListening() {
DCHECK(is_listening_);
NOTIMPLEMENTED();
is_listening_ = false;
}
bool GlobalShortcutListenerChromeOS::RegisterAcceleratorImpl(
const ui::Accelerator& accelerator) {
NOTIMPLEMENTED();
return false;
}
void GlobalShortcutListenerChromeOS::UnregisterAcceleratorImpl(
const ui::Accelerator& accelerator) {
NOTIMPLEMENTED();
}
}