diff options
author | Thomas White <taw@bitwiz.org.uk> | 2013-05-09 23:02:04 +0200 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2013-05-09 23:02:04 +0200 |
commit | 7ca0e4e398cea2e93b2597985b9f449d67060a39 (patch) | |
tree | 82c8b94d9a6242c850702d152924c4e486c0bbfa /src/slideshow.c | |
parent | 25f620f05b4f3ebee41e38ae4d58e3147a1a2bfa (diff) |
Make stuff work
Diffstat (limited to 'src/slideshow.c')
-rw-r--r-- | src/slideshow.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/slideshow.c b/src/slideshow.c index 0b2b865..6594be8 100644 --- a/src/slideshow.c +++ b/src/slideshow.c @@ -58,7 +58,6 @@ static gint ss_destroy_sig(GtkWidget *widget, struct presentation *p) static gboolean ss_draw_sig(GtkWidget *da, cairo_t *cr, struct presentation *p) { - GtkAllocation allocation; double xoff, yoff; double width, height; @@ -79,9 +78,8 @@ static gboolean ss_draw_sig(GtkWidget *da, cairo_t *cr, struct presentation *p) h = p->proj_slide_width * p->slide_height / p->slide_width; /* Get the overall size */ - gtk_widget_get_allocation(da, &allocation); - xoff = (allocation.width - p->proj_slide_width)/2.0; - yoff = (allocation.height - h)/2.0; + xoff = (width - p->proj_slide_width)/2.0; + yoff = (height - h)/2.0; /* Draw the slide from the cache */ cairo_rectangle(cr, xoff, yoff, p->proj_slide_width, h); @@ -258,6 +256,8 @@ void try_start_slideshow(struct presentation *p) } /* FIXME: Sensible (configurable) choice of monitor */ + rerender_slide(p); + p->slideshow = n; p->slideshow_linked = 1; gtk_window_fullscreen(GTK_WINDOW(n)); |