From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.68.242.99 with SMTP id wp3mr17840008pbc.7.1413812321094; Mon, 20 Oct 2014 06:38:41 -0700 (PDT) X-Received: by 10.182.110.232 with SMTP id id8mr130069obb.6.1413812320739; Mon, 20 Oct 2014 06:38:40 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!news.glorb.com!uq10no14253645igb.0!news-out.google.com!bc9ni31795igb.0!nntp.google.com!h18no7930820igc.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 20 Oct 2014 06:38:40 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=66.176.73.77; posting-account=yiWntAoAAAC1KqC_shmxJYv07B9l6LNU NNTP-Posting-Host: 66.176.73.77 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <60e2e606-0953-423d-8cae-adb5bb92011d@googlegroups.com> Subject: Re: Launching Popup Windows in Gnoga From: David Botton Injection-Date: Mon, 20 Oct 2014 13:38:40 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: news.eternal-september.org comp.lang.ada:22609 Date: 2014-10-20T06:38:40-07:00 List-Id: On Monday, October 20, 2014 8:56:09 AM UTC-4, Jeremiah wrote: >I am initially working in a Singleton environment The Singleton environment is exactly the right one for Desktop apps and there is no shame in using it :) It is there for a reason. > 1. the program calls Launch to launch the window and the delays some time to allow it to come up before adding elements to it (views, buttons, etc.). Using delay is not ideal, I have been meaning to revisit that before 1.0. I'll try and do that today. > 2. I don't need to recreate the window, but simply show it again. It is a limitation of browsers, they do not allow showing and hiding windows. Once a browser window is closed the browser has already cleared all its data, no way to recover. So you would need to create a new Gnoga object and launch that. Alternatives: 1) You could use an iFrame (if loading html from a third party) which is like any other Element_Type and Hidden (true) and Hidden (false) can be called on it. 2) You could create a view_type In both the above you do something like: My_Dialog.Position (Absolute); My_Dialog.Left (Main_Window.Width / 2 - My_Dialog.Width); -- Center Dialog on Horizontal My_Dialog.Top (Main_Window.Height /2 - My_Dialog.Height); -- Center Dialog on Vertical Then you can use these: (take a look at Gnoga.Gui.Element for the different methods of "hiding" and "showing") My_Dialog.Hidden (true); My_Dialog.Hidden (false); It is in the TO_DO list to create a Dialog_Type that will handle this in the near future. > 3. This is related to #2, but is there a way to create elements well enough so I can do things like attach other elements or callbacks to them but separately control when they show on the screen? You can create a view set it hidden, set up all the children inside of it then just show it when ready. > 4. Will there eventually be some more documentation on what each method and parameter are for? The specs are full with tons of info already, but I do plan on more comprehensive documentation short and long term. David Botton