Re: Basic OOP style app driving me crazy
| From: | Christian Weiske | Date: | Tue, 24 Jan 2006 06:36:57 +0000 |
| Subject: | Re: Basic OOP style app driving me crazy | ||
| References: | 1 2 3 4 5 6 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-6558@lists.php.net to get a copy of this message | ||
Michael,
> Well, I had fleshed out my app into a class, but it would never actually
> run, no errors, no shell window, nothing, on W2K.
>
> I've removed just about everything, and I can't even get a blank window
> to pop up... Halp!?
> $app = new myApp();
> $app->run();
> function myApp() {
> $oWin = &$this->oWin;
> $oWin = &new GtkWindow();
- use "&" when instantiating your own classes that have widgets, too
- switch the two $oWin lines
- move all the things from the constructor into a new funciton, then do
the following:
$app = new myApp();
$app->loadAllTheThings();
$app->run();
Unfortunately I can't test the script myself as I have php-gtk2 only
installed.
--
Regards/MfG,
Christian Weiske
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc