Re: object oriented approach
| From: | Sky | Date: | Sat, 13 Dec 2003 13:20:09 +0000 |
| Subject: | Re: object oriented approach | ||
| References: | 1 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-4295@lists.php.net to get a copy of this message | ||
Also such as...
class clicky {
function clicky() {
$button = &new GtkButton('Clicky!');
$button->connect('clicked', array(&$this, 'clickied'));
}
function clickied() {
echo 'The button was clickied!';
}
}
$clicky = new clicky;
"Szilard Novaki" <novaki@dcs.vein.hu> wrote in message
news:1071314300.32725.4.camel@localhost...
> Hi!
>
> I'm a newbie at php-gtk. It's very impressive, but i'd like to use it in
> object oriented way.
>
> I've read a hello-world application. It very simple, but I could not
> convert it to an object oriented structure, because the event callback
> (as far as I see) is a php function. Could anyone send me an object
> oriented php-gtk application, where the gtk widgets are objects? A hello
> world application would be just fine.
>
> Thank you,
> Szilard