From 70d04c9b21955c34070ee466693403e2b00870e1 Mon Sep 17 00:00:00 2001 From: Vadim Dashevskiy Date: Wed, 18 Jul 2012 07:52:13 +0000 Subject: FirstRun, FlashAvatars, FloatingContacts: changed folder structure git-svn-id: http://svn.miranda-ng.org/main/trunk@1008 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/FirstRun/FirstRun.vcxproj | 5 +-- plugins/FirstRun/FirstRun.vcxproj.filters | 8 +--- plugins/FirstRun/commonheaders.h | 11 ----- plugins/FirstRun/docs/firstrun-translation.txt | 2 + plugins/FirstRun/firstrun-translation.txt | 2 - plugins/FirstRun/main.cpp | 62 -------------------------- plugins/FirstRun/src/commonheaders.h | 11 +++++ plugins/FirstRun/src/main.cpp | 62 ++++++++++++++++++++++++++ 8 files changed, 79 insertions(+), 84 deletions(-) delete mode 100644 plugins/FirstRun/commonheaders.h create mode 100644 plugins/FirstRun/docs/firstrun-translation.txt delete mode 100644 plugins/FirstRun/firstrun-translation.txt delete mode 100644 plugins/FirstRun/main.cpp create mode 100644 plugins/FirstRun/src/commonheaders.h create mode 100644 plugins/FirstRun/src/main.cpp (limited to 'plugins/FirstRun') diff --git a/plugins/FirstRun/FirstRun.vcxproj b/plugins/FirstRun/FirstRun.vcxproj index 99d7f94327..e262c4a4f0 100644 --- a/plugins/FirstRun/FirstRun.vcxproj +++ b/plugins/FirstRun/FirstRun.vcxproj @@ -135,7 +135,6 @@ ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) WIN64;_DEBUG;_WINDOWS;_USRDLL;FIRSTRUN_EXPORTS;%(PreprocessorDefinitions) EnableFastChecks - MultiThreadedDebugDLL Level3 @@ -147,10 +146,10 @@ - + - + diff --git a/plugins/FirstRun/FirstRun.vcxproj.filters b/plugins/FirstRun/FirstRun.vcxproj.filters index 782e0f59ee..84d31bcfc1 100644 --- a/plugins/FirstRun/FirstRun.vcxproj.filters +++ b/plugins/FirstRun/FirstRun.vcxproj.filters @@ -9,18 +9,14 @@ {196047f9-ebe5-4820-92f6-8142fff77f44} h;hpp;hxx;hm;inl - - {9633b99b-6e98-48bf-a30e-fb695b840910} - ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe - - + Source Files - + Header Files diff --git a/plugins/FirstRun/commonheaders.h b/plugins/FirstRun/commonheaders.h deleted file mode 100644 index 1839f53fc1..0000000000 --- a/plugins/FirstRun/commonheaders.h +++ /dev/null @@ -1,11 +0,0 @@ -#define MIRANDA_VER 0x0A00 -#define _CRT_SECURE_NO_WARNINGS - -#include -#include -#include -#include -#include -#include - -#define MIID_FIRSTRUN {0x49c2cf54, 0x7898, 0x44de, { 0xbe, 0x3a, 0x6d, 0x2e, 0x4e, 0xf9, 0x0, 0x79 }} //{49c2cf54-7898-44de-be3a-6d2e4ef90079} \ No newline at end of file diff --git a/plugins/FirstRun/docs/firstrun-translation.txt b/plugins/FirstRun/docs/firstrun-translation.txt new file mode 100644 index 0000000000..52329c17db --- /dev/null +++ b/plugins/FirstRun/docs/firstrun-translation.txt @@ -0,0 +1,2 @@ +; Common strings that belong to many files +;[] diff --git a/plugins/FirstRun/firstrun-translation.txt b/plugins/FirstRun/firstrun-translation.txt deleted file mode 100644 index 52329c17db..0000000000 --- a/plugins/FirstRun/firstrun-translation.txt +++ /dev/null @@ -1,2 +0,0 @@ -; Common strings that belong to many files -;[] diff --git a/plugins/FirstRun/main.cpp b/plugins/FirstRun/main.cpp deleted file mode 100644 index cbe3b18f9d..0000000000 --- a/plugins/FirstRun/main.cpp +++ /dev/null @@ -1,62 +0,0 @@ -#include "commonheaders.h" - -HINSTANCE hInst; - -HANDLE hModulesLoaded; -int hLangpack; - -PLUGININFOEX pluginInfo={ - sizeof(PLUGININFOEX), - "First Run Plugin", - PLUGIN_MAKE_VERSION(0,0,0,2), - "Displays the Accounts window at the first start.", - "Yasnovidyashii", - "yasnovidyashii@gmail.com", - "© 2008 Mikhail Yuriev", - "http://miranda-im.org/", - UNICODE_AWARE, - MIID_FIRSTRUN -}; - -int ModulesLoaded(WPARAM wParam,LPARAM lParam) -{ - TCHAR* ptszDllName; - TCHAR ptszDllPath[MAX_PATH]; - - GetModuleFileName(hInst, ptszDllPath, MAX_PATH); - ptszDllName = _tcslwr(_tcsrchr(ptszDllPath, '\\')); - - if (ptszDllName!=NULL) - ptszDllName=ptszDllName + 1; - - CallService(MS_PROTO_SHOWACCMGR, (WPARAM) NULL, (LPARAM)NULL); - - DBWriteContactSettingByte(NULL, "PluginDisable", _T2A(ptszDllName), 1); - - return 0; -} - -BOOL WINAPI DllMain(HINSTANCE hinstDLL,DWORD fdwReason,LPVOID lpvReserved) -{ - hInst=hinstDLL; - return TRUE; -} - -extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD mirandaVersion) -{ - return &pluginInfo; -} - -extern "C" __declspec(dllexport) int Load(void) -{ - - mir_getLP(&pluginInfo); - hModulesLoaded = HookEvent(ME_SYSTEM_MODULESLOADED,ModulesLoaded); - return 0; -} - -extern "C" __declspec(dllexport) int Unload(void) -{ - UnhookEvent(hModulesLoaded); - return 0; -} \ No newline at end of file diff --git a/plugins/FirstRun/src/commonheaders.h b/plugins/FirstRun/src/commonheaders.h new file mode 100644 index 0000000000..1839f53fc1 --- /dev/null +++ b/plugins/FirstRun/src/commonheaders.h @@ -0,0 +1,11 @@ +#define MIRANDA_VER 0x0A00 +#define _CRT_SECURE_NO_WARNINGS + +#include +#include +#include +#include +#include +#include + +#define MIID_FIRSTRUN {0x49c2cf54, 0x7898, 0x44de, { 0xbe, 0x3a, 0x6d, 0x2e, 0x4e, 0xf9, 0x0, 0x79 }} //{49c2cf54-7898-44de-be3a-6d2e4ef90079} \ No newline at end of file diff --git a/plugins/FirstRun/src/main.cpp b/plugins/FirstRun/src/main.cpp new file mode 100644 index 0000000000..cbe3b18f9d --- /dev/null +++ b/plugins/FirstRun/src/main.cpp @@ -0,0 +1,62 @@ +#include "commonheaders.h" + +HINSTANCE hInst; + +HANDLE hModulesLoaded; +int hLangpack; + +PLUGININFOEX pluginInfo={ + sizeof(PLUGININFOEX), + "First Run Plugin", + PLUGIN_MAKE_VERSION(0,0,0,2), + "Displays the Accounts window at the first start.", + "Yasnovidyashii", + "yasnovidyashii@gmail.com", + "© 2008 Mikhail Yuriev", + "http://miranda-im.org/", + UNICODE_AWARE, + MIID_FIRSTRUN +}; + +int ModulesLoaded(WPARAM wParam,LPARAM lParam) +{ + TCHAR* ptszDllName; + TCHAR ptszDllPath[MAX_PATH]; + + GetModuleFileName(hInst, ptszDllPath, MAX_PATH); + ptszDllName = _tcslwr(_tcsrchr(ptszDllPath, '\\')); + + if (ptszDllName!=NULL) + ptszDllName=ptszDllName + 1; + + CallService(MS_PROTO_SHOWACCMGR, (WPARAM) NULL, (LPARAM)NULL); + + DBWriteContactSettingByte(NULL, "PluginDisable", _T2A(ptszDllName), 1); + + return 0; +} + +BOOL WINAPI DllMain(HINSTANCE hinstDLL,DWORD fdwReason,LPVOID lpvReserved) +{ + hInst=hinstDLL; + return TRUE; +} + +extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD mirandaVersion) +{ + return &pluginInfo; +} + +extern "C" __declspec(dllexport) int Load(void) +{ + + mir_getLP(&pluginInfo); + hModulesLoaded = HookEvent(ME_SYSTEM_MODULESLOADED,ModulesLoaded); + return 0; +} + +extern "C" __declspec(dllexport) int Unload(void) +{ + UnhookEvent(hModulesLoaded); + return 0; +} \ No newline at end of file -- cgit v1.2.3