aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorThomas White <taw@bitwiz.org.uk>2011-11-09 00:18:39 +0100
committerThomas White <taw@bitwiz.org.uk>2011-11-09 00:18:39 +0100
commit653e89ca19c679253a24e71e7049c423bbf67440 (patch)
treefb1cd04eed610b8fce64b12540de0c2ba844af81 /src
parent0bcf6185b031ccd74e6c39bdfb5d21a71e8992b1 (diff)
Formatting
Diffstat (limited to 'src')
-rw-r--r--src/mainwindow.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mainwindow.c b/src/mainwindow.c
index dfd3fe6..380e37d 100644
--- a/src/mainwindow.c
+++ b/src/mainwindow.c
@@ -127,19 +127,24 @@ static gint open_response_sig(GtkWidget *d, gint response,
filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(d));
if ( p->completely_empty ) {
+
if ( load_presentation(p, filename) ) {
show_error(p, "Failed to open presentation");
}
redraw_slide(p->cur_edit_slide);
update_toolbar(p);
+
} else {
+
struct presentation *p;
+
p = new_presentation();
if ( load_presentation(p, filename) ) {
show_error(p, "Failed to open presentation");
} else {
open_mainwindow(p);
}
+
}
g_free(filename);