Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 348889

Summary: Support for Swing like "lazy creation" pattern in SWT
Product: z_Archived Reporter: Konstantin Scheglov <Konstantin.Scheglov>
Component: WindowBuilderAssignee: Konstantin Scheglov <Konstantin.Scheglov>
Status: CLOSED INVALID QA Contact:
Severity: enhancement    
Priority: P5 CC: clayberg
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Konstantin Scheglov CLA 2011-06-09 09:16:11 EDT
http://www.instantiations.com/forum/viewtopic.php?f=1&t=2346&p=8905#p8905

We can add support for something like this in future.

When I say "something like this", I mean that we will use same style as for "lazy creation" in Swing - each container method creates also children components (invokes
corresponding methods). In contrast, in your example hierarchy is build in single method, i.e. all single methods are invoked from single one. I think that Swing approach is better for structuring source.

This is not so easy to support however, so this will require some time.
Comment 1 Konstantin Scheglov CLA 2011-06-09 09:16:27 EDT
Probably better approach: each widget should be in field and in each parent method we just call createSomeChild() methods. Or getSomeChild() methods, but without using result of "get", just to allow to change later its modifier from "private" to "public" and allow its displaying in VI.
Comment 2 Konstantin Scheglov CLA 2011-06-09 09:19:29 EDT
There was also idea was that we can always call getSomeChild(parent), but "parent" is used only first time, during UI construction.
Comment 3 Wim Jongman CLA 2021-02-27 12:57:03 EST
Closing. Please reopen if this is still an issue.