summaryrefslogtreecommitdiff
path: root/plugins/FTPFileYM/src/dialog.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-08-26 18:16:43 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-08-26 18:16:43 +0000
commit404e500ea39d5bd24b46cb214ef731f20c515867 (patch)
tree6f8325d4a6cab6d67f8596a9289ba8b4859538b1 /plugins/FTPFileYM/src/dialog.cpp
parent6a1a045e620dba38a7a64070af59d1a91b104921 (diff)
fix for bug with empty url
git-svn-id: http://svn.miranda-ng.org/main/trunk@15037 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/FTPFileYM/src/dialog.cpp')
-rw-r--r--plugins/FTPFileYM/src/dialog.cpp16
1 files changed, 7 insertions, 9 deletions
diff --git a/plugins/FTPFileYM/src/dialog.cpp b/plugins/FTPFileYM/src/dialog.cpp
index b6004ad18d..6db6412c4a 100644
--- a/plugins/FTPFileYM/src/dialog.cpp
+++ b/plugins/FTPFileYM/src/dialog.cpp
@@ -165,6 +165,8 @@ LRESULT CALLBACK UploadDialog::TabControlProc(HWND hwnd, UINT msg, WPARAM wParam
INT_PTR CALLBACK UploadDialog::UploadDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
+ UploadJob *job;
+
switch (msg) {
case WM_INITDIALOG:
TranslateDialogDefault(hwndDlg);
@@ -247,17 +249,13 @@ INT_PTR CALLBACK UploadDialog::UploadDlgProc(HWND hwndDlg, UINT msg, WPARAM wPar
return TRUE;
case IDC_BTN_CLIPBOARD:
- {
- UploadJob *job = (UploadJob *)uDlg->m_tabs[uDlg->m_activeTab]->m_job;
- Utils::copyToClipboard(job->m_szFileLink);
- }
+ job = (UploadJob*)uDlg->m_tabs[uDlg->m_activeTab]->m_job;
+ Utils::copyToClipboard(job->m_szFileLink);
return TRUE;
case IDC_BTN_DOWNLOAD:
- {
- UploadJob *job = (UploadJob *)uDlg->m_tabs[uDlg->m_activeTab]->m_job;
- ShellExecuteA(NULL, "open", job->m_szFileLink, NULL, NULL, SW_SHOWNORMAL);
- }
+ job = (UploadJob*)uDlg->m_tabs[uDlg->m_activeTab]->m_job;
+ ShellExecuteA(NULL, "open", job->m_szFileLink, NULL, NULL, SW_SHOWNORMAL);
return TRUE;
case IDC_BTN_FILEMANAGER:
@@ -351,8 +349,8 @@ INT_PTR CALLBACK UploadDialog::UploadDlgProc(HWND hwndDlg, UINT msg, WPARAM wPar
return TRUE;
}
}
- break;
}
+ break;
case WM_NOTIFY:
switch (((LPNMHDR)lParam)->code) {