diff options
author | rubidium <rubidium@openttd.org> | 2010-10-20 07:30:15 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-10-20 07:30:15 +0000 |
commit | 6431055810c8b22a5b6b6d204b20700b75c01bc1 (patch) | |
tree | 5cec9351179c8db69c2c42f2edf7f249a76d25ca | |
parent | 9e35e80aa1a11329a4f2d94f76323cf533c40845 (diff) | |
download | openttd-6431055810c8b22a5b6b6d204b20700b75c01bc1.tar.xz |
(svn r21000) -Feature[tte]: chat directly to the server or a bot/admin/irc channel monitoring the server (dihedral)
-rw-r--r-- | src/main_gui.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/main_gui.cpp b/src/main_gui.cpp index b5ebe97dd..e77a3f250 100644 --- a/src/main_gui.cpp +++ b/src/main_gui.cpp @@ -230,6 +230,7 @@ enum { GHK_CHAT, GHK_CHAT_ALL, GHK_CHAT_COMPANY, + GHK_CHAT_SERVER, }; struct MainWindow : Window @@ -380,6 +381,12 @@ struct MainWindow : Window ShowNetworkChatQueryWindow(DESTTYPE_TEAM, cio->client_playas); } break; + + case GHK_CHAT_SERVER: // send text to the server + if (_networking && !_network_server) { + ShowNetworkChatQueryWindow(DESTTYPE_CLIENT, CLIENT_ID_SERVER); + } + break; #endif default: return ES_NOT_HANDLED; @@ -428,6 +435,7 @@ const uint16 _ghk_quit_keys[] = {'Q' | WKC_CTRL, 'Q' | WKC_META, 0}; const uint16 _ghk_chat_keys[] = {WKC_RETURN, 'T', 0}; const uint16 _ghk_chat_all_keys[] = {WKC_SHIFT | WKC_RETURN, WKC_SHIFT | 'T', 0}; const uint16 _ghk_chat_company_keys[] = {WKC_CTRL | WKC_RETURN, WKC_CTRL | 'T', 0}; +const uint16 _ghk_chat_server_keys[] = {WKC_CTRL | WKC_SHIFT | WKC_RETURN, WKC_CTRL | WKC_SHIFT | 'T', 0}; Hotkey<MainWindow> MainWindow::global_hotkeys[] = { Hotkey<MainWindow>(_ghk_quit_keys, "quit", GHK_QUIT), @@ -467,6 +475,7 @@ Hotkey<MainWindow> MainWindow::global_hotkeys[] = { Hotkey<MainWindow>(_ghk_chat_keys, "chat", GHK_CHAT), Hotkey<MainWindow>(_ghk_chat_all_keys, "chat_all", GHK_CHAT_ALL), Hotkey<MainWindow>(_ghk_chat_company_keys, "chat_company", GHK_CHAT_COMPANY), + Hotkey<MainWindow>(_ghk_chat_server_keys, "chat_server", GHK_CHAT_SERVER), #endif HOTKEY_LIST_END(MainWindow) }; |