How to coece a HWND* was: Win32Window how to get Squeak's window Handle? VM?

Herbert König herbertkoenig at gmx.net
Fri Jul 13 16:07:01 UTC 2007


Hello Sig,

you involve yourself deeply into my problems.  If we ever meet in
person, I owe you a beer!

s> can you send a function which generates VMMaker for your primitive?
s> You dont need to declare variable as HWND*.
s> You can declare its as HWND, and then put address of variable to win calls

As it's all very tiny I've filed out the plugin class and the class
using the plugin (each one method)

VMMaker generates SqueakWindowPlugin.c which I modify to
SqueakWindowPluginHko.c.

In Line 11 I include windows.h, in line 89 i make a test function to
see if I can do something with the window.

In Line 102 you find my changed primitive. Later I'll learn to use
cCode in Squeak and code it all in Squeak.

The test is, that if you uncomment the closeWindow call in line 107 it
closes the Squeak window.

Beware, it closes Squeak but leaves all files open, as I don't observe
the niceties before closing a window. It kind of slams the window and
breaks a few window panes :-))

Thanks,

Herbert                            mailto:herbertkoenig at gmx.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SqueakWindowPlugin.st
Type: application/octet-stream
Size: 649 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20070713/91204b80/SqueakWindowPlugin.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SqueakWindow.st
Type: application/octet-stream
Size: 713 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20070713/91204b80/SqueakWindow.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SqueakWindowPluginHko.c
Type: application/octet-stream
Size: 3524 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20070713/91204b80/SqueakWindowPluginHko.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SqueakWindowPlugin.c
Type: application/octet-stream
Size: 3124 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20070713/91204b80/SqueakWindowPlugin-0001.obj


More information about the Squeak-dev mailing list