mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-12 10:30:28 +00:00
(svn r23738) -Fix (r23731): forgot to sync the new window with the script API
This commit is contained in:
parent
a32154eaa0
commit
ecb725b34b
@ -51,6 +51,7 @@ void SQGSWindow_Register(Squirrel *engine)
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_TOOLTIPS, "WC_TOOLTIPS");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_QUERY_STRING, "WC_QUERY_STRING");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_CONFIRM_POPUP_QUERY, "WC_CONFIRM_POPUP_QUERY");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_GOAL_QUESTION, "WC_GOAL_QUESTION");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_SAVELOAD, "WC_SAVELOAD");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_LAND_INFO, "WC_LAND_INFO");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WC_DROPDOWN_MENU, "WC_DROPDOWN_MENU");
|
||||
@ -494,6 +495,11 @@ void SQGSWindow_Register(Squirrel *engine)
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GP_ABORT, "WID_GP_ABORT");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GL_PANEL, "WID_GL_PANEL");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GL_SCROLLBAR, "WID_GL_SCROLLBAR");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GQ_QUESTION, "WID_GQ_QUESTION");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GQ_BUTTONS, "WID_GQ_BUTTONS");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GQ_BUTTON_1, "WID_GQ_BUTTON_1");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GQ_BUTTON_2, "WID_GQ_BUTTON_2");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GQ_BUTTON_3, "WID_GQ_BUTTON_3");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GL_BACKGROUND, "WID_GL_BACKGROUND");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GL_FIRST_COMPANY, "WID_GL_FIRST_COMPANY");
|
||||
SQGSWindow.DefSQConst(engine, ScriptWindow::WID_GL_LAST_COMPANY, "WID_GL_LAST_COMPANY");
|
||||
|
@ -194,6 +194,14 @@ public:
|
||||
*/
|
||||
WC_CONFIRM_POPUP_QUERY = ::WC_CONFIRM_POPUP_QUERY,
|
||||
|
||||
/**
|
||||
* Popup with a set of buttons, designed to ask the user a question
|
||||
* from a GameScript. %Window numbers:
|
||||
* - uniqueid = #GoalQuestionWidgets
|
||||
*/
|
||||
WC_GOAL_QUESTION,
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Saveload window; Window numbers:
|
||||
@ -1268,6 +1276,15 @@ public:
|
||||
WID_GL_SCROLLBAR = ::WID_GL_SCROLLBAR, ///< Scrollbar of the panel.
|
||||
};
|
||||
|
||||
/** Widgets of the #GoalQuestionWindow class. */
|
||||
enum GoalQuestionWidgets {
|
||||
WID_GQ_QUESTION = ::WID_GQ_QUESTION, ///< Question text.
|
||||
WID_GQ_BUTTONS = ::WID_GQ_BUTTONS, ///< Buttons selection (between 1, 2 or 3).
|
||||
WID_GQ_BUTTON_1 = ::WID_GQ_BUTTON_1, ///< First button.
|
||||
WID_GQ_BUTTON_2 = ::WID_GQ_BUTTON_2, ///< Second button.
|
||||
WID_GQ_BUTTON_3 = ::WID_GQ_BUTTON_3, ///< Third button.
|
||||
};
|
||||
|
||||
/** Widgets of the #GraphLegendWindow class. */
|
||||
enum GraphLegendWidgets {
|
||||
WID_GL_BACKGROUND = ::WID_GL_BACKGROUND, ///< Background of the window.
|
||||
|
@ -85,6 +85,8 @@ namespace SQConvert {
|
||||
template <> inline int Return<ScriptWindow::GenerationProgressWidgets>(HSQUIRRELVM vm, ScriptWindow::GenerationProgressWidgets res) { sq_pushinteger(vm, (int32)res); return 1; }
|
||||
template <> inline ScriptWindow::GoalListWidgets GetParam(ForceType<ScriptWindow::GoalListWidgets>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQInteger tmp; sq_getinteger(vm, index, &tmp); return (ScriptWindow::GoalListWidgets)tmp; }
|
||||
template <> inline int Return<ScriptWindow::GoalListWidgets>(HSQUIRRELVM vm, ScriptWindow::GoalListWidgets res) { sq_pushinteger(vm, (int32)res); return 1; }
|
||||
template <> inline ScriptWindow::GoalQuestionWidgets GetParam(ForceType<ScriptWindow::GoalQuestionWidgets>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQInteger tmp; sq_getinteger(vm, index, &tmp); return (ScriptWindow::GoalQuestionWidgets)tmp; }
|
||||
template <> inline int Return<ScriptWindow::GoalQuestionWidgets>(HSQUIRRELVM vm, ScriptWindow::GoalQuestionWidgets res) { sq_pushinteger(vm, (int32)res); return 1; }
|
||||
template <> inline ScriptWindow::GraphLegendWidgets GetParam(ForceType<ScriptWindow::GraphLegendWidgets>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQInteger tmp; sq_getinteger(vm, index, &tmp); return (ScriptWindow::GraphLegendWidgets)tmp; }
|
||||
template <> inline int Return<ScriptWindow::GraphLegendWidgets>(HSQUIRRELVM vm, ScriptWindow::GraphLegendWidgets res) { sq_pushinteger(vm, (int32)res); return 1; }
|
||||
template <> inline ScriptWindow::CompanyValueWidgets GetParam(ForceType<ScriptWindow::CompanyValueWidgets>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQInteger tmp; sq_getinteger(vm, index, &tmp); return (ScriptWindow::CompanyValueWidgets)tmp; }
|
||||
|
@ -22,7 +22,7 @@ enum GoalListWidgets {
|
||||
/** Widgets of the #GoalQuestionWindow class. */
|
||||
enum GoalQuestionWidgets {
|
||||
WID_GQ_QUESTION, ///< Question text.
|
||||
WID_GQ_BUTTONS, ///< Buttons selection (between 2 or 3).
|
||||
WID_GQ_BUTTONS, ///< Buttons selection (between 1, 2 or 3).
|
||||
WID_GQ_BUTTON_1, ///< First button.
|
||||
WID_GQ_BUTTON_2, ///< Second button.
|
||||
WID_GQ_BUTTON_3, ///< Third button.
|
||||
|
Loading…
Reference in New Issue
Block a user