summaryrefslogtreecommitdiffstats
path: root/remoting
diff options
context:
space:
mode:
authorjamiewalch@chromium.org <jamiewalch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-03 16:59:46 +0000
committerjamiewalch@chromium.org <jamiewalch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-03 16:59:46 +0000
commita84fc0421361a55f7be6a7e238f7aebeeb926d9b (patch)
tree9889cd43162d9f4064010e3590e12d1ffc30e1a7 /remoting
parent02f7433a8d82aea6094bf9280767889ab7b7f011 (diff)
downloadchromium_src-a84fc0421361a55f7be6a7e238f7aebeeb926d9b.zip
chromium_src-a84fc0421361a55f7be6a7e238f7aebeeb926d9b.tar.gz
chromium_src-a84fc0421361a55f7be6a7e238f7aebeeb926d9b.tar.bz2
Changed disconnect shortcut to Ctrl+Alt+Esc.
BUG=None TEST=Manual Review URL: http://codereview.chromium.org/7552019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95255 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting')
-rw-r--r--remoting/host/disconnect_window.cc2
-rw-r--r--remoting/host/local_input_monitor_thread_linux.cc10
-rw-r--r--remoting/host/local_input_monitor_thread_linux.h3
3 files changed, 9 insertions, 6 deletions
diff --git a/remoting/host/disconnect_window.cc b/remoting/host/disconnect_window.cc
index b5efa31..8036856 100644
--- a/remoting/host/disconnect_window.cc
+++ b/remoting/host/disconnect_window.cc
@@ -8,5 +8,5 @@ namespace remoting {
// TODO(garykac): These strings should be localized.
const char DisconnectWindow::kTitle[] = "Remoting";
const char DisconnectWindow::kSharingWith[] = "Sharing with: ";
-const char DisconnectWindow::kDisconnectButton[] = "Disconnect (Shift+Esc)";
+const char DisconnectWindow::kDisconnectButton[] = "Disconnect (Ctrl+Alt+Esc)";
}
diff --git a/remoting/host/local_input_monitor_thread_linux.cc b/remoting/host/local_input_monitor_thread_linux.cc
index 4fd46ac..0c6e007 100644
--- a/remoting/host/local_input_monitor_thread_linux.cc
+++ b/remoting/host/local_input_monitor_thread_linux.cc
@@ -63,7 +63,7 @@ static void ProcessReply(XPointer thread,
LocalInputMonitorThread::LocalInputMonitorThread(ChromotingHost* host)
: base::SimpleThread("LocalInputMonitor"),
- host_(host), display_(NULL), shift_pressed_(false) {
+ host_(host), display_(NULL), alt_pressed_(false), ctrl_pressed_(false) {
wakeup_pipe_[0] = -1;
wakeup_pipe_[1] = -1;
CHECK_EQ(pipe(wakeup_pipe_), 0);
@@ -162,9 +162,11 @@ void LocalInputMonitorThread::LocalMouseMoved(const gfx::Point& pos) {
void LocalInputMonitorThread::LocalKeyPressed(int key_code, bool down) {
int key_sym = XKeycodeToKeysym(display_, key_code, 0);
- if (key_sym == XK_Shift_L || key_sym == XK_Shift_R)
- shift_pressed_ = down;
- if (shift_pressed_ && key_sym == XK_Escape && down) {
+ if (key_sym == XK_Control_L || key_sym == XK_Control_R) {
+ ctrl_pressed_ = down;
+ } else if (key_sym == XK_Alt_L || key_sym == XK_Alt_R) {
+ alt_pressed_ = down;
+ } else if (alt_pressed_ && ctrl_pressed_ && key_sym == XK_Escape && down) {
host_->Shutdown(NULL);
}
}
diff --git a/remoting/host/local_input_monitor_thread_linux.h b/remoting/host/local_input_monitor_thread_linux.h
index b709158..d87470d 100644
--- a/remoting/host/local_input_monitor_thread_linux.h
+++ b/remoting/host/local_input_monitor_thread_linux.h
@@ -29,7 +29,8 @@ class LocalInputMonitorThread : public base::SimpleThread {
ChromotingHost* host_;
int wakeup_pipe_[2];
Display* display_;
- bool shift_pressed_;
+ bool alt_pressed_;
+ bool ctrl_pressed_;
DISALLOW_COPY_AND_ASSIGN(LocalInputMonitorThread);
};