perry@well.UUCP (Perry S. Kivolowitz) (02/12/86)
It'd be nice if each gadget structure contained a pointer to the message port Intuition would send messages to about this gadget. Usually, the message port would be owned by the task that owns the window. But, sometimes (and this is the reason for the idea) the message port can be owned by a completely unrelated task. This would allow me to insert a gadget into (for example) the screen title bar. The gadget would be linked into the screen's gadget list but point to the message port of (for example) a calculator program. Click on the screen gadget and up comes the calculator (a la Morkintosh). Difficulties with this that would need to be solved before this facility can become truely generalized include: (1) General (predictable) algorithm for placement of border gadgets. Can I easily find out where it would be safe for me to write my gadget on your screen. The information to do this is already available but might be cleaned up a bit. (2) When a screen or window closes that has been ``invaded'' the closing task might like to go through its gadget list deallocating whatever memory and such the gadget might have had allocated to it. Programs would need to understand that not all gadgets on your gadget list are really yours. This also means another Intuition Message would need to be created. Saying to the gadget owning process that the task that was presenting the gadget has gone away. All in all it'd be a nice generalization of the way tasks interact with gadgets. Perry S. Kivolowitz