Thank you for the response. I was able to solve the issue as follows: When I want to destroy the window I check if the window is visible. If it is not visible I simply do iup.Destroy. If the window is visible then it has to be destroyed whenever the user closes it so I set a flag indicating that the close_cb callback should destroy it.
In the close_cb call back if the flag is set I destroy the window otherwise I just hide it. Attached is the working file for the same test case. Thanks, Milind On Wed, Jul 9, 2014 at 5:33 AM, Antonio Scuri <[email protected]> wrote: > No, this message did not hit the list before. > > Your logic is inverted compared to I suggest you. You should set a flag in > close_cb and use it in the timer callback. > > Best, > Scuri > > > On Tue, Jul 8, 2014 at 4:33 PM, Milind Gupta <[email protected]> > wrote: > >> I don't know if my last message made it to the list so I am posting it >> again: >> >> I am not sure if I understood properly but here is what I tried: >> >> 1. Defined the close_cb callback for the dialog. The function always >> returns iup.IGNORE >> 2. If a variable value is true then only it will destroy the dialog >> otherwise just do iup.Hide for the dialog >> 3. When I do want to destroy it in the timer call back I simply call the >> callback function directly something like dlg:close_cb() after setting the >> variable value to true so that this time the call destroys it. >> >> I did this but I still see the crash. I have attached the modified file. >> The close_cb function is defined at line 68. >> >> Thanks Ariset for suggesting HIDETASKBAR but I did not understand how >> would that be different from the above approach. >> >> Thanks, >> Milind >> >> >> ------------------------------------------------------------------------------ >> Open source business process management suite built on Java and Eclipse >> Turn processes into business applications with Bonita BPM Community >> Edition >> Quickly connect people, data, and systems into organized workflows >> Winner of BOSSIE, CODIE, OW2 and Gartner awards >> http://p.sf.net/sfu/Bonitasoft >> _______________________________________________ >> Iup-users mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/iup-users >> >> > > > ------------------------------------------------------------------------------ > Open source business process management suite built on Java and Eclipse > Turn processes into business applications with Bonita BPM Community Edition > Quickly connect people, data, and systems into organized workflows > Winner of BOSSIE, CODIE, OW2 and Gartner awards > http://p.sf.net/sfu/Bonitasoft > _______________________________________________ > Iup-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/iup-users > >
plotter.lua
Description: Binary data
------------------------------------------------------------------------------ Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft
_______________________________________________ Iup-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/iup-users
