diff options
author | frosch <frosch@openttd.org> | 2012-11-14 22:50:46 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2012-11-14 22:50:46 +0000 |
commit | 1b3e8a8af6c11864226058a8fbffc4d765096468 (patch) | |
tree | eeb9ba6dc2fef0513d9453cd11434a6608f5f3a5 /src/misc_gui.cpp | |
parent | c8c040d0577597c7cd849db06535942d454ebc96 (diff) | |
download | openttd-1b3e8a8af6c11864226058a8fbffc4d765096468.tar.xz |
(svn r24745) -Codechange: Draw complete editbox via QueryString.
Diffstat (limited to 'src/misc_gui.cpp')
-rw-r--r-- | src/misc_gui.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/misc_gui.cpp b/src/misc_gui.cpp index ba627ddee..1e0e8c8e5 100644 --- a/src/misc_gui.cpp +++ b/src/misc_gui.cpp @@ -778,7 +778,7 @@ void QueryString::HandleEditBox(Window *w, int wid) void QueryString::DrawEditBox(const Window *w, int wid) const { - const NWidgetBase *wi = w->GetWidget<NWidgetBase>(wid); + const NWidgetLeaf *wi = w->GetWidget<NWidgetLeaf>(wid); assert((wi->type & WWT_MASK) == WWT_EDITBOX); int left = wi->pos_x; @@ -786,6 +786,7 @@ void QueryString::DrawEditBox(const Window *w, int wid) const int top = wi->pos_y; int bottom = wi->pos_y + wi->current_y - 1; + DrawFrameRect(left, top, right, bottom, wi->colour, FR_LOWERED | FR_DARKENED); GfxFillRect(left + 1, top + 1, right - 1, bottom - 1, PC_BLACK); /* Limit the drawing of the string inside the widget boundaries */ |