Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(550)

Side by Side Diff: remoting/host/disconnect_window_linux.cc

Issue 7613004: Split Chromoting's Disconnect button text into 2 parts: name + hotkeys. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « remoting/host/disconnect_window.cc ('k') | remoting/host/disconnect_window_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "remoting/host/disconnect_window.h" 5 #include "remoting/host/disconnect_window.h"
6 6
7 #include <gtk/gtk.h> 7 #include <gtk/gtk.h>
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 27 matching lines...) Expand all
38 : host_(NULL), 38 : host_(NULL),
39 disconnect_window_(NULL) { 39 disconnect_window_(NULL) {
40 } 40 }
41 41
42 DisconnectWindowLinux::~DisconnectWindowLinux() { 42 DisconnectWindowLinux::~DisconnectWindowLinux() {
43 } 43 }
44 44
45 void DisconnectWindowLinux::CreateWindow() { 45 void DisconnectWindowLinux::CreateWindow() {
46 if (disconnect_window_) return; 46 if (disconnect_window_) return;
47 47
48 std::string disconnect_button(kDisconnectButton);
49 disconnect_button += kDisconnectKeysLinux;
48 disconnect_window_ = gtk_dialog_new_with_buttons( 50 disconnect_window_ = gtk_dialog_new_with_buttons(
49 kTitle, 51 kTitle,
50 NULL, 52 NULL,
51 GTK_DIALOG_NO_SEPARATOR, 53 GTK_DIALOG_NO_SEPARATOR,
52 kDisconnectButton, GTK_RESPONSE_OK, 54 disconnect_button.c_str(), GTK_RESPONSE_OK,
53 NULL); 55 NULL);
54 56
55 GtkWindow* window = GTK_WINDOW(disconnect_window_); 57 GtkWindow* window = GTK_WINDOW(disconnect_window_);
56 gtk_window_set_resizable(window, FALSE); 58 gtk_window_set_resizable(window, FALSE);
57 // Try to keep the window always visible. 59 // Try to keep the window always visible.
58 gtk_window_stick(window); 60 gtk_window_stick(window);
59 gtk_window_set_keep_above(window, TRUE); 61 gtk_window_set_keep_above(window, TRUE);
60 // Utility windows have no minimize button or taskbar presence. 62 // Utility windows have no minimize button or taskbar presence.
61 gtk_window_set_type_hint(window, GDK_WINDOW_TYPE_HINT_UTILITY); 63 gtk_window_set_type_hint(window, GDK_WINDOW_TYPE_HINT_UTILITY);
62 gtk_window_set_deletable(window, FALSE); 64 gtk_window_set_deletable(window, FALSE);
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 108
107 host_->Shutdown(NULL); 109 host_->Shutdown(NULL);
108 Hide(); 110 Hide();
109 } 111 }
110 112
111 DisconnectWindow* DisconnectWindow::Create() { 113 DisconnectWindow* DisconnectWindow::Create() {
112 return new DisconnectWindowLinux; 114 return new DisconnectWindowLinux;
113 } 115 }
114 116
115 } // namespace remoting 117 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/disconnect_window.cc ('k') | remoting/host/disconnect_window_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698