<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Oct 21, 2008, at 2:54 PM, angico wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"> <div>How could I send a message to a widget? Say, I want to have a modal window to be closed after a specified timeout. How could I send it a "default" ID_CANCEL or ID_ACCEPT message, in order to have it close itself and return control to its parent window?</div></blockquote><div><br></div><div>This should do the trick:</div><div><br></div><span class="Apple-tab-span" style="white-space:pre">        </span>dialog.handle(self, FXSEL(SEL_COMMAND, FXDialogBox::ID_ACCEPT), nil)</div><div><br></div><div>Hope this helps,</div><div><br></div><div>Lyle</div><div><br></div><div apple-content-edited="true"> <span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div><div><div><div><div><div><div>---<br><div apple-content-edited="true"><div><div><div><div><div><div>"FXRuby: Create Lean and Mean GUIs with Ruby"</div><div>Now available from the Pragmatic Bookshelf!</div><div><a href="http://www.pragprog.com/titles/fxruby">http://www.pragprog.com/titles/fxruby</a></div><div><br></div></div></div></div></div></div></div></div></div></div></div></div></div></div><br></div><br></div></span><br class="Apple-interchange-newline"> </div><br></body></html>