Re: Frist steps on PHP-GTK

From: Date: Wed, 25 Aug 2004 18:58:31 +0000
Subject: Re: Frist steps on PHP-GTK
References: 1 2 3 4  Groups: php.gtk.general 
Request: Send a blank email to php-gtk-general+get-5007@lists.php.net to get a copy of this message
So, I can use the same method with diferents objects... Isn't it? It's great... I'm loving to learn this kind of programming! :))) > The two methods are different. I used connect_object which passes a > widget to the method when it is called. This allows my method to work > on a widget without declaring it global. Using connect_object and a > function that takes the widget as a parameter makes it a little easier > to do things like clearing a form or when you aren't sure which widget > will get changed until run time, etc... > > My today method would look like this: > > function today($widget) { > $widget->select_month((date('n')-1), date('Y')); > $widget->$calendario->select_day(date('d')); > } > > Check out the manual page for connect_object > >http://gtk.php.net/manual/en/gtk.gtkobject.method.connect_object.php > > Scott Mattocks

« previous php.gtk.general (#5007) next »