Fixed startup in thumbnail mode with floating window

This commit is contained in:
Bert Münnich 2014-09-26 20:45:15 +02:00
parent eaa269b6cb
commit c1e084357c
1 changed files with 5 additions and 3 deletions

8
main.c
View File

@ -671,8 +671,6 @@ void run(void)
bool discard, to_set; bool discard, to_set;
XEvent ev, nextev; XEvent ev, nextev;
set_timeout(redraw, 25, false);
while (true) { while (true) {
while (mode == MODE_THUMB && tns.loadnext < tns.end && while (mode == MODE_THUMB && tns.loadnext < tns.end &&
XPending(win.env.dpy) == 0) XPending(win.env.dpy) == 0)
@ -881,10 +879,14 @@ int main(int argc, char **argv)
tns.thumbs = NULL; tns.thumbs = NULL;
load_image(fileidx); load_image(fileidx);
} }
win_open(&win); win_open(&win);
win_set_cursor(&win, CURSOR_WATCH); win_set_cursor(&win, CURSOR_WATCH);
if (mode == MODE_THUMB)
tns_render(&tns);
set_timeout(redraw, 25, false);
run(); run();
cleanup(); cleanup();