summaryrefslogtreecommitdiff
path: root/src/mir_app
diff options
context:
space:
mode:
Diffstat (limited to 'src/mir_app')
-rw-r--r--src/mir_app/src/FontOptions.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mir_app/src/FontOptions.cpp b/src/mir_app/src/FontOptions.cpp
index e87ea4cd11..7847d3d92a 100644
--- a/src/mir_app/src/FontOptions.cpp
+++ b/src/mir_app/src/FontOptions.cpp
@@ -236,8 +236,8 @@ static BOOL ExportSettings(HWND hwndDlg, const wchar_t *filename, OBJLIST<FontIn
SIZE size;
GetTextExtentPoint32(hdc, L"_W", 2, &size);
- ReleaseDC(hwndDlg, hdc);
SelectObject(hdc, hOldFont);
+ ReleaseDC(hwndDlg, hdc);
DeleteObject(hFont);
iFontSize = size.cy;
@@ -577,8 +577,8 @@ static void sttSaveFontData(HWND hwndDlg, FontInternal &F)
HDC hdc = GetDC(hwndDlg);
HFONT hOldFont = (HFONT)SelectObject(hdc, hFont);
GetTextExtentPoint32(hdc, L"_W", 2, &size);
- ReleaseDC(hwndDlg, hdc);
SelectObject(hdc, hOldFont);
+ ReleaseDC(hwndDlg, hdc);
DeleteObject(hFont);
db_set_b(0, F.dbSettingsGroup, str, (char)size.cy);