tron@2186: /* $Id$ */ tron@2186: truelight@0: #ifndef GUI_H truelight@0: #define GUI_H truelight@0: darkvater@175: #include "window.h" darkvater@175: truelight@0: /* main_gui.c */ tron@1093: void SetupColorsAndInitialWindow(void); tron@1977: void CcPlaySound10(bool success, TileIndex tile, uint32 p1, uint32 p2); tron@1977: void CcBuildCanal(bool success, TileIndex tile, uint32 p1, uint32 p2); tron@1977: void CcTerraform(bool success, TileIndex tile, uint32 p1, uint32 p2); truelight@0: truelight@0: /* settings_gui.c */ tron@1093: void ShowGameOptions(void); tron@1093: void ShowGameDifficulty(void); tron@1093: void ShowPatchesSelection(void); tron@1093: void ShowNewgrf(void); tron@1093: void ShowCustCurrency(void); truelight@0: truelight@0: /* graph_gui.c */ tron@1093: void ShowOperatingProfitGraph(void); tron@1093: void ShowIncomeGraph(void); tron@1093: void ShowDeliveredCargoGraph(void); tron@1093: void ShowPerformanceHistoryGraph(void); tron@1093: void ShowCompanyValueGraph(void); tron@1093: void ShowCargoPaymentRates(void); tron@1093: void ShowCompanyLeagueTable(void); tron@1093: void ShowPerformanceRatingDetail(void); truelight@0: truelight@0: /* news_gui.c */ tron@1093: void ShowLastNewsMessage(void); tron@1093: void ShowMessageOptions(void); tron@1093: void ShowMessageHistory(void); truelight@0: truelight@0: /* traintoolb_gui.c */ truelight@0: void ShowBuildRailToolbar(int index, int button); tron@1977: void PlaceProc_BuyLand(TileIndex tile); truelight@0: truelight@0: /* train_gui.c */ tron@588: void ShowPlayerTrains(int player, int station); truelight@0: void ShowTrainViewWindow(Vehicle *v); truelight@0: void ShowTrainDetailsWindow(Vehicle *v); truelight@0: void ShowOrdersWindow(Vehicle *v); truelight@0: truelight@0: void ShowRoadVehViewWindow(Vehicle *v); truelight@0: truelight@0: /* road_gui.c */ tron@1093: void ShowBuildRoadToolbar(void); tron@1093: void ShowBuildRoadScenToolbar(void); tron@588: void ShowPlayerRoadVehicles(int player, int station); truelight@0: truelight@0: /* dock_gui.c */ tron@1093: void ShowBuildDocksToolbar(void); tron@588: void ShowPlayerShips(int player, int station); truelight@0: truelight@0: void ShowShipViewWindow(Vehicle *v); truelight@0: truelight@0: /* aircraft_gui.c */ tron@1093: void ShowBuildAirToolbar(void); tron@588: void ShowPlayerAircraft(int player, int station); truelight@0: truelight@0: /* terraform_gui.c */ Darkvater@1632: void ShowTerraformToolbar(void); Darkvater@1632: tron@1977: void PlaceProc_DemolishArea(TileIndex tile); tron@1977: void PlaceProc_LowerLand(TileIndex tile); tron@1977: void PlaceProc_RaiseLand(TileIndex tile); tron@1977: void PlaceProc_LevelLand(TileIndex tile); Darkvater@1632: bool GUIPlaceProcDragXY(const WindowEvent *we); Darkvater@1632: Darkvater@1632: enum { // max 32 - 4 = 28 types Darkvater@1632: GUI_PlaceProc_DemolishArea = 0 << 4, Darkvater@1632: GUI_PlaceProc_LevelArea = 1 << 4, Darkvater@1632: GUI_PlaceProc_DesertArea = 2 << 4, Darkvater@1632: GUI_PlaceProc_WaterArea = 3 << 4, Darkvater@1632: GUI_PlaceProc_ConvertRailArea = 4 << 4 Darkvater@1632: }; truelight@0: truelight@0: /* misc_gui.c */ tron@1093: void PlaceLandBlockInfo(void); tron@1093: void ShowAboutWindow(void); tron@1093: void ShowBuildTreesToolbar(void); tron@1093: void ShowBuildTreesScenToolbar(void); tron@1093: void ShowTownDirectory(void); tron@1093: void ShowIndustryDirectory(void); tron@1093: void ShowSubsidiesList(void); truelight@0: void ShowPlayerStations(int player); truelight@0: void ShowPlayerFinances(int player); truelight@0: void ShowPlayerCompany(int player); truelight@1575: void ShowSignList(void); truelight@0: truelight@0: void ShowEstimatedCostOrIncome(int32 cost, int x, int y); truelight@0: void ShowErrorMessage(StringID msg_1, StringID msg_2, int x, int y); truelight@0: Celestar@568: void DrawStationCoverageAreaText(int sx, int sy, uint mask,int rad); truelight@0: void CheckRedrawStationCoverage(Window *w); truelight@0: tron@1093: void ShowSmallMap(void); tron@1093: void ShowExtraViewPortWindow(void); truelight@0: void SetVScrollCount(Window *w, int num); bjarni@842: void SetVScroll2Count(Window *w, int num); truelight@0: void SetHScrollCount(Window *w, int num); truelight@0: tron@1093: void ShowCheatWindow(void); tron@1093: void AskForNewGameToStart(void); truelight@0: truelight@0: void DrawEditBox(Window *w, int wid); truelight@0: void HandleEditBox(Window *w, int wid); Darkvater@1390: int HandleEditBoxKey(Window *w, int wid, WindowEvent *we); Darkvater@1390: bool HandleCaret(Textbuf *tb); Darkvater@1390: Darkvater@1879: void DeleteTextBufferAll(Textbuf *tb); Darkvater@1390: bool DeleteTextBufferChar(Textbuf *tb, int delmode); Darkvater@1390: bool InsertTextBufferChar(Textbuf *tb, byte key); Darkvater@1390: bool InsertTextBufferClipboard(Textbuf *tb); Darkvater@1390: bool MoveTextBufferPos(Textbuf *tb, int navmode); Darkvater@1390: void UpdateTextBufferSize(Textbuf *tb); truelight@0: tron@1093: void BuildFileList(void); truelight@543: void SetFiosType(const byte fiostype); truelight@543: truelight@543: /* FIOS_TYPE_FILE, FIOS_TYPE_OLDFILE etc. different colours */ ludde@2261: extern const byte _fios_colors[]; truelight@0: truelight@0: /* network gui */ tron@1093: void ShowNetworkGameWindow(void); dominik@649: void ShowChatWindow(StringID str, StringID caption, int maxlen, int maxwidth, byte window_class, uint16 window_number); truelight@0: truelight@0: /* bridge_gui.c */ truelight@0: void ShowBuildBridgeWindow(uint start, uint end, byte type); truelight@0: truelight@0: enum { truelight@0: ZOOM_IN = 0, truelight@0: ZOOM_OUT = 1, truelight@0: ZOOM_NONE = 2, // hack, used to update the button status truelight@0: }; truelight@0: darkvater@152: bool DoZoomInOutWindow(int how, Window * w); tron@1093: void ShowBuildIndustryWindow(void); tron@1386: void ShowQueryString(StringID str, StringID caption, uint maxlen, uint maxwidth, WindowClass window_class, WindowNumber window_number); tron@1093: void ShowMusicWindow(void); truelight@0: truelight@0: /* main_gui.c */ truelight@0: VARDEF byte _construct_mode; truelight@0: VARDEF byte _station_show_coverage; truelight@0: VARDEF PlaceProc *_place_proc; truelight@0: VARDEF bool _no_button_sound; truelight@0: darkvater@1246: /* vehicle_gui.c */ darkvater@1246: void InitializeGUI(void); darkvater@1246: truelight@0: #endif /* GUI_H */