From 38418bfefb15124e9f40a8b4c47e12ac7a1680a4 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 23 Apr 2020 21:24:41 +0300 Subject: minor code cleaning --- plugins/NewStory/src/calendartool.cpp | 3 ++- plugins/NewStory/src/history.cpp | 7 ++----- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'plugins') diff --git a/plugins/NewStory/src/calendartool.cpp b/plugins/NewStory/src/calendartool.cpp index 8ce42ce529..46155c6220 100644 --- a/plugins/NewStory/src/calendartool.cpp +++ b/plugins/NewStory/src/calendartool.cpp @@ -52,6 +52,7 @@ INT_PTR CALLBACK CalendarToolDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM time_t CalendarTool_Show(HWND hwnd, int x, int y) { - CreateDialogParam(g_plugin.getInst(), MAKEINTRESOURCE(IDD_CALENDARTOOL), hwnd, CalendarToolDlgProc, MAKELONG(x, y)); + HWND hwndCalendar = CreateDialogParam(g_plugin.getInst(), MAKEINTRESOURCE(IDD_CALENDARTOOL), hwnd, CalendarToolDlgProc, MAKELONG(x, y)); + ShowWindow(hwndCalendar, SW_SHOW); return 0; } diff --git a/plugins/NewStory/src/history.cpp b/plugins/NewStory/src/history.cpp index b94fad88da..548c387501 100644 --- a/plugins/NewStory/src/history.cpp +++ b/plugins/NewStory/src/history.cpp @@ -831,11 +831,8 @@ public: // break; case WM_USER + 0x600: - { - time_t tm_jump = (time_t)wParam; - if (tm_jump) - m_histControl.SendMsg(NSM_SEEKTIME, tm_jump, 0); - } + if (wParam) + m_histControl.SendMsg(NSM_SEEKTIME, wParam, 0); } return CDlgBase::DlgProc(msg, wParam, lParam); -- cgit v1.2.3