David Cuny's GUI
- Posted by Mike Burrell <a00000hg at SOFTHOME.NET> Nov 09, 1997
- 587 views
hey i'm using david cuny's gui and i want to make a dialog box that will track the progress of a fairly cpu intensive operation...so like it's doin a whole bunch of stuff and while it's doing it says like "64% done" and "24 seconds elapsed" and all stuff like that what i'm trying to do right now is set up the dialog: new_dialog("Progress", 0, 0, 50, 6, {}) add_control(1, BUTTON, "&Cancel", 4, 2, 12, 0, {CANCEL_BUTTON}) add_control(2, LABEL, "", 2, 2, 0, 0, {}) -- progress indicator okay and then what i want to do is: (in pseudocode) while get_dialog(EXIT_STATE) != CANCELLED do progress = do_stuff() set_attrib(2, TITLE, sprintf("%d precent done", progress)) show_dialog() end while except it doesn't really work...and i can't really do edit_dialog() at all because then it would wait for a key to be pressed or whatever :\ any suggestions? -- Mike Burrell http://mikpos.base.org/ mikpos at hempseed.com