From 89cc2518f313afc5da650f327af838fa4e1b79ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Ankarstr=C3=B6m?= Date: Mon, 4 Apr 2022 21:56:22 +0200 Subject: Don't start updating episode list until after window is drawn. This ensures the window is displayed before the episodes are loaded, which is important on slow internet connections. --- c/main.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'c/main.c') diff --git a/c/main.c b/c/main.c index b40bb83..3b370ff 100644 --- a/c/main.c +++ b/c/main.c @@ -30,9 +30,10 @@ WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR tszErr; MSG msg; INITCOMMONCONTROLSEX icc; + term_t t; WNDCLASSEX wc; - /* Set constant globals. */ + /* Set constant values. */ hModule = LoadLibrary(TEXT("uxtheme.dll")); BThemes = hModule && GetProcAddress(hModule,"SetWindowTheme"); if (hModule) FreeLibrary(hModule); @@ -81,6 +82,12 @@ WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, if (!hWnd) goto f; ShowWindow(hWnd, nCmdShow); + /* Populate episode list view. */ + t = T(0); + P("track_episodes","update_tracked_episodes",0,t); + ElvUpdate(); + ElvSelectRecent(); + while (GetMessage(&msg, NULL, 0, 0) > 0) { if (IsDialogMessage(hWnd, &msg)) continue; TranslateMessage(&msg); -- cgit v1.2.3