From bd9554ed8e8ba1e4be8d0ba5a0600cacbf95a950 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 22 Mar 2020 15:23:41 +0300 Subject: SendScreenShot: - fixes #2272 (main dialog doesn't restore cloud service correctly); - CloudService doesn't apply default settings correctly --- plugins/SendScreenshotPlus/src/UMainForm.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'plugins/SendScreenshotPlus') diff --git a/plugins/SendScreenshotPlus/src/UMainForm.cpp b/plugins/SendScreenshotPlus/src/UMainForm.cpp index 9db52a35ef..04b274cce2 100644 --- a/plugins/SendScreenshotPlus/src/UMainForm.cpp +++ b/plugins/SendScreenshotPlus/src/UMainForm.cpp @@ -300,6 +300,7 @@ void TfrmMain::wmInitdialog(WPARAM, LPARAM) } // init SendBy combo box + UPLOAD_INFO *pDefault = nullptr; { hCtrl = GetDlgItem(m_hWnd, ID_cboxSendBy); ComboBox_ResetContent(hCtrl); @@ -338,6 +339,7 @@ void TfrmMain::wmInitdialog(WPARAM, LPARAM) for (int i = 0; i < ComboBox_GetCount(hCtrl); i++) { UPLOAD_INFO *p = (UPLOAD_INFO*)ComboBox_GetItemData(hCtrl, i); if (p && p->sendBy == m_opt_cboxSendBy) { + pDefault = p; ComboBox_SetCurSel(hCtrl, i); break; } @@ -385,7 +387,7 @@ void TfrmMain::wmInitdialog(WPARAM, LPARAM) SetWindowText(hCtrl, TranslateT("&Capture")); SendMessage(hCtrl, BUTTONSETDEFAULT, 1, NULL); } - cboxSendByChange(nullptr); // enable disable controls + cboxSendByChange((pDefault) ? pDefault->param : nullptr); // enable disable controls TranslateDialogDefault(m_hWnd); } -- cgit v1.2.3