summaryrefslogtreecommitdiff
path: root/gui/index.c
diff options
context:
space:
mode:
authorWerner Almesberger <werner@almesberger.net>2016-08-24 02:01:30 -0300
committerWerner Almesberger <werner@almesberger.net>2016-08-24 02:01:30 -0300
commitef5150170a0a26f79b2ddfed3d0815aaf48781ac (patch)
tree1f1a342e5e78f76942ce26122625194f337422b9 /gui/index.c
parent6e07f89c6fd2cf86e25fa245c2688d8c2e20be95 (diff)
downloadeeshow-ef5150170a0a26f79b2ddfed3d0815aaf48781ac.tar.gz
eeshow-ef5150170a0a26f79b2ddfed3d0815aaf48781ac.tar.bz2
eeshow-ef5150170a0a26f79b2ddfed3d0815aaf48781ac.zip
gui/: move resizing back to gui.c; support resizing index
Diffstat (limited to 'gui/index.c')
-rw-r--r--gui/index.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/gui/index.c b/gui/index.c
index d9dd9bd..62dd259 100644
--- a/gui/index.c
+++ b/gui/index.c
@@ -274,6 +274,18 @@ static const struct input_ops index_input_ops = {
};
+/* ----- Resizing ---------------------------------------------------------- */
+
+
+void index_resize(struct gui_ctx *ctx)
+{
+ overlay_remove_all(&ctx->thumb_overlays);
+ best_ratio(ctx);
+ index_render_sheets(ctx);
+ redraw(ctx);
+}
+
+
/* ----- Initialization ---------------------------------------------------- */
@@ -281,7 +293,5 @@ void show_index(struct gui_ctx *ctx)
{
input_push(&index_input_ops, ctx);
ctx->mode = showing_index;
- best_ratio(ctx);
- index_render_sheets(ctx);
- redraw(ctx);
+ index_resize(ctx);
}