[fxruby-users] Class with looping objects

Stuart Clarke stuart_clarke86 at yahoo.com
Mon Mar 1 06:09:54 EST 2010


Hi,
I have a GUI which triggers an object to do some stuff, when you press the FXButton it calls matcher e.g.
button = FXButton.new(frame, "Run").connect(SEL_COMMAND, method(:matcher))
This button remains in a pressed state until the object has finished running, when it is complete the button pops back up. I am trying to add a popup box to respond to the button popping up (or processing finished) like so:
if button == SEL_KEYRELEASE  FXMessageBox.information(self, MBOX_OK, "Complete")  mainwindow.closeend
This however does not work, any ideas how I can acheive this?
Many thanks
--- On Fri, 26/2/10, Stuart Clarke <stuart_clarke86 at yahoo.com> wrote:

From: Stuart Clarke <stuart_clarke86 at yahoo.com>
Subject: [fxruby-users] Class with looping objects
To: fxruby-users at rubyforge.org
Date: Friday, 26 February, 2010, 19:38

Hi all,

Apologies if this is a stupid question but it is getting the best of me.

I have a class which contains a GUI object which has serveral text fields and buttons which when used trigger the use of further objects which all loop through data, the structure is as follows:

class
def GUI
GUI calls object1
end
def object1 loops through some data one entry at a time and for each entry passes to a new object
end
def object2 loops through passed data and does stuff
end
then the next bit of data does the same thing in object1


What I need is a gui that pops up when my script runs through all of objects for each bit of data. Any ideas? I just need to know when the loop is complete, at present I press the go button on my fx GUI and it stays pressed in until all processing is done then pops back out. At this point I need a Gui.

I hope this makes sense,

Many thanks


      
_______________________________________________
fxruby-users mailing list
fxruby-users at rubyforge.org
http://rubyforge.org/mailman/listinfo/fxruby-users



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/fxruby-users/attachments/20100301/0f9bd017/attachment-0001.html>


More information about the fxruby-users mailing list