Using Gtk.Application.Invoke().
Minor refactoring.