Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

how do i make sure that it is only one instance of my dialog box that is called.  RSS feed

 
Ezeilo Uchenna
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how do i make sure that it is only one instance of my dialog box that is called.especially when the machine is slow and subsequent event triggers before dialog appears creates other dialogs.
 
Manfred Leonhardt
Ranch Hand
Posts: 1492
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ezeilo,
The easiest way would be to keep a class variable that holds a reference to the dialog. All users can first check to see if the dialog is null (none exists yet) otherwise just use the already created dialog.
Regards,
Manfred.
 
Ezeilo Uchenna
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Manfred.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!