summaryrefslogtreecommitdiff
path: root/src/mir_app
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2022-09-26 18:23:52 +0300
committerGeorge Hazan <ghazan@miranda.im>2022-09-26 18:23:52 +0300
commit30a9e9e370aa9aff9f64158aa0942b471621a7ef (patch)
tree013f47dfcc748e7a816eb3b59a9ee852d34de0ad /src/mir_app
parentcb0412427ffb4819f2026906f259f4a2dd3ef177 (diff)
Utils_ClipboardCopy - system-wide helper for writing text to clipboard
Diffstat (limited to 'src/mir_app')
-rw-r--r--src/mir_app/src/srmm_log_rtf.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/src/mir_app/src/srmm_log_rtf.cpp b/src/mir_app/src/srmm_log_rtf.cpp
index b0ed13d3b7..01d8b7c5c8 100644
--- a/src/mir_app/src/srmm_log_rtf.cpp
+++ b/src/mir_app/src/srmm_log_rtf.cpp
@@ -168,14 +168,7 @@ INT_PTR CRtfLogWindow::Notify(WPARAM, LPARAM lParam)
break;
case IDM_COPYLINK:
- if (OpenClipboard(m_pDlg.m_hwnd)) {
- EmptyClipboard();
- HGLOBAL hData = GlobalAlloc(GMEM_MOVEABLE, (wszText.GetLength() + 1) * sizeof(wchar_t));
- mir_wstrcpy((wchar_t *)GlobalLock(hData), wszText);
- GlobalUnlock(hData);
- SetClipboardData(CF_UNICODETEXT, hData);
- CloseClipboard();
- }
+ Utils_ClipboardCopy(wszText);
break;
}