mirror of https://github.com/OpenTTD/OpenTTD
Codechange: use std::source_location over __FILE__ and __LINE__ for WindowDesc
parent
ee79dbe035
commit
b15c019b55
|
@ -82,7 +82,7 @@ static constexpr NWidgetPart _nested_ai_config_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the configure AI window. */
|
||||
static WindowDesc _ai_config_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _ai_config_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GAME_OPTIONS, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -207,7 +207,7 @@ static constexpr NWidgetPart _nested_air_toolbar_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _air_toolbar_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _air_toolbar_desc(
|
||||
WDP_ALIGN_TOOLBAR, "toolbar_air", 0, 0,
|
||||
WC_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -618,7 +618,7 @@ static constexpr NWidgetPart _nested_build_airport_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_airport_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_airport_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUILD_STATION, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -789,7 +789,7 @@ static constexpr NWidgetPart _nested_replace_rail_vehicle_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _replace_rail_vehicle_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _replace_rail_vehicle_desc(
|
||||
WDP_AUTO, "replace_vehicle_train", 500, 140,
|
||||
WC_REPLACE_VEHICLE, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -847,7 +847,7 @@ static constexpr NWidgetPart _nested_replace_road_vehicle_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _replace_road_vehicle_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _replace_road_vehicle_desc(
|
||||
WDP_AUTO, "replace_vehicle_road", 500, 140,
|
||||
WC_REPLACE_VEHICLE, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -901,7 +901,7 @@ static constexpr NWidgetPart _nested_replace_vehicle_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _replace_vehicle_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _replace_vehicle_desc(
|
||||
WDP_AUTO, "replace_vehicle", 456, 118,
|
||||
WC_REPLACE_VEHICLE, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -40,7 +40,7 @@ static constexpr NWidgetPart _background_widgets[] = {
|
|||
/**
|
||||
* Window description for the background window to prevent smearing.
|
||||
*/
|
||||
static WindowDesc _background_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _background_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_BOOTSTRAP, WC_NONE,
|
||||
WDF_NO_CLOSE,
|
||||
|
@ -76,7 +76,7 @@ static constexpr NWidgetPart _nested_bootstrap_errmsg_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window description for the error window. */
|
||||
static WindowDesc _bootstrap_errmsg_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _bootstrap_errmsg_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_BOOTSTRAP, WC_NONE,
|
||||
WDF_MODAL | WDF_NO_CLOSE,
|
||||
|
@ -133,7 +133,7 @@ static constexpr NWidgetPart _nested_bootstrap_download_status_window_widgets[]
|
|||
};
|
||||
|
||||
/** Window description for the download window */
|
||||
static WindowDesc _bootstrap_download_status_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _bootstrap_download_status_window_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_NETWORK_STATUS_WINDOW, WC_NONE,
|
||||
WDF_MODAL | WDF_NO_CLOSE,
|
||||
|
@ -185,7 +185,7 @@ static constexpr NWidgetPart _bootstrap_query_widgets[] = {
|
|||
};
|
||||
|
||||
/** The window description for the query. */
|
||||
static WindowDesc _bootstrap_query_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _bootstrap_query_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_CONFIRM_POPUP_QUERY, WC_NONE,
|
||||
WDF_NO_CLOSE,
|
||||
|
|
|
@ -341,7 +341,7 @@ static constexpr NWidgetPart _nested_build_bridge_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the rail bridge selection window. */
|
||||
static WindowDesc _build_bridge_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_bridge_desc(
|
||||
WDP_AUTO, "build_bridge", 200, 114,
|
||||
WC_BUILD_BRIDGE, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -1895,7 +1895,7 @@ struct BuildVehicleWindow : Window {
|
|||
}};
|
||||
};
|
||||
|
||||
static WindowDesc _build_vehicle_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_vehicle_desc(
|
||||
WDP_AUTO, "build_vehicle", 240, 268,
|
||||
WC_BUILD_VEHICLE, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -427,7 +427,7 @@ struct CheatWindow : Window {
|
|||
};
|
||||
|
||||
/** Window description of the cheats GUI. */
|
||||
static WindowDesc _cheats_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _cheats_desc(
|
||||
WDP_AUTO, "cheats", 0, 0,
|
||||
WC_CHEATS, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -525,7 +525,7 @@ struct CompanyFinancesWindow : Window {
|
|||
/** First conservative estimate of the maximum amount of money */
|
||||
Money CompanyFinancesWindow::max_money = INT32_MAX;
|
||||
|
||||
static WindowDesc _company_finances_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _company_finances_desc(
|
||||
WDP_AUTO, "company_finances", 0, 0,
|
||||
WC_FINANCES, WC_NONE,
|
||||
0,
|
||||
|
@ -1126,7 +1126,7 @@ static constexpr NWidgetPart _nested_select_company_livery_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _select_company_livery_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _select_company_livery_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_COMPANY_COLOUR, WC_NONE,
|
||||
0,
|
||||
|
@ -1751,7 +1751,7 @@ public:
|
|||
};
|
||||
|
||||
/** Company manager face selection window description */
|
||||
static WindowDesc _select_company_manager_face_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _select_company_manager_face_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_COMPANY_MANAGER_FACE, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -2123,7 +2123,7 @@ struct CompanyInfrastructureWindow : Window
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _company_infrastructure_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _company_infrastructure_desc(
|
||||
WDP_AUTO, "company_infrastructure", 0, 0,
|
||||
WC_COMPANY_INFRASTRUCTURE, WC_NONE,
|
||||
0,
|
||||
|
@ -2611,7 +2611,7 @@ struct CompanyWindow : Window
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _company_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _company_desc(
|
||||
WDP_AUTO, "company", 0, 0,
|
||||
WC_COMPANY, WC_NONE,
|
||||
0,
|
||||
|
@ -2745,7 +2745,7 @@ static constexpr NWidgetPart _nested_buy_company_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _buy_company_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _buy_company_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUY_COMPANY, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -102,7 +102,7 @@ static constexpr NWidgetPart _nested_console_window_widgets[] = {
|
|||
NWidget(WWT_EMPTY, INVALID_COLOUR, WID_C_BACKGROUND), SetResize(1, 1),
|
||||
};
|
||||
|
||||
static WindowDesc _console_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _console_window_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_CONSOLE, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -195,7 +195,7 @@ static constexpr NWidgetPart _nested_set_date_widgets[] = {
|
|||
};
|
||||
|
||||
/** Description of the date setting window. */
|
||||
static WindowDesc _set_date_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _set_date_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_SET_DATE, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -85,28 +85,28 @@ static constexpr NWidgetPart _nested_train_depot_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _train_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _train_depot_desc(
|
||||
WDP_AUTO, "depot_train", 362, 123,
|
||||
WC_VEHICLE_DEPOT, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_train_depot_widgets), std::end(_nested_train_depot_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _road_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _road_depot_desc(
|
||||
WDP_AUTO, "depot_roadveh", 316, 97,
|
||||
WC_VEHICLE_DEPOT, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_train_depot_widgets), std::end(_nested_train_depot_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _ship_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _ship_depot_desc(
|
||||
WDP_AUTO, "depot_ship", 306, 99,
|
||||
WC_VEHICLE_DEPOT, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_train_depot_widgets), std::end(_nested_train_depot_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _aircraft_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _aircraft_depot_desc(
|
||||
WDP_AUTO, "depot_aircraft", 332, 99,
|
||||
WC_VEHICLE_DEPOT, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -344,7 +344,7 @@ static constexpr NWidgetPart _nested_build_docks_toolbar_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_docks_toolbar_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_docks_toolbar_desc(
|
||||
WDP_ALIGN_TOOLBAR, "toolbar_water", 0, 0,
|
||||
WC_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -388,7 +388,7 @@ static constexpr NWidgetPart _nested_build_docks_scen_toolbar_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the build docks in scenario editor window. */
|
||||
static WindowDesc _build_docks_scen_toolbar_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_docks_scen_toolbar_desc(
|
||||
WDP_AUTO, "toolbar_water_scen", 0, 0,
|
||||
WC_SCEN_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -498,7 +498,7 @@ static constexpr NWidgetPart _nested_build_dock_station_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_dock_station_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_dock_station_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUILD_STATION, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -593,7 +593,7 @@ static constexpr NWidgetPart _nested_build_docks_depot_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_docks_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_docks_depot_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUILD_DEPOT, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -144,7 +144,7 @@ struct EnginePreviewWindow : Window {
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _engine_preview_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _engine_preview_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_ENGINE_PREVIEW, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -43,7 +43,7 @@ static constexpr NWidgetPart _nested_errmsg_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _errmsg_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _errmsg_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_ERRMSG, WC_NONE,
|
||||
0,
|
||||
|
@ -63,7 +63,7 @@ static constexpr NWidgetPart _nested_errmsg_face_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _errmsg_face_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _errmsg_face_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_ERRMSG, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -883,7 +883,7 @@ public:
|
|||
};
|
||||
|
||||
/** Load game/scenario */
|
||||
static WindowDesc _load_dialog_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _load_dialog_desc(
|
||||
WDP_CENTER, "load_game", 500, 294,
|
||||
WC_SAVELOAD, WC_NONE,
|
||||
0,
|
||||
|
@ -891,7 +891,7 @@ static WindowDesc _load_dialog_desc(__FILE__, __LINE__,
|
|||
);
|
||||
|
||||
/** Load heightmap */
|
||||
static WindowDesc _load_heightmap_dialog_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _load_heightmap_dialog_desc(
|
||||
WDP_CENTER, "load_heightmap", 257, 320,
|
||||
WC_SAVELOAD, WC_NONE,
|
||||
0,
|
||||
|
@ -899,7 +899,7 @@ static WindowDesc _load_heightmap_dialog_desc(__FILE__, __LINE__,
|
|||
);
|
||||
|
||||
/** Save game/scenario */
|
||||
static WindowDesc _save_dialog_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _save_dialog_desc(
|
||||
WDP_CENTER, "save_game", 500, 294,
|
||||
WC_SAVELOAD, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -726,7 +726,7 @@ struct FramerateWindow : Window {
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _framerate_display_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _framerate_display_desc(
|
||||
WDP_AUTO, "framerate_display", 0, 0,
|
||||
WC_FRAMERATE_DISPLAY, WC_NONE,
|
||||
0,
|
||||
|
@ -1017,7 +1017,7 @@ struct FrametimeGraphWindow : Window {
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _frametime_graph_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _frametime_graph_window_desc(
|
||||
WDP_AUTO, "frametime_graph", 140, 90,
|
||||
WC_FRAMETIME_GRAPH, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -73,7 +73,7 @@ static constexpr NWidgetPart _nested_gs_config_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the configure GS window. */
|
||||
static WindowDesc _gs_config_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _gs_config_desc(
|
||||
WDP_CENTER, "settings_gs_config", 500, 350,
|
||||
WC_GAME_OPTIONS, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -1003,14 +1003,14 @@ struct GenerateLandscapeWindow : public Window {
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _generate_landscape_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _generate_landscape_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GENERATE_LANDSCAPE, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_generate_landscape_widgets), std::end(_nested_generate_landscape_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _heightmap_load_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _heightmap_load_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GENERATE_LANDSCAPE, WC_NONE,
|
||||
0,
|
||||
|
@ -1313,7 +1313,7 @@ static constexpr NWidgetPart _nested_create_scenario_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _create_scenario_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _create_scenario_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GENERATE_LANDSCAPE, WC_NONE,
|
||||
0,
|
||||
|
@ -1339,7 +1339,7 @@ static constexpr NWidgetPart _nested_generate_progress_widgets[] = {
|
|||
};
|
||||
|
||||
|
||||
static WindowDesc _generate_progress_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _generate_progress_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_MODAL_PROGRESS, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -302,7 +302,7 @@ static constexpr NWidgetPart _nested_goals_list_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _goals_list_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _goals_list_desc(
|
||||
WDP_AUTO, "list_goals", 500, 127,
|
||||
WC_GOALS_LIST, WC_NONE,
|
||||
0,
|
||||
|
@ -512,28 +512,24 @@ static constexpr NWidgetPart _nested_goal_question_widgets_error[] = {
|
|||
|
||||
static WindowDesc _goal_question_list_desc[] = {
|
||||
{
|
||||
__FILE__, __LINE__,
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GOAL_QUESTION, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
std::begin(_nested_goal_question_widgets_question), std::end(_nested_goal_question_widgets_question),
|
||||
},
|
||||
{
|
||||
__FILE__, __LINE__,
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GOAL_QUESTION, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
std::begin(_nested_goal_question_widgets_info), std::end(_nested_goal_question_widgets_info),
|
||||
},
|
||||
{
|
||||
__FILE__, __LINE__,
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GOAL_QUESTION, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
std::begin(_nested_goal_question_widgets_warning), std::end(_nested_goal_question_widgets_warning),
|
||||
},
|
||||
{
|
||||
__FILE__, __LINE__,
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GOAL_QUESTION, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -138,7 +138,7 @@ static constexpr NWidgetPart _nested_graph_legend_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _graph_legend_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _graph_legend_desc(
|
||||
WDP_AUTO, "graph_legend", 0, 0,
|
||||
WC_GRAPH_LEGEND, WC_NONE,
|
||||
0,
|
||||
|
@ -650,7 +650,7 @@ static constexpr NWidgetPart _nested_operating_profit_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _operating_profit_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _operating_profit_desc(
|
||||
WDP_AUTO, "graph_operating_profit", 0, 0,
|
||||
WC_OPERATING_PROFIT, WC_NONE,
|
||||
0,
|
||||
|
@ -701,7 +701,7 @@ static constexpr NWidgetPart _nested_income_graph_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _income_graph_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _income_graph_desc(
|
||||
WDP_AUTO, "graph_income", 0, 0,
|
||||
WC_INCOME_GRAPH, WC_NONE,
|
||||
0,
|
||||
|
@ -750,7 +750,7 @@ static constexpr NWidgetPart _nested_delivered_cargo_graph_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _delivered_cargo_graph_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _delivered_cargo_graph_desc(
|
||||
WDP_AUTO, "graph_delivered_cargo", 0, 0,
|
||||
WC_DELIVERED_CARGO, WC_NONE,
|
||||
0,
|
||||
|
@ -806,7 +806,7 @@ static constexpr NWidgetPart _nested_performance_history_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _performance_history_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _performance_history_desc(
|
||||
WDP_AUTO, "graph_performance", 0, 0,
|
||||
WC_PERFORMANCE_HISTORY, WC_NONE,
|
||||
0,
|
||||
|
@ -855,7 +855,7 @@ static constexpr NWidgetPart _nested_company_value_graph_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _company_value_graph_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _company_value_graph_desc(
|
||||
WDP_AUTO, "graph_company_value", 0, 0,
|
||||
WC_COMPANY_VALUE, WC_NONE,
|
||||
0,
|
||||
|
@ -1091,7 +1091,7 @@ static constexpr NWidgetPart _nested_cargo_payment_rates_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _cargo_payment_rates_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _cargo_payment_rates_desc(
|
||||
WDP_AUTO, "graph_cargo_payment_rates", 0, 0,
|
||||
WC_PAYMENT_RATES, WC_NONE,
|
||||
0,
|
||||
|
@ -1383,7 +1383,7 @@ static constexpr NWidgetPart _nested_performance_rating_detail_widgets[] = {
|
|||
NWidgetFunction(MakePerformanceDetailPanels),
|
||||
};
|
||||
|
||||
static WindowDesc _performance_rating_detail_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _performance_rating_detail_desc(
|
||||
WDP_AUTO, "league_details", 0, 0,
|
||||
WC_PERFORMANCE_DETAIL, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -1098,14 +1098,14 @@ public:
|
|||
};
|
||||
|
||||
|
||||
static WindowDesc _other_group_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _other_group_desc(
|
||||
WDP_AUTO, "list_groups", 460, 246,
|
||||
WC_INVALID, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_group_widgets), std::end(_nested_group_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _train_group_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _train_group_desc(
|
||||
WDP_AUTO, "list_groups_train", 525, 246,
|
||||
WC_TRAINS_LIST, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -191,7 +191,7 @@ static constexpr NWidgetPart _nested_helpwin_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _helpwin_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _helpwin_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_HELPWIN, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -214,14 +214,14 @@ static constexpr NWidgetPart _nested_highscore_widgets[] = {
|
|||
NWidget(WWT_PANEL, COLOUR_BROWN, WID_H_BACKGROUND), SetResize(1, 1), EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _highscore_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _highscore_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_HIGHSCORE, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_highscore_widgets), std::end(_nested_highscore_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _endgame_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _endgame_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_ENDSCREEN, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -292,7 +292,7 @@ static constexpr NWidgetPart _nested_build_industry_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition of the dynamic place industries gui */
|
||||
static WindowDesc _build_industry_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_industry_desc(
|
||||
WDP_AUTO, "build_industry", 170, 212,
|
||||
WC_BUILD_INDUSTRY, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1199,7 +1199,7 @@ static constexpr NWidgetPart _nested_industry_view_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition of the view industry gui */
|
||||
static WindowDesc _industry_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _industry_view_desc(
|
||||
WDP_AUTO, "view_industry", 260, 120,
|
||||
WC_INDUSTRY_VIEW, WC_NONE,
|
||||
0,
|
||||
|
@ -1904,7 +1904,7 @@ CargoID IndustryDirectoryWindow::produced_cargo_filter = CargoFilterCriteria::CF
|
|||
|
||||
|
||||
/** Window definition of the industry directory gui */
|
||||
static WindowDesc _industry_directory_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _industry_directory_desc(
|
||||
WDP_AUTO, "list_industries", 428, 190,
|
||||
WC_INDUSTRY_DIRECTORY, WC_NONE,
|
||||
0,
|
||||
|
@ -1943,7 +1943,7 @@ static constexpr NWidgetPart _nested_industry_cargoes_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window description for the industry cargoes window. */
|
||||
static WindowDesc _industry_cargoes_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _industry_cargoes_desc(
|
||||
WDP_AUTO, "industry_cargoes", 300, 210,
|
||||
WC_INDUSTRY_CARGOES, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -456,7 +456,7 @@ static constexpr NWidgetPart _nested_select_game_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _select_game_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _select_game_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_SELECT_GAME, WC_NONE,
|
||||
WDF_NO_CLOSE,
|
||||
|
|
|
@ -197,7 +197,7 @@ static constexpr NWidgetPart _nested_performance_league_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _performance_league_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _performance_league_desc(
|
||||
WDP_AUTO, "performance_league", 0, 0,
|
||||
WC_COMPANY_LEAGUE, WC_NONE,
|
||||
0,
|
||||
|
@ -430,7 +430,7 @@ static constexpr NWidgetPart _nested_script_league_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _script_league_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _script_league_desc(
|
||||
WDP_AUTO, "script_league", 0, 0,
|
||||
WC_COMPANY_LEAGUE, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -539,7 +539,7 @@ static constexpr NWidgetPart _nested_linkgraph_legend_widgets[] = {
|
|||
static_assert(WID_LGL_SATURATION_LAST - WID_LGL_SATURATION_FIRST ==
|
||||
lengthof(LinkGraphOverlay::LINK_COLOURS[0]) - 1);
|
||||
|
||||
static WindowDesc _linkgraph_legend_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _linkgraph_legend_desc(
|
||||
WDP_AUTO, "toolbar_linkgraph", 0, 0,
|
||||
WC_LINKGRAPH_LEGEND, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -513,7 +513,7 @@ struct MainWindow : Window
|
|||
}};
|
||||
};
|
||||
|
||||
static WindowDesc _main_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _main_window_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_MAIN_WINDOW, WC_NONE,
|
||||
WDF_NO_CLOSE,
|
||||
|
|
|
@ -58,7 +58,7 @@ static constexpr NWidgetPart _nested_land_info_widgets[] = {
|
|||
NWidget(WWT_PANEL, COLOUR_GREY, WID_LI_BACKGROUND), EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _land_info_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _land_info_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_LAND_INFO, WC_NONE,
|
||||
0,
|
||||
|
@ -393,7 +393,7 @@ static constexpr NWidgetPart _nested_about_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _about_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _about_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GAME_OPTIONS, WC_NONE,
|
||||
0,
|
||||
|
@ -651,7 +651,7 @@ static constexpr NWidgetPart _nested_tooltips_widgets[] = {
|
|||
NWidget(WWT_EMPTY, INVALID_COLOUR, WID_TT_BACKGROUND),
|
||||
};
|
||||
|
||||
static WindowDesc _tool_tips_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _tool_tips_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0, // Coordinates and sizes are not used,
|
||||
WC_TOOLTIPS, WC_NONE,
|
||||
WDF_NO_FOCUS | WDF_NO_CLOSE,
|
||||
|
@ -1064,7 +1064,7 @@ static constexpr NWidgetPart _nested_query_string_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _query_string_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _query_string_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_QUERY_STRING, WC_NONE,
|
||||
0,
|
||||
|
@ -1211,7 +1211,7 @@ static constexpr NWidgetPart _nested_query_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _query_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _query_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_CONFIRM_POPUP_QUERY, WC_NONE,
|
||||
WDF_MODAL,
|
||||
|
|
|
@ -667,7 +667,7 @@ static constexpr NWidgetPart _nested_music_track_selection_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _music_track_selection_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _music_track_selection_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_MUSIC_TRACK_SELECTION, WC_NONE,
|
||||
0,
|
||||
|
@ -926,7 +926,7 @@ static constexpr NWidgetPart _nested_music_window_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _music_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _music_window_desc(
|
||||
WDP_AUTO, "music", 0, 0,
|
||||
WC_MUSIC_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -506,7 +506,7 @@ static constexpr NWidgetPart _nested_chat_window_widgets[] = {
|
|||
};
|
||||
|
||||
/** The description of the chat window. */
|
||||
static WindowDesc _chat_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _chat_window_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_SEND_NETWORK_MSG, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -92,7 +92,7 @@ static constexpr NWidgetPart _nested_network_content_download_status_window_widg
|
|||
};
|
||||
|
||||
/** Window description for the download window */
|
||||
static WindowDesc _network_content_download_status_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_content_download_status_window_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_NETWORK_STATUS_WINDOW, WC_NONE,
|
||||
WDF_MODAL,
|
||||
|
@ -1111,7 +1111,7 @@ static constexpr NWidgetPart _nested_network_content_list_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window description of the content list */
|
||||
static WindowDesc _network_content_list_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_content_list_desc(
|
||||
WDP_CENTER, "list_content", 630, 460,
|
||||
WC_NETWORK_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -949,7 +949,7 @@ static constexpr NWidgetPart _nested_network_game_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _network_game_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_game_window_desc(
|
||||
WDP_CENTER, "list_servers", 1000, 730,
|
||||
WC_NETWORK_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -1216,7 +1216,7 @@ static constexpr NWidgetPart _nested_network_start_server_window_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _network_start_server_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_start_server_window_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_NETWORK_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -1295,7 +1295,7 @@ static constexpr NWidgetPart _nested_client_list_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _client_list_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _client_list_desc(
|
||||
WDP_AUTO, "list_clients", 220, 300,
|
||||
WC_CLIENT_LIST, WC_NONE,
|
||||
0,
|
||||
|
@ -2205,7 +2205,7 @@ static constexpr NWidgetPart _nested_network_join_status_window_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _network_join_status_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_join_status_window_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_NETWORK_STATUS_WINDOW, WC_NONE,
|
||||
WDF_MODAL,
|
||||
|
@ -2327,7 +2327,7 @@ static constexpr NWidgetPart _nested_network_company_password_window_widgets[] =
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _network_company_password_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_company_password_window_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_COMPANY_PASSWORD_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -2436,7 +2436,7 @@ static constexpr NWidgetPart _nested_network_ask_relay_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _network_ask_relay_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_ask_relay_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_NETWORK_ASK_RELAY, WC_NONE,
|
||||
WDF_MODAL,
|
||||
|
@ -2534,7 +2534,7 @@ static constexpr NWidgetPart _nested_network_ask_survey_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _network_ask_survey_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _network_ask_survey_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_NETWORK_ASK_SURVEY, WC_NONE,
|
||||
WDF_MODAL,
|
||||
|
|
|
@ -679,14 +679,14 @@ static constexpr NWidgetPart _nested_newgrf_inspect_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _newgrf_inspect_chain_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _newgrf_inspect_chain_desc(
|
||||
WDP_AUTO, "newgrf_inspect_chain", 400, 300,
|
||||
WC_NEWGRF_INSPECT, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_newgrf_inspect_chain_widgets), std::end(_nested_newgrf_inspect_chain_widgets)
|
||||
);
|
||||
|
||||
static WindowDesc _newgrf_inspect_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _newgrf_inspect_desc(
|
||||
WDP_AUTO, "newgrf_inspect", 400, 300,
|
||||
WC_NEWGRF_INSPECT, WC_NONE,
|
||||
0,
|
||||
|
@ -1160,7 +1160,7 @@ static constexpr NWidgetPart _nested_sprite_aligner_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _sprite_aligner_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _sprite_aligner_desc(
|
||||
WDP_AUTO, "sprite_aligner", 400, 300,
|
||||
WC_SPRITE_ALIGNER, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -541,7 +541,7 @@ static constexpr NWidgetPart _nested_newgrf_parameter_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the change grf parameters window */
|
||||
static WindowDesc _newgrf_parameters_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _newgrf_parameters_desc(
|
||||
WDP_CENTER, "settings_newgrf_config", 500, 208,
|
||||
WC_GRF_PARAMETERS, WC_NONE,
|
||||
0,
|
||||
|
@ -1966,7 +1966,7 @@ static constexpr NWidgetPart _nested_newgrf_widgets[] = {
|
|||
};
|
||||
|
||||
/* Window definition of the manage newgrfs window */
|
||||
static WindowDesc _newgrf_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _newgrf_desc(
|
||||
WDP_CENTER, "settings_newgrf", 300, 263,
|
||||
WC_GAME_OPTIONS, WC_NONE,
|
||||
0,
|
||||
|
@ -2050,7 +2050,7 @@ static constexpr NWidgetPart _nested_save_preset_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window description of the preset save window. */
|
||||
static WindowDesc _save_preset_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _save_preset_desc(
|
||||
WDP_CENTER, "save_preset", 140, 110,
|
||||
WC_SAVE_PRESET, WC_GAME_OPTIONS,
|
||||
WDF_MODAL,
|
||||
|
@ -2195,7 +2195,7 @@ static constexpr NWidgetPart _nested_scan_progress_widgets[] = {
|
|||
};
|
||||
|
||||
/** Description of the widgets and other settings of the window. */
|
||||
static WindowDesc _scan_progress_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _scan_progress_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_MODAL_PROGRESS, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -96,7 +96,7 @@ static constexpr NWidgetPart _nested_normal_news_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _normal_news_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _normal_news_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_NEWS_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -123,7 +123,7 @@ static constexpr NWidgetPart _nested_vehicle_news_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _vehicle_news_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _vehicle_news_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_NEWS_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -151,7 +151,7 @@ static constexpr NWidgetPart _nested_company_news_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _company_news_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _company_news_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_NEWS_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -174,7 +174,7 @@ static constexpr NWidgetPart _nested_thin_news_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _thin_news_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _thin_news_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_NEWS_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -200,7 +200,7 @@ static constexpr NWidgetPart _nested_small_news_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _small_news_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _small_news_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_NEWS_WINDOW, WC_NONE,
|
||||
0,
|
||||
|
@ -1228,7 +1228,7 @@ static constexpr NWidgetPart _nested_message_history[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _message_history_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _message_history_desc(
|
||||
WDP_AUTO, "list_news", 400, 140,
|
||||
WC_MESSAGE_HISTORY, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -709,7 +709,7 @@ static constexpr NWidgetPart _nested_build_object_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_object_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_object_desc(
|
||||
WDP_AUTO, "build_object", 0, 0,
|
||||
WC_BUILD_OBJECT, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -1636,7 +1636,7 @@ static constexpr NWidgetPart _nested_orders_train_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _orders_train_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _orders_train_desc(
|
||||
WDP_AUTO, "view_vehicle_orders_train", 384, 100,
|
||||
WC_VEHICLE_ORDERS, WC_VEHICLE_VIEW,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1709,7 +1709,7 @@ static constexpr NWidgetPart _nested_orders_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _orders_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _orders_desc(
|
||||
WDP_AUTO, "view_vehicle_orders", 384, 100,
|
||||
WC_VEHICLE_ORDERS, WC_VEHICLE_VIEW,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1736,7 +1736,7 @@ static constexpr NWidgetPart _nested_other_orders_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _other_orders_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _other_orders_desc(
|
||||
WDP_AUTO, "view_vehicle_orders_competitor", 384, 86,
|
||||
WC_VEHICLE_ORDERS, WC_VEHICLE_VIEW,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -333,7 +333,7 @@ static constexpr NWidgetPart _nested_osk_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _osk_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _osk_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_OSK, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -837,7 +837,7 @@ static constexpr NWidgetPart _nested_build_rail_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_rail_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_rail_desc(
|
||||
WDP_ALIGN_TOOLBAR, "toolbar_rail", 0, 0,
|
||||
WC_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1617,7 +1617,7 @@ static constexpr NWidgetPart _nested_station_builder_widgets[] = {
|
|||
};
|
||||
|
||||
/** High level window description of the station-build window (default & newGRF) */
|
||||
static WindowDesc _station_builder_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _station_builder_desc(
|
||||
WDP_AUTO, "build_station_rail", 350, 0,
|
||||
WC_BUILD_STATION, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1875,7 +1875,7 @@ static constexpr NWidgetPart _nested_signal_builder_widgets[] = {
|
|||
};
|
||||
|
||||
/** Signal selection window description */
|
||||
static WindowDesc _signal_builder_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _signal_builder_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUILD_SIGNAL, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1956,7 +1956,7 @@ static constexpr NWidgetPart _nested_build_depot_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_depot_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUILD_DEPOT, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -2185,7 +2185,7 @@ static constexpr NWidgetPart _nested_build_waypoint_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_waypoint_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_waypoint_desc(
|
||||
WDP_AUTO, "build_waypoint", 0, 0,
|
||||
WC_BUILD_WAYPOINT, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -851,7 +851,7 @@ static constexpr NWidgetPart _nested_build_road_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_road_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_road_desc(
|
||||
WDP_ALIGN_TOOLBAR, "toolbar_road", 0, 0,
|
||||
WC_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -892,7 +892,7 @@ static constexpr NWidgetPart _nested_build_tramway_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_tramway_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_tramway_desc(
|
||||
WDP_ALIGN_TOOLBAR, "toolbar_tramway", 0, 0,
|
||||
WC_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -947,7 +947,7 @@ static constexpr NWidgetPart _nested_build_road_scen_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_road_scen_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_road_scen_desc(
|
||||
WDP_AUTO, "toolbar_road_scen", 0, 0,
|
||||
WC_SCEN_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -982,7 +982,7 @@ static constexpr NWidgetPart _nested_build_tramway_scen_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_tramway_scen_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_tramway_scen_desc(
|
||||
WDP_AUTO, "toolbar_tram_scen", 0, 0,
|
||||
WC_SCEN_BUILD_TOOLBAR, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1079,7 +1079,7 @@ static constexpr NWidgetPart _nested_build_road_depot_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_road_depot_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_road_depot_desc(
|
||||
WDP_AUTO, nullptr, 0, 0,
|
||||
WC_BUILD_DEPOT, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1680,7 +1680,7 @@ static constexpr NWidgetPart _nested_road_station_picker_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _road_station_picker_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _road_station_picker_desc(
|
||||
WDP_AUTO, "build_station_road", 0, 0,
|
||||
WC_BUS_STATION, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -1757,7 +1757,7 @@ static constexpr NWidgetPart _nested_tram_station_picker_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _tram_station_picker_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _tram_station_picker_desc(
|
||||
WDP_AUTO, "build_station_tram", 0, 0,
|
||||
WC_BUS_STATION, WC_BUILD_TOOLBAR,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -60,7 +60,7 @@ static constexpr NWidgetPart _nested_screenshot[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _screenshot_window_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _screenshot_window_desc(
|
||||
WDP_AUTO, "take_a_screenshot", 200, 100,
|
||||
WC_SCREENSHOT, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -261,7 +261,7 @@ static constexpr NWidgetPart _nested_script_list_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the ai list window. */
|
||||
static WindowDesc _script_list_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _script_list_desc(
|
||||
WDP_CENTER, "settings_script_list", 200, 234,
|
||||
WC_SCRIPT_LIST, WC_NONE,
|
||||
0,
|
||||
|
@ -606,7 +606,7 @@ static constexpr NWidgetPart _nested_script_settings_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the Script settings window. */
|
||||
static WindowDesc _script_settings_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _script_settings_desc(
|
||||
WDP_CENTER, "settings_script", 500, 208,
|
||||
WC_SCRIPT_SETTINGS, WC_NONE,
|
||||
0,
|
||||
|
@ -1285,7 +1285,7 @@ EndContainer(),
|
|||
};
|
||||
|
||||
/** Window definition for the Script debug window. */
|
||||
static WindowDesc _script_debug_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _script_debug_desc(
|
||||
WDP_AUTO, "script_debug", 600, 450,
|
||||
WC_SCRIPT_DEBUG, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -973,7 +973,7 @@ static constexpr NWidgetPart _nested_game_options_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _game_options_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _game_options_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_GAME_OPTIONS, WC_NONE,
|
||||
0,
|
||||
|
@ -2711,7 +2711,7 @@ static constexpr NWidgetPart _nested_settings_selection_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _settings_selection_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _settings_selection_desc(
|
||||
WDP_CENTER, "settings", 510, 450,
|
||||
WC_GAME_OPTIONS, WC_NONE,
|
||||
0,
|
||||
|
@ -3019,7 +3019,7 @@ static constexpr NWidgetPart _nested_cust_currency_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _cust_currency_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _cust_currency_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_CUSTOM_CURRENCY, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -383,7 +383,7 @@ static constexpr NWidgetPart _nested_sign_list_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _sign_list_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _sign_list_desc(
|
||||
WDP_AUTO, "list_signs", 358, 138,
|
||||
WC_SIGN_LIST, WC_NONE,
|
||||
0,
|
||||
|
@ -549,7 +549,7 @@ static constexpr NWidgetPart _nested_query_sign_edit_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _query_sign_edit_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _query_sign_edit_desc(
|
||||
WDP_CENTER, nullptr, 0, 0,
|
||||
WC_QUERY_STRING, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -1981,7 +1981,7 @@ static constexpr NWidgetPart _nested_smallmap_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _smallmap_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _smallmap_desc(
|
||||
WDP_AUTO, "smallmap", 484, 314,
|
||||
WC_SMALLMAP, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -767,7 +767,7 @@ static constexpr NWidgetPart _nested_company_stations_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _company_stations_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _company_stations_desc(
|
||||
WDP_AUTO, "list_stations", 358, 162,
|
||||
WC_STATION_LIST, WC_NONE,
|
||||
0,
|
||||
|
@ -2135,7 +2135,7 @@ const StringID StationViewWindow::_group_names[] = {
|
|||
INVALID_STRING_ID
|
||||
};
|
||||
|
||||
static WindowDesc _station_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _station_view_desc(
|
||||
WDP_AUTO, "view_station", 249, 117,
|
||||
WC_STATION_VIEW, WC_NONE,
|
||||
0,
|
||||
|
@ -2392,7 +2392,7 @@ struct SelectStationWindow : Window {
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _select_station_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _select_station_desc(
|
||||
WDP_AUTO, "build_station_join", 200, 180,
|
||||
WC_SELECT_STATION, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -226,7 +226,7 @@ static constexpr NWidgetPart _nested_main_status_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _main_status_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _main_status_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_STATUS_BAR, WC_NONE,
|
||||
WDF_NO_FOCUS | WDF_NO_CLOSE,
|
||||
|
|
|
@ -968,7 +968,7 @@ static constexpr NWidgetPart _nested_story_book_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _story_book_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _story_book_desc(
|
||||
WDP_CENTER, "view_story", 400, 300,
|
||||
WC_STORY_BOOK, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -233,7 +233,7 @@ static constexpr NWidgetPart _nested_subsidies_list_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _subsidies_list_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _subsidies_list_desc(
|
||||
WDP_AUTO, "list_subsidies", 500, 127,
|
||||
WC_SUBSIDIES_LIST, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -351,7 +351,7 @@ static constexpr NWidgetPart _nested_terraform_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _terraform_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _terraform_desc(
|
||||
WDP_MANUAL, "toolbar_landscape", 0, 0,
|
||||
WC_SCEN_LAND_GEN, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -735,7 +735,7 @@ struct ScenarioEditorLandscapeGenerationWindow : Window {
|
|||
}, TerraformToolbarEditorGlobalHotkeys};
|
||||
};
|
||||
|
||||
static WindowDesc _scen_edit_land_gen_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _scen_edit_land_gen_desc(
|
||||
WDP_AUTO, "toolbar_landscape_scen", 0, 0,
|
||||
WC_SCEN_LAND_GEN, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -50,7 +50,7 @@ TEST_CASE("WindowDesc - ini_key validity")
|
|||
bool has_inikey = window_desc->ini_key != nullptr;
|
||||
bool has_widget = std::any_of(window_desc->nwid_begin, window_desc->nwid_end, [](const NWidgetPart &part) { return part.type == WWT_DEFSIZEBOX || part.type == WWT_STICKYBOX; });
|
||||
|
||||
INFO(fmt::format("{}:{}", window_desc->file, window_desc->line));
|
||||
INFO(fmt::format("{}:{}", window_desc->source_location.file_name(), window_desc->source_location.line()));
|
||||
CAPTURE(has_inikey);
|
||||
CAPTURE(has_widget);
|
||||
|
||||
|
@ -78,7 +78,7 @@ TEST_CASE("WindowDesc - NWidgetParts properly closed")
|
|||
{
|
||||
const WindowDesc *window_desc = GENERATE(from_range(std::begin(*_window_descs), std::end(*_window_descs)));
|
||||
|
||||
INFO(fmt::format("{}:{}", window_desc->file, window_desc->line));
|
||||
INFO(fmt::format("{}:{}", window_desc->source_location.file_name(), window_desc->source_location.line()));
|
||||
|
||||
CHECK(IsNWidgetTreeClosed(window_desc->nwid_begin, window_desc->nwid_end));
|
||||
}
|
||||
|
@ -87,7 +87,7 @@ TEST_CASE_METHOD(WindowDescTestsFixture, "WindowDesc - NWidgetPart validity")
|
|||
{
|
||||
const WindowDesc *window_desc = GENERATE(from_range(std::begin(*_window_descs), std::end(*_window_descs)));
|
||||
|
||||
INFO(fmt::format("{}:{}", window_desc->file, window_desc->line));
|
||||
INFO(fmt::format("{}:{}", window_desc->source_location.file_name(), window_desc->source_location.line()));
|
||||
|
||||
NWidgetStacked *shade_select = nullptr;
|
||||
std::unique_ptr<NWidgetBase> root = nullptr;
|
||||
|
|
|
@ -74,7 +74,7 @@ static constexpr NWidgetPart _nested_textfile_widgets[] = {
|
|||
};
|
||||
|
||||
/** Window definition for the textfile window */
|
||||
static WindowDesc _textfile_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _textfile_desc(
|
||||
WDP_CENTER, "textfile", 630, 460,
|
||||
WC_TEXTFILE, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -846,7 +846,7 @@ static constexpr NWidgetPart _nested_timetable_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _timetable_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _timetable_desc(
|
||||
WDP_AUTO, "view_vehicle_timetable", 400, 130,
|
||||
WC_VEHICLE_TIMETABLE, WC_VEHICLE_VIEW,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -2183,7 +2183,7 @@ static constexpr NWidgetPart _nested_toolbar_normal_widgets[] = {
|
|||
NWidgetFunction(MakeMainToolbar),
|
||||
};
|
||||
|
||||
static WindowDesc _toolb_normal_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _toolb_normal_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_MAIN_TOOLBAR, WC_NONE,
|
||||
WDF_NO_FOCUS | WDF_NO_CLOSE,
|
||||
|
@ -2523,7 +2523,7 @@ static constexpr NWidgetPart _nested_toolb_scen_widgets[] = {
|
|||
NWidgetFunction(MakeScenarioToolbar),
|
||||
};
|
||||
|
||||
static WindowDesc _toolb_scen_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _toolb_scen_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_MAIN_TOOLBAR, WC_NONE,
|
||||
WDF_NO_FOCUS | WDF_NO_CLOSE,
|
||||
|
|
|
@ -327,7 +327,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _town_authority_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _town_authority_desc(
|
||||
WDP_AUTO, "view_town_authority", 317, 222,
|
||||
WC_TOWN_AUTHORITY, WC_NONE,
|
||||
0,
|
||||
|
@ -620,7 +620,7 @@ static constexpr NWidgetPart _nested_town_game_view_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _town_game_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _town_game_view_desc(
|
||||
WDP_AUTO, "view_town", 260, TownViewWindow::WID_TV_HEIGHT_NORMAL,
|
||||
WC_TOWN_VIEW, WC_NONE,
|
||||
0,
|
||||
|
@ -651,7 +651,7 @@ static constexpr NWidgetPart _nested_town_editor_view_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _town_editor_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _town_editor_view_desc(
|
||||
WDP_AUTO, "view_town_scen", 260, TownViewWindow::WID_TV_HEIGHT_NORMAL,
|
||||
WC_TOWN_VIEW, WC_NONE,
|
||||
0,
|
||||
|
@ -1048,7 +1048,7 @@ GUITownList::SortFunction * const TownDirectoryWindow::sorter_funcs[] = {
|
|||
&TownRatingSorter,
|
||||
};
|
||||
|
||||
static WindowDesc _town_directory_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _town_directory_desc(
|
||||
WDP_AUTO, "list_towns", 208, 202,
|
||||
WC_TOWN_DIRECTORY, WC_NONE,
|
||||
0,
|
||||
|
@ -1282,7 +1282,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _found_town_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _found_town_desc(
|
||||
WDP_AUTO, "build_town", 160, 162,
|
||||
WC_FOUND_TOWN, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -148,7 +148,7 @@ static constexpr NWidgetPart _nested_transparency_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _transparency_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _transparency_desc(
|
||||
WDP_MANUAL, "toolbar_transparency", 0, 0,
|
||||
WC_TRANSPARENCY_TOOLBAR, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -313,7 +313,7 @@ static constexpr NWidgetPart _nested_build_trees_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _build_trees_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _build_trees_desc(
|
||||
WDP_AUTO, "build_tree", 0, 0,
|
||||
WC_BUILD_TREES, WC_NONE,
|
||||
WDF_CONSTRUCTION,
|
||||
|
|
|
@ -1233,7 +1233,7 @@ static constexpr NWidgetPart _nested_vehicle_refit_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _vehicle_refit_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _vehicle_refit_desc(
|
||||
WDP_AUTO, "view_vehicle_refit", 240, 174,
|
||||
WC_VEHICLE_REFIT, WC_VEHICLE_VIEW,
|
||||
WDF_CONSTRUCTION,
|
||||
|
@ -2160,14 +2160,14 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _vehicle_list_other_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _vehicle_list_other_desc(
|
||||
WDP_AUTO, "list_vehicles", 260, 246,
|
||||
WC_INVALID, WC_NONE,
|
||||
0,
|
||||
std::begin(_nested_vehicle_list), std::end(_nested_vehicle_list)
|
||||
);
|
||||
|
||||
static WindowDesc _vehicle_list_train_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _vehicle_list_train_desc(
|
||||
WDP_AUTO, "list_vehicles_train", 325, 246,
|
||||
WC_TRAINS_LIST, WC_NONE,
|
||||
0,
|
||||
|
@ -2666,7 +2666,7 @@ struct VehicleDetailsWindow : Window {
|
|||
};
|
||||
|
||||
/** Vehicle details window descriptor. */
|
||||
static WindowDesc _train_vehicle_details_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _train_vehicle_details_desc(
|
||||
WDP_AUTO, "view_vehicle_details_train", 405, 178,
|
||||
WC_VEHICLE_DETAILS, WC_VEHICLE_VIEW,
|
||||
0,
|
||||
|
@ -2674,7 +2674,7 @@ static WindowDesc _train_vehicle_details_desc(__FILE__, __LINE__,
|
|||
);
|
||||
|
||||
/** Vehicle details window descriptor for other vehicles than a train. */
|
||||
static WindowDesc _nontrain_vehicle_details_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _nontrain_vehicle_details_desc(
|
||||
WDP_AUTO, "view_vehicle_details", 405, 113,
|
||||
WC_VEHICLE_DETAILS, WC_VEHICLE_VIEW,
|
||||
0,
|
||||
|
@ -3269,7 +3269,7 @@ public:
|
|||
};
|
||||
|
||||
/** Vehicle view window descriptor for all vehicles but trains. */
|
||||
static WindowDesc _vehicle_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _vehicle_view_desc(
|
||||
WDP_AUTO, "view_vehicle", 250, 116,
|
||||
WC_VEHICLE_VIEW, WC_NONE,
|
||||
0,
|
||||
|
@ -3281,7 +3281,7 @@ static WindowDesc _vehicle_view_desc(__FILE__, __LINE__,
|
|||
* Vehicle view window descriptor for trains. Only minimum_height and
|
||||
* default_height are different for train view.
|
||||
*/
|
||||
static WindowDesc _train_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _train_view_desc(
|
||||
WDP_AUTO, "view_vehicle_train", 250, 134,
|
||||
WC_VEHICLE_VIEW, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -142,7 +142,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
static WindowDesc _extra_viewport_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _extra_viewport_desc(
|
||||
WDP_AUTO, "extra_viewport", 300, 268,
|
||||
WC_EXTRA_VIEWPORT, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -183,7 +183,7 @@ static constexpr NWidgetPart _nested_waypoint_view_widgets[] = {
|
|||
};
|
||||
|
||||
/** The description of the waypoint view. */
|
||||
static WindowDesc _waypoint_view_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _waypoint_view_desc(
|
||||
WDP_AUTO, "view_waypoint", 260, 118,
|
||||
WC_WAYPOINT_VIEW, WC_NONE,
|
||||
0,
|
||||
|
|
|
@ -31,7 +31,7 @@ static constexpr NWidgetPart _nested_dropdown_menu_widgets[] = {
|
|||
EndContainer(),
|
||||
};
|
||||
|
||||
static WindowDesc _dropdown_desc(__FILE__, __LINE__,
|
||||
static WindowDesc _dropdown_desc(
|
||||
WDP_MANUAL, nullptr, 0, 0,
|
||||
WC_DROPDOWN_MENU, WC_NONE,
|
||||
WDF_NO_FOCUS,
|
||||
|
|
|
@ -102,11 +102,11 @@ std::vector<WindowDesc*> *_window_descs = nullptr;
|
|||
std::string _windows_file;
|
||||
|
||||
/** Window description constructor. */
|
||||
WindowDesc::WindowDesc(const char * const file, const int line, WindowPosition def_pos, const char *ini_key, int16_t def_width_trad, int16_t def_height_trad,
|
||||
WindowDesc::WindowDesc(WindowPosition def_pos, const char *ini_key, int16_t def_width_trad, int16_t def_height_trad,
|
||||
WindowClass window_class, WindowClass parent_class, uint32_t flags,
|
||||
const NWidgetPart *nwid_begin, const NWidgetPart *nwid_end, HotkeyList *hotkeys) :
|
||||
file(file),
|
||||
line(line),
|
||||
const NWidgetPart *nwid_begin, const NWidgetPart *nwid_end, HotkeyList *hotkeys,
|
||||
const std::source_location location) :
|
||||
source_location(location),
|
||||
default_pos(def_pos),
|
||||
cls(window_class),
|
||||
parent_cls(parent_class),
|
||||
|
|
|
@ -246,14 +246,14 @@ struct HotkeyList;
|
|||
*/
|
||||
struct WindowDesc : ZeroedMemoryAllocator {
|
||||
|
||||
WindowDesc(const char * const file, const int line, WindowPosition default_pos, const char *ini_key, int16_t def_width_trad, int16_t def_height_trad,
|
||||
WindowDesc(WindowPosition default_pos, const char *ini_key, int16_t def_width_trad, int16_t def_height_trad,
|
||||
WindowClass window_class, WindowClass parent_class, uint32_t flags,
|
||||
const NWidgetPart *nwid_begin, const NWidgetPart *nwid_end, HotkeyList *hotkeys = nullptr);
|
||||
const NWidgetPart *nwid_begin, const NWidgetPart *nwid_end, HotkeyList *hotkeys = nullptr,
|
||||
const std::source_location location = std::source_location::current());
|
||||
|
||||
~WindowDesc();
|
||||
|
||||
const char * const file; ///< Source file of this definition
|
||||
const int line; ///< Source line of this definition
|
||||
const std::source_location source_location; ///< Source location of this definition
|
||||
WindowPosition default_pos; ///< Preferred position of the window. @see WindowPosition()
|
||||
WindowClass cls; ///< Class of the window, @see WindowClass.
|
||||
WindowClass parent_cls; ///< Class of the parent window. @see WindowClass
|
||||
|
@ -278,10 +278,11 @@ private:
|
|||
int16_t default_height_trad; ///< Preferred initial height of the window (pixels at 1x zoom).
|
||||
|
||||
/**
|
||||
* Dummy private copy constructor to prevent compilers from
|
||||
* Delete copy constructor to prevent compilers from
|
||||
* copying the structure, which fails due to _window_descs.
|
||||
*/
|
||||
WindowDesc(const WindowDesc &other);
|
||||
WindowDesc(const WindowDesc &) = delete;
|
||||
WindowDesc& operator=(const WindowDesc &) = delete;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue