equal
deleted
inserted
replaced
51 } |
51 } |
52 |
52 |
53 static void SelectGameWndProc(Window *w, WindowEvent *e) |
53 static void SelectGameWndProc(Window *w, WindowEvent *e) |
54 { |
54 { |
55 switch (e->event) { |
55 switch (e->event) { |
56 case WE_CREATE: LowerWindowWidget(w, _opt_newgame.landscape + 8); break; |
56 case WE_CREATE: w->LowerWidget(_opt_newgame.landscape + 8); break; |
57 |
57 |
58 case WE_PAINT: |
58 case WE_PAINT: |
59 SetWindowWidgetLoweredState(w, 8, _opt_newgame.landscape == LT_TEMPERATE); |
59 w->SetWidgetLoweredState(8, _opt_newgame.landscape == LT_TEMPERATE); |
60 SetWindowWidgetLoweredState(w, 9, _opt_newgame.landscape == LT_ARCTIC); |
60 w->SetWidgetLoweredState(9, _opt_newgame.landscape == LT_ARCTIC); |
61 SetWindowWidgetLoweredState(w, 10, _opt_newgame.landscape == LT_TROPIC); |
61 w->SetWidgetLoweredState(10, _opt_newgame.landscape == LT_TROPIC); |
62 SetWindowWidgetLoweredState(w, 11, _opt_newgame.landscape == LT_TOYLAND); |
62 w->SetWidgetLoweredState(11, _opt_newgame.landscape == LT_TOYLAND); |
63 SetDParam(0, STR_6801_EASY + _opt_newgame.diff_level); |
63 SetDParam(0, STR_6801_EASY + _opt_newgame.diff_level); |
64 DrawWindowWidgets(w); |
64 DrawWindowWidgets(w); |
65 break; |
65 break; |
66 |
66 |
67 case WE_CLICK: |
67 case WE_CLICK: |
83 } else { |
83 } else { |
84 ShowNetworkGameWindow(); |
84 ShowNetworkGameWindow(); |
85 } |
85 } |
86 break; |
86 break; |
87 case 8: case 9: case 10: case 11: |
87 case 8: case 9: case 10: case 11: |
88 RaiseWindowWidget(w, _opt_newgame.landscape + 8); |
88 w->RaiseWidget(_opt_newgame.landscape + 8); |
89 SetNewLandscapeType(e->we.click.widget - 8); |
89 SetNewLandscapeType(e->we.click.widget - 8); |
90 break; |
90 break; |
91 case 12: ShowGameOptions(); break; |
91 case 12: ShowGameOptions(); break; |
92 case 13: ShowGameDifficulty(); break; |
92 case 13: ShowGameDifficulty(); break; |
93 case 14: ShowPatchesSelection(); break; |
93 case 14: ShowPatchesSelection(); break; |