[Oberon] FPGA - OberonV4 Dialogs

Tomas Kral thomas.kral at email.cz
Tue Nov 27 11:11:33 CET 2018


On Thu, 15 Nov 2018 10:52:40 +0100
Jörg <joerg.straube at iaeth.ch> wrote:

> Either you store the type info you got by the module Type.Mod or -
> cleaner - you call an instantiation routine of the module where you
> imported the POINTER from and let that module do its job.

My understanding is that Dialogs.Load() scans `*.Dlg' (meta?) file for module names, reading further some static and dynamic data.

PROCEDURE LoadP (p: Panel; VAR r: Files.Rider);
	(** reads the panel from rider r *)
BEGIN
	...
	WHILE V{elements-count} > 0 DO
		P{Get Module Name} 
		P{Load Name}
		P{Init Module with Dlg data} 
	END ;
DONE.

For loading part, it does some magic with `Types'
Types.NewObj (o, Types.This (Modules.ThisMod (module), name)); ASSERT (o # NIL);

Could be it recoded to something like this?
Modules.Load(name, dlgItem);
Modules.ThisCommand(dlgItem, "Init()");

Many thanks and apologies for asking too much.

-- 
Tomas Kral <thomas.kral at email.cz>


More information about the Oberon mailing list