aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--c/main.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/c/main.cpp b/c/main.cpp
index 3cfe2d6..f2172ba 100644
--- a/c/main.cpp
+++ b/c/main.cpp
@@ -23,7 +23,7 @@ int g_bThemes = 0;
int g_bViewTVOriginal = 1;
int g_bViewWatched = 1;
int g_bThread = 0;
-int g_iDPI = -1;
+int g_iDPI = 96;
static int g_cxVScroll;
static LRESULT CALLBACK CBTProc(int, WPARAM, LPARAM);
static LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
@@ -145,8 +145,6 @@ CBTProc(int nCode, WPARAM wParam, LPARAM lParam)
* initializes global variables that are used by WndProc. */
g_hWnd = (HWND)wParam;
- g_lpDlv = new DataListView;
- g_lpElv = new EpisodeListView;
/* Get DPI. */
UINT (*GetDpiForWindow)(HWND);
@@ -154,8 +152,11 @@ CBTProc(int nCode, WPARAM wParam, LPARAM lParam)
if (hModule && (GetDpiForWindow = (UINT (*)(HWND))GetProcAddress(hModule, "GetDpiForWindow"))) {
g_iDPI = GetDpiForWindow(g_hWnd);
FreeLibrary(hModule);
- } else
- g_iDPI = 96;
+ }
+
+ /* Create child windows. */
+ g_lpDlv = new DataListView;
+ g_lpElv = new EpisodeListView;
/* Get saved view settings. */
char *sz;