Get the correct adjustment

Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
This commit is contained in:
Sebastian Ramacher 2013-11-05 02:29:20 +01:00
parent 403d867ca4
commit 903dae55e0

View file

@ -700,9 +700,9 @@ document_open(zathura_t* zathura, const char* path, const char* password,
GtkAdjustment* vadjustment = gtk_scrolled_window_get_vadjustment( GtkAdjustment* vadjustment = gtk_scrolled_window_get_vadjustment(
GTK_SCROLLED_WINDOW(zathura->ui.session->gtk.view)); GTK_SCROLLED_WINDOW(zathura->ui.session->gtk.view));
const unsigned int view_width = (unsigned int)floor(gtk_adjustment_get_page_size(vadjustment)); const unsigned int view_width = (unsigned int)floor(gtk_adjustment_get_page_size(hadjustment));
zathura_document_set_viewport_width(zathura->document, view_width); zathura_document_set_viewport_width(zathura->document, view_width);
const unsigned int view_height = (unsigned int)floor(gtk_adjustment_get_page_size(hadjustment)); const unsigned int view_height = (unsigned int)floor(gtk_adjustment_get_page_size(vadjustment));
zathura_document_set_viewport_height(zathura->document, view_height); zathura_document_set_viewport_height(zathura->document, view_height);
/* create blank pages */ /* create blank pages */