mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-22 15:23:01 +01:00
Add text box widget
This commit is contained in:
@@ -2003,12 +2003,18 @@ void window_cancel_textbox()
|
||||
if (gUsingWidgetTextBox)
|
||||
{
|
||||
rct_window* w = window_find_by_number(gCurrentTextBox.window.classification, gCurrentTextBox.window.number);
|
||||
window_event_textinput_call(w, gCurrentTextBox.widget_index, nullptr);
|
||||
if (w != nullptr)
|
||||
{
|
||||
window_event_textinput_call(w, gCurrentTextBox.widget_index, nullptr);
|
||||
}
|
||||
gCurrentTextBox.window.classification = WC_NULL;
|
||||
gCurrentTextBox.window.number = 0;
|
||||
context_stop_text_input();
|
||||
gUsingWidgetTextBox = false;
|
||||
widget_invalidate(w, gCurrentTextBox.widget_index);
|
||||
if (w != nullptr)
|
||||
{
|
||||
widget_invalidate(w, gCurrentTextBox.widget_index);
|
||||
}
|
||||
gCurrentTextBox.widget_index = static_cast<uint16_t>(WindowWidgetType::Last);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user