passing a widget to a function in g_io_add_watch
- From: Kent Nyberg <blurk telia com>
- To: Gtk App Devel <gtk-app-devel-list gnome org>
- Subject: passing a widget to a function in g_io_add_watch
- Date: 20 Dec 2001 21:35:28 +0100
Hello!
I have a function which i use in g_io_add_watch.
In that function i want to use glades lookup_widget to find some widgets
in the UI to be able to change some information there.
The thing is that i dont know how to do that.
lookup_widget needs one widget to search for the others.. and i dont
have one there :(
All the calback-functions that glade created have for example:
on_start_the_server1_activate (GtkMenuItem *menuitem,
gpointer user_data)
In that function i can use menuitem to lookup the widgets that i need,
but how do i do that in a function I created my self?
I pass this function to the g_io_add_watch:
static gboolean
server_function(GIOChannel *channel, GIOCondition cond, gpointer data);
There is no widget in there.. so what should i do?
I have not realy ever learned what "gpointer data" is for.. but i guess
that i can use that to pass a widget to my function, is that correct?
And if so, how do i do it?
I realy hope you understand me here.. :)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]