Laurent ROCHER wrote:
> hello

hi Laurent!

>>     -onClick => \&DoSomething
>
> Good.

yup :-)

> Not obscure at all ;-) but a very difficult point.
> I have think a little about this and i have notice 2 things.
>
>     * With only one event fonction (actual NEM)
>
> it's possible to call the DoSomethingElse function in the
> DoSomething function.

yes, I know, but in your example the 'implementer' is responsible
for calling the package event (eg. $self->OnClick), which is not a
good way to create subpackages... so I don't like this approach.

>     * With event queue
>
> Problem for the new package method.
>
> For example :
>         - the package need to add a click event function
>         - the user create an object with a click event function
>
>     How create the click event array ?

yes, that's the problem. I haven't figured yet a 'package-writers'
API... I should think of a real world example of this and try to
model in pseudocode first :-)

>         - order problem between user event and package event.

package event should always come first and decide what to do
(eg. do some stuff, then cal user event, then do some other
stuff... or don't call the user event at all, if it so decides).

>         - If user don't want default package click event.

this should be left as an option to the package writer. for
example, s?he could relay on the user event's return value.
0 == don't process default (package) event, 1 == process it.
this is the way Win32::GUI actually works with DefWindowProc()
after all.

>> **** Win32::GUI::JPEG
>> allow *read* support for JPEG images, using libjpeg (see
>> ftp://ftp.uu.net/graphics/jpeg). JPEG files can be converted
>> to in-memory bitmaps and then used as regular Bitmap objects.
>> (NOTE: I'm *not going* to develop Win32::GUI::GIF. GIF is
>> absolutely deprecated, I'll look into PNG support eventually).

> After some search about this point, I found a free open source
> code project named FreeImage.

way cool, I will implement this. seems lot easier than libjpeg
(even the installation is much easier and it comes with binaries
too). BTW, I will also try to release a standalone Perl module
for this library (eg. Image::Free :-).

> I can help you for this point.

you're welcome! let's discuss it on Perl-Win32-GUI-hackers.


cheers,
Aldo

__END__
$_=q,just perl,,s, , another ,,s,$, hacker,,print;



Reply via email to