ag_app_open_chart() now saves the URI of the opened chart to the created window

This commit is contained in:
Gergely Polonkai 2013-09-18 10:40:17 +02:00
parent bdf318a2ad
commit d26f9f5d8b

View File

@ -110,11 +110,15 @@ ag_app_open_chart(AgApp *app, GFile *file)
GtkWidget *window;
AgChart *chart;
GError *err = NULL;
gchar *uri;
chart = ag_chart_load_from_file(file, &err);
window = ag_app_create_window(app);
ag_window_set_chart(AG_WINDOW(window), chart);
ag_window_update_from_chart(AG_WINDOW(window));
uri = g_file_get_uri(file);
ag_window_set_uri(AG_WINDOW(window), uri);
g_free(uri);
}
static void