From martin.schoettler at matique.de Thu Sep 15 23:53:06 2011 From: martin.schoettler at matique.de (=?UTF-8?Q?Martin_Sch=C3=B6ttler?=) Date: Thu, 15 Sep 2011 20:53:06 -0700 (PDT) Subject: [fxruby-users] Finish Button disappears on last panel of FXWizard Message-ID: <32454694.post@talk.nabble.com> Hi Patrick, I see the same issue: Connecting the buttons (advanceButton, finishButton) by SEL_COMMAND does not yield the desired result. But connecting the FXWizard object to SEL_UPDATE works: wiz.connect( SEL_UPDATE ){ ... } In the block you may check which screen is the current one by wiz.container.current (0 for the first screen, 1 for the second ) and whether the Wizard has been finished wiz.shown? (true if not finished, false if finished). As the SEL_UPDATE event comes periodically, I firstly check whether something has changed, and leave the block immediately if not: @current = -1 wiz.connect( SEL_UPDATE ){ exit unless wiz.shown? # finish has been pressed unless @current == wiz.container.current @current = wiz.containter.current ... # now call a handler for the current page end } It took me some hours to come to this solution, as I found only few hints for FXRuby/FXWizard by Google. I hope there are no misspellings in the solution above, as I now write this down from memory. Martin patrick-194 wrote: > > require 'rubygems' > require 'fox16' > include Fox app = FXApp.new > wiz = FXWizard.new(app, 'wiz', nil, :width => 640, :height => 480) > ... > wiz.finishButton.connect(SEL_COMMAND) { exit } > ... > It seems that when I add attach a command to the wiz.finishButton, when > the time comes for it to appear (on the last panel) it disappears... > > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > -- View this message in context: http://old.nabble.com/Finish-Button-disappears-on-last-panel-of-FXWizard-tp25656458p32454694.html Sent from the FXRuby Users mailing list archive at Nabble.com. From djlewis at triadic.com Wed Sep 21 15:03:08 2011 From: djlewis at triadic.com (David Lewis) Date: Wed, 21 Sep 2011 15:03:08 -0400 Subject: [fxruby-users] flushing - stops when app window is moved Message-ID: I'm trying to get an FXRuby app to keep its window in sync with the application -- in particular the progress bar freezes until the loop is done. Following instructions in the FAQ at... http://www.fox-toolkit.org/faq.html#CLIENTSERVER ... I put in an app.flush to make sure the screen stayed in sync with the actual updates. I know that is expensive, but I wanted to make sure. I also preceded flush with forceRefresh. It worked fine -- until -- I moved the application window with the mouse or obscured it with another window. Then the app window froze again until the end of the loop. This is quite a mystery to me, as I am still issuing flushes. In fact, the entire app window gets tagged "not responding" by Windows and goes dim if I persist in trying to click in it. I guess I could put in a delay, to let the queue empty, but that would really slow things down. Why don't the standard functions (flush, etc) seem to work? This is in Win 7, Ruby 192. Thanks. --David. -------------- next part -------------- An HTML attachment was scrubbed... URL: From djlewis at triadic.com Wed Sep 21 21:41:37 2011 From: djlewis at triadic.com (djlewis) Date: Wed, 21 Sep 2011 18:41:37 -0700 (PDT) Subject: [fxruby-users] flush -- doesn't work after main window is moved or obscured Message-ID: <32503788.post@talk.nabble.com> I'm trying to get an FXRuby app to keep its window in sync with the application -- in particular the progress bar freezes until the loop is done. Following instructions in the FAQ at... http://www.fox-toolkit.org/faq.html#CLIENTSERVER ... I put in an app.flush to make sure the screen stayed in sync with the actual updates. I know that is expensive, but I wanted to make sure. I also preceded flush with forceRefresh. It worked fine -- until -- I moved the application window with the mouse or obscured it with another window. Then the app window froze again until the end of the loop. This is quite a mystery to me, as I am still issuing flushes. In fact, the entire app window gets tagged "not responding" by Windows and goes dim if I persist in trying to click in it. I guess I could put in a delay, to let the queue empty, but that would really slow things down. Why don't the standard functions (flush, etc) seem to work? This is in Win 7, Ruby 192. Thanks. --David. -- View this message in context: http://old.nabble.com/flush----doesn%27t-work-after-main-window-is-moved-or-obscured-tp32503788p32503788.html Sent from the FXRuby Users mailing list archive at Nabble.com.