Commit 85787863 authored by Sébastien Wilmet's avatar Sébastien Wilmet
Browse files

App: let Tepl handle the GApplication::activate signal

This works thanks to the abstract factory.
parent af83d340
......@@ -44,9 +44,11 @@ public class LatexilaApp : Gtk.Application
setup_main_option_entries ();
startup.connect (startup_cb);
activate.connect (activate_cb);
open.connect (open_documents);
shutdown.connect (shutdown_cb);
Tepl.Application tepl_app = Tepl.Application.get_from_gtk_application (this);
tepl_app.handle_activate ();
}
public static LatexilaApp get_instance ()
......@@ -141,18 +143,6 @@ public class LatexilaApp : Gtk.Application
release ();
}
private void activate_cb ()
{
hold ();
if (get_active_main_window () == null)
create_window ();
else
active_window.present ();
release ();
}
private void shutdown_cb ()
{
hold ();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment