[Gtk-sharp-list] Any way to trigger a method call when Gtk.Application.Run() is called?
Adam R.
darkelyte.mono at mailnull.com
Wed May 19 12:58:13 EDT 2010
I am writing an application that needs to run some code when the app first
starts up. I would prefer this code to run after Gtk.Application.Run() is
called, but I have not found a way to detect when the main loop has started.
The code should run after the main loop has started because it is capable of
calling Application.Quit if there is a problem, and this doesn't seem to
work if Application.Run has not been called first.
I was hoping there was an event I could listen for from Gtk.Application that
is fired when the main loop starts, or even a property I could check (like
Gtk.Application.IsRunning) from a background thread before running this
code, but I haven't had any luck finding something along those lines.
Could someone provide some insight into how to approach this? Is there a way
to accomplish what I am after, or is there a better approach to use? Any
input would be appreciated.
--
View this message in context: http://mono.1490590.n4.nabble.com/Any-way-to-trigger-a-method-call-when-Gtk-Application-Run-is-called-tp2223200p2223200.html
Sent from the Mono - Gtk# mailing list archive at Nabble.com.
More information about the Gtk-sharp-list
mailing list