From 5a1e588c3fbdce549e0b3c487e2671c679890675 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Sat, 30 Mar 2019 17:32:24 +0100 Subject: Get rid of Presentation structure It doesn't have any reason to exist. A Narrative defines the top-level object already. This is, after all, a narrative-based presentation system. This removes a lot of faff surrounding retrieving the Narrative from the Presentation. It also removes a gigantic place for bugs to hide in keeping the Presentation's view of the slides in sync with the Narrative's opinion. What was that quote? "Code is terrible, and we want as little of it as possible in our program." --- libstorycode/gtk/gtknarrativeview.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'libstorycode/gtk/gtknarrativeview.h') diff --git a/libstorycode/gtk/gtknarrativeview.h b/libstorycode/gtk/gtknarrativeview.h index c85ca1f..82fd215 100644 --- a/libstorycode/gtk/gtknarrativeview.h +++ b/libstorycode/gtk/gtknarrativeview.h @@ -32,7 +32,6 @@ #include #include -#include #include #include @@ -66,7 +65,7 @@ struct _gtknarrativeview GtkDrawingArea parent_instance; /*< private >*/ - Presentation *p; + Narrative *n; GtkIMContext *im_context; int w; /* Surface size in pixels */ @@ -101,7 +100,7 @@ typedef struct _gtknarrativeview GtkNarrativeView; typedef struct _gtknarrativeviewclass GtkNarrativeViewClass; extern GType gtk_narrative_view_get_type(void); -extern GtkWidget *gtk_narrative_view_new(Presentation *p); +extern GtkWidget *gtk_narrative_view_new(Narrative *n); extern void gtk_narrative_view_set_logical_size(GtkNarrativeView *e, double w, double h); -- cgit v1.2.3