summaryrefslogtreecommitdiff
path: root/network_gui.c
diff options
context:
space:
mode:
authortron <tron@openttd.org>2005-11-13 13:43:55 +0000
committertron <tron@openttd.org>2005-11-13 13:43:55 +0000
commitee15e3de13643b2d09abcc5424bf8e2d916cff75 (patch)
tree385ce09aff7cf19e072a627e83e91fe8a5f3fb3b /network_gui.c
parent59e885c2bff5b1af6d7f5473106e9aa1f562abfd (diff)
downloadopenttd-ee15e3de13643b2d09abcc5424bf8e2d916cff75.tar.xz
(svn r3172) static, const
Diffstat (limited to 'network_gui.c')
-rw-r--r--network_gui.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/network_gui.c b/network_gui.c
index 5f09d9934..c99e10538 100644
--- a/network_gui.c
+++ b/network_gui.c
@@ -79,8 +79,9 @@ static void NetworkGameWindowWndProc(Window *w, WindowEvent *e)
_selected_field = 3;
_selected_item = NULL;
break;
+
case WE_PAINT: {
- NetworkGameList *sel = _selected_item;
+ const NetworkGameList* sel = _selected_item;
w->disabled_state = 0;
@@ -891,9 +892,10 @@ static WindowDesc _client_list_desc = {
};
// Finds the Xth client-info that is active
-static NetworkClientInfo *NetworkFindClientInfo(byte client_no)
+static const NetworkClientInfo* NetworkFindClientInfo(byte client_no)
{
- NetworkClientInfo *ci;
+ const NetworkClientInfo* ci;
+
for (ci = _network_client_info; ci != &_network_client_info[MAX_CLIENT_INFO]; ci++) {
// Skip non-active items
if (ci->client_index == NETWORK_EMPTY_INDEX) continue;
@@ -1012,7 +1014,7 @@ static uint ClientListPopupHeigth(void) {
static Window *PopupClientList(Window *w, int client_no, int x, int y)
{
int i, h;
- NetworkClientInfo *ci;
+ const NetworkClientInfo* ci;
DeleteWindowById(WC_TOOLBAR_MENU, 0);
// Clean the current actions