summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/SendScreenshotPlus/src/UMainForm.cpp4
-rw-r--r--protocols/CloudFile/src/services.cpp2
2 files changed, 4 insertions, 2 deletions
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);
}
diff --git a/protocols/CloudFile/src/services.cpp b/protocols/CloudFile/src/services.cpp
index e0a01fbfba..f568f2f68c 100644
--- a/protocols/CloudFile/src/services.cpp
+++ b/protocols/CloudFile/src/services.cpp
@@ -67,7 +67,7 @@ INT_PTR Upload(WPARAM wParam, LPARAM lParam)
if (accountName == nullptr)
return 2;
- CCloudService *service = FindService(uploadData->accountName);
+ CCloudService *service = FindService(accountName);
if (service == nullptr)
return 3;