Fixed build warnings. More TODOs.

This commit is contained in:
Pietro Gagliardi 2015-04-15 23:14:36 -04:00
parent bb81eebefe
commit 7b73734854
6 changed files with 8 additions and 8 deletions

View File

@ -10,9 +10,10 @@
- make sure all terminology is consistent
- 32-bit Mac OS X support (requires lots of code changes)
- add a test for hidden controls when a window is shown
- WS_CLIPCHILDREN
- SWP_NOCOPYBITS (or was it WS_CLIPCHILDREN?)
- buttons not in tab get drawover issues
- buttons in tab without transparent drawing code get copied into the label when stack shown and rehidden
- see if we can clean up the GTK+ backend
ultimately:
- make everything vtable-based
@ -21,3 +22,4 @@ ultimately:
- figure out what to do about custom containers
- rename container to parent?
- make the code flow of all platforms fully symmetrical
- add some sort of runtime type checking

View File

@ -3,7 +3,7 @@
struct button {
uiButton b;
void (*onClicked)(uiControl *, void *);
void (*onClicked)(uiButton *, void *);
void *onClickedData;
};
@ -38,7 +38,7 @@ static void setText(uiButton *b, const char *text)
gtk_button_set_label(BUTTON(b), text);
}
static void setOnClicked(uiButton *bb, void (*f)(uiControl *, void *), void *data)
static void setOnClicked(uiButton *bb, void (*f)(uiButton *, void *), void *data)
{
struct button *b = (struct button *) bb;

View File

@ -31,12 +31,12 @@ static void onDestroy(GtkWidget *widget, gpointer data)
static char *getText(uiCheckbox *c)
{
return g_strdup(gtk_button_get_label(CHECKBOX(c)));
return g_strdup(gtk_button_get_label(GTK_BUTTON(CHECKBOX(c))));
}
static void setText(uiCheckbox *c, const char *text)
{
gtk_button_set_label(CHECKBOX(c), text);
gtk_button_set_label(GTK_BUTTON(CHECKBOX(c)), text);
}
static void setOnToggled(uiCheckbox *cc, void (*f)(uiCheckbox *, void *), void *data)

View File

@ -222,5 +222,4 @@ void uiUnixNewControl(uiControl *c, GType type, gboolean inScrolledWindow, gbool
gtk_widget_show_all(s->immediate);
c->Internal = s;
return c;
}

View File

@ -43,7 +43,6 @@ static void addPage(uiTab *tt, const char *name, uiControl *child)
uiTab *uiNewTab(void)
{
uiControl *c;
struct tab *t;
GtkWidget *widget;

View File

@ -15,7 +15,7 @@ static gboolean onClosing(GtkWidget *win, GdkEvent *e, gpointer data)
struct window *w = (struct window *) data;
// return exact values just in case
if ((*(w->onClosing))(w, w->onClosingData))
if ((*(w->onClosing))(uiWindow(w), w->onClosingData))
return FALSE;
return TRUE;
}