summaryrefslogtreecommitdiff
path: root/navit/gui.c
diff options
context:
space:
mode:
authormartin-s <martin-s@ffa7fe5e-494d-0410-b361-a75ebd5db220>2009-02-01 16:07:50 +0000
committermartin-s <martin-s@ffa7fe5e-494d-0410-b361-a75ebd5db220>2009-02-01 16:07:50 +0000
commit48194427ce8fc25ce59e9aa55c0a6b9900f53585 (patch)
tree7f54fc0d98f2cf137296ec5d11a9ea412242ebb2 /navit/gui.c
parent2cdf13b06ed12db1a04084b4cd67898d480f308a (diff)
downloadnavit-48194427ce8fc25ce59e9aa55c0a6b9900f53585.tar.gz
Add:Core:Added c style command evaluation for more flexible osds
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@1987 ffa7fe5e-494d-0410-b361-a75ebd5db220
Diffstat (limited to 'navit/gui.c')
-rw-r--r--navit/gui.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/navit/gui.c b/navit/gui.c
index 662fa388e..28b2132cd 100644
--- a/navit/gui.c
+++ b/navit/gui.c
@@ -20,6 +20,7 @@
#include <glib.h>
#include <string.h>
#include "debug.h"
+#include "callback.h"
#include "gui.h"
#include "menu.h"
#include "data_window.h"
@@ -38,6 +39,7 @@ gui_new(struct attr *parent, struct attr **attrs)
struct gui *this_;
struct attr *type_attr;
struct gui_priv *(*guitype_new)(struct navit *nav, struct gui_methods *meth, struct attr **attrs);
+ struct attr cbl;
if (! (type_attr=attr_search(attrs, NULL, attr_type))) {
return NULL;
}
@@ -47,8 +49,11 @@ gui_new(struct attr *parent, struct attr **attrs)
return NULL;
this_=g_new0(struct gui, 1);
- this_->priv=guitype_new(parent->u.navit, &this_->meth, attrs);
this_->attrs=attr_list_dup(attrs);
+ cbl.type=attr_callback_list;
+ cbl.u.callback_list=callback_list_new();
+ this_->attrs=attr_generic_add_attr(this_->attrs, &cbl);
+ this_->priv=guitype_new(parent->u.navit, &this_->meth, this_->attrs);
return this_;
}