@@ -1135,24 +1135,20 @@ struct QueryWindow : public Window {
}
void UpdateWidgetSize(WidgetID widget, Dimension *size, [[maybe_unused]] const Dimension &padding, [[maybe_unused]] Dimension *fill, [[maybe_unused]] Dimension *resize) override
{
if (widget != WID_Q_TEXT) return;
Dimension d = GetStringMultiLineBoundingBox(this->message, *size);
d.width += WidgetDimensions::scaled.frametext.Horizontal();
d.height += WidgetDimensions::scaled.framerect.Vertical();
*size = d;
*size = GetStringMultiLineBoundingBox(this->message, *size);
void DrawWidget(const Rect &r, WidgetID widget) const override
DrawStringMultiLine(r.Shrink(WidgetDimensions::scaled.frametext, WidgetDimensions::scaled.framerect),
this->message, TC_FROMSTRING, SA_CENTER);
DrawStringMultiLine(r, this->message, TC_FROMSTRING, SA_CENTER);
void OnClick([[maybe_unused]] Point pt, WidgetID widget, [[maybe_unused]] int click_count) override
switch (widget) {
case WID_Q_YES: {
Status change: