Changeset - r16282:0752f4fb1e3e
[Not reviewed]
master
0 1 0
rubidium - 14 years ago 2010-10-20 07:30:15
rubidium@openttd.org
(svn r21000) -Feature[tte]: chat directly to the server or a bot/admin/irc channel monitoring the server (dihedral)
1 file changed with 9 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/main_gui.cpp
Show inline comments
 
@@ -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' | W
 
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_ho
 
	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)
 
};
0 comments (0 inline, 0 general)