[Lazarus] Modal forms: block parent form or application

Andreas Schneider aksdb at gmx.de
Sun Jan 30 11:18:31 CET 2011


On Sunday, January 30, 2011 00:13 cobines wrote:
> But what about dialog boxes with buttons requiring user input? Usually
> you want to have result which button was pressed and such dialog boxes
> are shown as modal with ModalResult returned. Showing OpenFile dialog,
> showing messages with ShowMessage or asking user for input with
> InputQuery, all such cases result in all windows in the application
> being blocked.

Well, IMHO these windows are called "dialog" for a reason. If you were
in  a dialog with me and I asked you something, I would be offended if
you turned away, talked to a bunch of other people first and THEN come
back to finally answer my question.
Or  more  specifically  in these cases: if you click a button to enter
some  information  (InputQuery),  you  most  likely  already know - or
should  know  -  what  you  want to enter. Similarly for the Open/Save
Dialogs.  If  you intent on saving or opening a file, you usually have
in  mind which one. So why should you be able to click around in other
windows in that time?

-- 
Best Regards,
Andreas





More information about the Lazarus mailing list