summaryrefslogtreecommitdiff
path: root/plugins/LangMan/utils.cpp
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2012-07-20 10:47:53 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2012-07-20 10:47:53 +0000
commitd0de809a2d4f2ac76025d861bf55aa2c4ba1ac07 (patch)
tree3ccf0ebf548cfe6e69bbbd04329ef19192e30f33 /plugins/LangMan/utils.cpp
parent6e7980b0ad162bbb526b3d52acbc1639c2b11760 (diff)
LangMan: changed folder structure
git-svn-id: http://svn.miranda-ng.org/main/trunk@1072 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/LangMan/utils.cpp')
-rw-r--r--plugins/LangMan/utils.cpp67
1 files changed, 0 insertions, 67 deletions
diff --git a/plugins/LangMan/utils.cpp b/plugins/LangMan/utils.cpp
deleted file mode 100644
index c67b9813a8..0000000000
--- a/plugins/LangMan/utils.cpp
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
-
-'Language Pack Manager'-Plugin for Miranda IM
-
-Copyright (C) 2005-2007 H. Herkenrath
-
-This program is free software; you can redistribute it and/or
-modify it under the terms of the GNU General Public License
-as published by the Free Software Foundation; either version 2
-of the License, or (at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program (LangMan-License.txt); if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-*/
-
-#include "common.h"
-
-/************************* Error Output ***************************/
-
-static void MessageBoxIndirectFree(MSGBOXPARAMSA *mbp)
-{
- MessageBoxIndirectA(mbp);
- mir_free((char*)mbp->lpszCaption); /* does NULL check */
- mir_free((char*)mbp->lpszText); /* does NULL check */
- mir_free(mbp);
-}
-
-void ShowInfoMessage(BYTE flags, const char *pszTitle, const char *pszTextFmt, ...)
-{
- va_list va;
- va_start(va, pszTextFmt);
- char szText[256]; /* max for systray */
- mir_vsnprintf(szText, SIZEOF(szText), pszTextFmt, va);
- va_end(va);
-
- if (ServiceExists(MS_CLIST_SYSTRAY_NOTIFY)) {
- MIRANDASYSTRAYNOTIFY msn;
- msn.cbSize = sizeof(msn);
- msn.szProto = NULL;
- msn.szInfoTitle = (char*)pszTitle;
- msn.szInfo = (char*)szText;
- msn.uTimeout = 30000; /* max timeout */
- msn.dwInfoFlags = flags;
- if (!CallServiceSync(MS_CLIST_SYSTRAY_NOTIFY, 0, (LPARAM)&msn))
- return; /* success */
- }
-
- MSGBOXPARAMSA *mbp = (MSGBOXPARAMSA*)mir_calloc(sizeof(*mbp));
- if (mbp == NULL) return;
- mbp->cbSize = sizeof(*mbp);
- mbp->lpszCaption = mir_strdup(pszTitle);
- mbp->lpszText = mir_strdup(szText);
- mbp->dwStyle = MB_OK|MB_SETFOREGROUND|MB_TASKMODAL;
- mbp->dwLanguageId = LANGIDFROMLCID((LCID)CallService(MS_LANGPACK_GETLOCALE, 0, 0));
- switch(flags&NIIF_ICON_MASK) {
- case NIIF_INFO: mbp->dwStyle |= MB_ICONINFORMATION; break;
- case NIIF_WARNING: mbp->dwStyle |= MB_ICONWARNING; break;
- case NIIF_ERROR: mbp->dwStyle |= MB_ICONERROR;
- }
- mir_forkthread(( pThreadFunc )MessageBoxIndirectFree, mbp);
-}