summaryrefslogtreecommitdiff
path: root/src/window_gui.h
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2009-07-25 11:54:53 +0000
committeralberth <alberth@openttd.org>2009-07-25 11:54:53 +0000
commite3033ee895d8d621ffe2bb115b2293206db0e52f (patch)
tree8bf38b6bf210fb0fa73272deefb61347b14aba89 /src/window_gui.h
parente5bfc5660d35e408de764cde63bf376fbade37c5 (diff)
downloadopenttd-e3033ee895d8d621ffe2bb115b2293206db0e52f.tar.xz
(svn r16953) -Codechange: Use SetStringParameters() for simple parameterized strings.
Diffstat (limited to 'src/window_gui.h')
-rw-r--r--src/window_gui.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/window_gui.h b/src/window_gui.h
index 3cb1fa9f6..f44efbcc2 100644
--- a/src/window_gui.h
+++ b/src/window_gui.h
@@ -534,6 +534,14 @@ public:
virtual void UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *resize) {}
/**
+ * Initialize string parameters for a widget.
+ * Calls to this function are made during initialization to measure the size (that is as part of #InitNested()), during drawing,
+ * and while re-initializing the window. Only for widgets that render text initializing is requested.
+ * @param widget Widget number.
+ */
+ virtual void SetStringParameters(int widget) const {}
+
+ /**
* Called when window gains focus
*/
virtual void OnFocus() {}