Intuition window goes OOP(ish)

From Freepascal Amiga wiki
Revision as of 19:59, 27 March 2017 by Molly (talk | contribs) (initial setup)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

A long while ago, someone on the aros-exec forums suggested to use some (more) OOP to create f.i. native Intuition Windows.

Although i already knew it is possible to do, i never managed to create a example for those wanting to have a look. So here we go :-)

Do note however, that the code showed herein is not complete, nor does it show good programing practice (even far from that). It is merely shown as a possible solution to the problem. Much more abstraction is required in order to be able to make practical use of these examples.

The beginning =

Let's start out with a simple intuition window example, this example was taken from Thomas Rapp.

[code=pascal]

[/code]

We need a class

Move around message handling

Dispatching messages

Implement message handlers

What's next ?