summaryrefslogtreecommitdiff
path: root/textscreen/txt_widget.c
diff options
context:
space:
mode:
authorSimon Howard2006-05-20 16:34:34 +0000
committerSimon Howard2006-05-20 16:34:34 +0000
commit62b5f953677addeebac38ab6774599bbbab130f0 (patch)
tree66a787570daedf15c342099784e7ed9a1a8f30b0 /textscreen/txt_widget.c
parentbb630087923d51ce190461e8aba044bff04249eb (diff)
downloadchocolate-doom-62b5f953677addeebac38ab6774599bbbab130f0.tar.gz
chocolate-doom-62b5f953677addeebac38ab6774599bbbab130f0.tar.bz2
chocolate-doom-62b5f953677addeebac38ab6774599bbbab130f0.zip
Add main loop function and forward key presses to widgets.
Subversion-branch: /trunk/chocolate-doom Subversion-revision: 490
Diffstat (limited to 'textscreen/txt_widget.c')
-rw-r--r--textscreen/txt_widget.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/textscreen/txt_widget.c b/textscreen/txt_widget.c
index 68e3d9b5..de79beb7 100644
--- a/textscreen/txt_widget.c
+++ b/textscreen/txt_widget.c
@@ -17,12 +17,14 @@ void TXT_DestroyWidget(txt_widget_t *widget)
widget->widget_class->destructor(widget);
}
-void TXT_WidgetKeyPress(txt_widget_t *widget, int key)
+int TXT_WidgetKeyPress(txt_widget_t *widget, int key)
{
if (widget->widget_class->key_press != NULL)
{
- widget->widget_class->key_press(widget, key);
+ return widget->widget_class->key_press(widget, key);
}
+
+ return 0;
}