From 2e8ba48abab7276a23078b28a9120cbb27eda1b9 Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Sun, 2 Aug 2015 11:49:20 +0000 Subject: ListeningTo: common project git-svn-id: http://svn.miranda-ng.org/main/trunk@14815 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/ListeningTo/listeningto.vcxproj | 70 ++++++ plugins/ListeningTo/listeningto.vcxproj.filters | 4 + plugins/ListeningTo/listeningto_10.vcxproj | 239 -------------------- plugins/ListeningTo/listeningto_10.vcxproj.filters | 116 ---------- plugins/ListeningTo/listeningto_12.vcxproj | 242 --------------------- plugins/ListeningTo/listeningto_12.vcxproj.filters | 119 ---------- plugins/ListeningTo/listeningto_14.vcxproj | 242 --------------------- plugins/ListeningTo/listeningto_14.vcxproj.filters | 119 ---------- plugins/ListeningTo/src/commons.h | 118 ---------- plugins/ListeningTo/src/listeningto.cpp | 2 +- plugins/ListeningTo/src/music.cpp | 2 +- plugins/ListeningTo/src/music.h | 2 +- plugins/ListeningTo/src/options.cpp | 2 +- plugins/ListeningTo/src/options.h | 2 +- plugins/ListeningTo/src/players/foobar.cpp | 2 +- plugins/ListeningTo/src/players/generic.cpp | 2 +- plugins/ListeningTo/src/players/itunes.cpp | 2 +- plugins/ListeningTo/src/players/mradio.cpp | 2 +- plugins/ListeningTo/src/players/player.cpp | 2 +- plugins/ListeningTo/src/players/watrack.cpp | 2 +- plugins/ListeningTo/src/players/winamp.cpp | 2 +- plugins/ListeningTo/src/players/wmp.cpp | 2 +- plugins/ListeningTo/src/stdafx.cpp | 18 -- plugins/ListeningTo/src/stdafx.cxx | 18 ++ plugins/ListeningTo/src/stdafx.h | 118 ++++++++++ plugins/WinterSpeak/WinterSpeak.vcxproj | 1 + 26 files changed, 224 insertions(+), 1226 deletions(-) create mode 100644 plugins/ListeningTo/listeningto.vcxproj create mode 100644 plugins/ListeningTo/listeningto.vcxproj.filters delete mode 100644 plugins/ListeningTo/listeningto_10.vcxproj delete mode 100644 plugins/ListeningTo/listeningto_10.vcxproj.filters delete mode 100644 plugins/ListeningTo/listeningto_12.vcxproj delete mode 100644 plugins/ListeningTo/listeningto_12.vcxproj.filters delete mode 100644 plugins/ListeningTo/listeningto_14.vcxproj delete mode 100644 plugins/ListeningTo/listeningto_14.vcxproj.filters delete mode 100644 plugins/ListeningTo/src/commons.h delete mode 100644 plugins/ListeningTo/src/stdafx.cpp create mode 100644 plugins/ListeningTo/src/stdafx.cxx create mode 100644 plugins/ListeningTo/src/stdafx.h (limited to 'plugins') diff --git a/plugins/ListeningTo/listeningto.vcxproj b/plugins/ListeningTo/listeningto.vcxproj new file mode 100644 index 0000000000..177acb87e2 --- /dev/null +++ b/plugins/ListeningTo/listeningto.vcxproj @@ -0,0 +1,70 @@ + + + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + + + {5FAA475D-0593-454F-8601-0D7150DCA4A0} + ListeningTo + + + + + + + + + + + + + + + + + + + + NotUsing + + + ..\stdafx.h + + + ..\stdafx.h + + + ..\stdafx.h + + + ..\stdafx.h + + + ..\stdafx.h + + + ..\stdafx.h + + + ..\stdafx.h + + + ..\stdafx.h + + + \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto.vcxproj.filters b/plugins/ListeningTo/listeningto.vcxproj.filters new file mode 100644 index 0000000000..de5ad9f66c --- /dev/null +++ b/plugins/ListeningTo/listeningto.vcxproj.filters @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto_10.vcxproj b/plugins/ListeningTo/listeningto_10.vcxproj deleted file mode 100644 index 83b0f71a72..0000000000 --- a/plugins/ListeningTo/listeningto_10.vcxproj +++ /dev/null @@ -1,239 +0,0 @@ - - - - - Debug - Win32 - - - Debug - x64 - - - Release - Win32 - - - Release - x64 - - - - {5FAA475D-0593-454F-8601-0D7150DCA4A0} - ListeningTo - - - - DynamicLibrary - Unicode - true - - - DynamicLibrary - Unicode - true - - - DynamicLibrary - Unicode - - - DynamicLibrary - Unicode - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.40219.1 - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - true - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - MultiThreadedDebugDLL - Level3 - EditAndContinue - EnableFastChecks - Use - commons.h - - - _DEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - true - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - Windows - $(ProfileDir)..\..\bin10\lib - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - MultiThreadedDebugDLL - Level3 - EnableFastChecks - Use - commons.h - - - _DEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - true - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - Windows - $(ProfileDir)..\..\bin10\lib - - - - - Full - OnlyExplicitInline - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - true - Level3 - Size - Use - commons.h - - - NDEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - true - true - true - Windows - $(ProfileDir)..\..\bin10\lib - /PDBALTPATH:%_PDB% - - - - - Full - OnlyExplicitInline - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - true - Level3 - Size - Use - commons.h - - - NDEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - true - true - true - Windows - $(ProfileDir)..\..\bin10\lib - /PDBALTPATH:%_PDB% - - - - - - - - - - - - - - - - - - - - - - - - - - - - NotUsing - - - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - Create - - - - - - \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto_10.vcxproj.filters b/plugins/ListeningTo/listeningto_10.vcxproj.filters deleted file mode 100644 index 93ec77c5f0..0000000000 --- a/plugins/ListeningTo/listeningto_10.vcxproj.filters +++ /dev/null @@ -1,116 +0,0 @@ - - - - - {b6bb240e-0f99-4a66-aa07-c073b78bdd2c} - h;hpp;hxx;hm;inl - - - {145ba183-13ea-4c67-8d0d-9114c27c7715} - ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe - - - {df0c152d-8646-4ab0-931c-bca74f7f5dda} - cpp;c;cxx;rc;def;r;odl;idl;hpj;bat - - - {b02fc25f-b248-4ac3-aa31-f386676c62b5} - - - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Header Files - - - - - Resource Files - - - Resource Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Source Files - - - \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto_12.vcxproj b/plugins/ListeningTo/listeningto_12.vcxproj deleted file mode 100644 index 69d7e78f20..0000000000 --- a/plugins/ListeningTo/listeningto_12.vcxproj +++ /dev/null @@ -1,242 +0,0 @@ - - - - - Debug - Win32 - - - Debug - x64 - - - Release - Win32 - - - Release - x64 - - - - {5FAA475D-0593-454F-8601-0D7150DCA4A0} - ListeningTo - - - - DynamicLibrary - Unicode - true - v120_xp - - - DynamicLibrary - Unicode - true - v120_xp - - - DynamicLibrary - Unicode - v120_xp - - - DynamicLibrary - Unicode - v120_xp - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.40219.1 - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - true - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - MultiThreadedDebugDLL - Level3 - EditAndContinue - EnableFastChecks - Use - commons.h - - - _DEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - true - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - Windows - $(ProfileDir)..\..\bin12\lib - false - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - MultiThreadedDebugDLL - Level3 - EnableFastChecks - Use - commons.h - - - _DEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - true - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - Windows - $(ProfileDir)..\..\bin12\lib - - - - - Full - OnlyExplicitInline - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - true - Level3 - Size - Use - commons.h - - - NDEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - true - true - true - Windows - $(ProfileDir)..\..\bin12\lib - - - - - Full - OnlyExplicitInline - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - true - Level3 - Size - Use - commons.h - - - NDEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - true - true - true - Windows - $(ProfileDir)..\..\bin12\lib - - - - - - - - - - - - - - - - - - - - - - - - - - - - NotUsing - - - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - Create - - - - - - \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto_12.vcxproj.filters b/plugins/ListeningTo/listeningto_12.vcxproj.filters deleted file mode 100644 index 95cc67b9fe..0000000000 --- a/plugins/ListeningTo/listeningto_12.vcxproj.filters +++ /dev/null @@ -1,119 +0,0 @@ - - - - - {b6bb240e-0f99-4a66-aa07-c073b78bdd2c} - h;hpp;hxx;hm;inl - - - {145ba183-13ea-4c67-8d0d-9114c27c7715} - ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe - - - {df0c152d-8646-4ab0-931c-bca74f7f5dda} - cpp;c;cxx;rc;def;r;odl;idl;hpj;bat - - - {b02fc25f-b248-4ac3-aa31-f386676c62b5} - - - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Header Files - - - Header Files - - - - - Resource Files - - - Resource Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Source Files - - - \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto_14.vcxproj b/plugins/ListeningTo/listeningto_14.vcxproj deleted file mode 100644 index ff87a25c64..0000000000 --- a/plugins/ListeningTo/listeningto_14.vcxproj +++ /dev/null @@ -1,242 +0,0 @@ - - - - - Debug - Win32 - - - Debug - x64 - - - Release - Win32 - - - Release - x64 - - - - {5FAA475D-0593-454F-8601-0D7150DCA4A0} - ListeningTo - - - - DynamicLibrary - Unicode - true - v140_xp - - - DynamicLibrary - Unicode - true - v140_xp - - - DynamicLibrary - Unicode - v140_xp - - - DynamicLibrary - Unicode - v140_xp - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.40219.1 - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - true - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - MultiThreadedDebugDLL - Level3 - EditAndContinue - EnableFastChecks - Use - commons.h - - - _DEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - true - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - Windows - $(ProfileDir)..\..\bin14\lib - false - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - MultiThreadedDebugDLL - Level3 - EnableFastChecks - Use - commons.h - - - _DEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - true - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - Windows - $(ProfileDir)..\..\bin14\lib - - - - - Full - OnlyExplicitInline - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - true - Level3 - Size - Use - commons.h - - - NDEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - true - true - true - Windows - $(ProfileDir)..\..\bin14\lib - - - - - Full - OnlyExplicitInline - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - true - Level3 - Size - Use - commons.h - - - NDEBUG;%(PreprocessorDefinitions) - ..\..\include\msapi - - - 0x3EC20000 - false - $(IntDir)$(TargetName).lib - true - true - true - Windows - $(ProfileDir)..\..\bin14\lib - - - - - - - - - - - - - - - - - - - - - - - - - - - - NotUsing - - - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - ..\commons.h - - - Create - - - - - - \ No newline at end of file diff --git a/plugins/ListeningTo/listeningto_14.vcxproj.filters b/plugins/ListeningTo/listeningto_14.vcxproj.filters deleted file mode 100644 index 95cc67b9fe..0000000000 --- a/plugins/ListeningTo/listeningto_14.vcxproj.filters +++ /dev/null @@ -1,119 +0,0 @@ - - - - - {b6bb240e-0f99-4a66-aa07-c073b78bdd2c} - h;hpp;hxx;hm;inl - - - {145ba183-13ea-4c67-8d0d-9114c27c7715} - ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe - - - {df0c152d-8646-4ab0-931c-bca74f7f5dda} - cpp;c;cxx;rc;def;r;odl;idl;hpj;bat - - - {b02fc25f-b248-4ac3-aa31-f386676c62b5} - - - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Header Files - - - Header Files - - - - - Resource Files - - - Resource Files - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Players - - - Source Files - - - \ No newline at end of file diff --git a/plugins/ListeningTo/src/commons.h b/plugins/ListeningTo/src/commons.h deleted file mode 100644 index 6f7c04d010..0000000000 --- a/plugins/ListeningTo/src/commons.h +++ /dev/null @@ -1,118 +0,0 @@ -/* -Copyright (C) 2006 Ricardo Pescuma Domenecci - -This is free software; you can redistribute it and/or -modify it under the terms of the GNU Library General Public -License as published by the Free Software Foundation; either -version 2 of the License, or (at your option) any later version. - -This 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 -Library General Public License for more details. - -You should have received a copy of the GNU Library General Public -License along with this file; see the file license.txt. If -not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -Boston, MA 02111-1307, USA. -*/ - - -#ifndef __COMMONS_H__ -# define __COMMONS_H__ - -#define _CRT_SECURE_NO_WARNINGS -#define _CRT_NONSTDC_NO_DEPRECATE - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#include "..\utils\mir_options.h" -#include "..\utils\mir_buffer.h" -#include "..\utils\utf8_helpers.h" - -#include "music.h" -#include "resource.h" -#include "options.h" -#include "Version.h" - -// Prototypes /////////////////////////////////////////////////////////////////////////// - -// Service called by the main menu -#define MS_LISTENINGTO_MAINMENU "ListeningTo/MainMenu" - -// Service called by toptoolbar -#define MS_LISTENINGTO_TTB "ListeningTo/TopToolBar" - -// Services called by hotkeys -#define MS_LISTENINGTO_HOTKEYS_ENABLE "ListeningTo/HotkeysEnable" -#define MS_LISTENINGTO_HOTKEYS_DISABLE "ListeningTo/HotkeysDisable" -#define MS_LISTENINGTO_HOTKEYS_TOGGLE "ListeningTo/HotkeysToggle" - -#define MODULE_NAME "ListeningTo" - - -// Global Variables -extern HINSTANCE hInst; -extern BOOL loaded; - -#define MIR_FREE(_X_) { mir_free(_X_); _X_ = NULL; } - -#define MIN_TIME_BEETWEEN_SETS 10000 // ms - - -void RebuildMenu(); -void StartTimer(); - -struct ProtocolInfo -{ - char proto[128]; - TCHAR account[128]; - HGENMENU hMenu; - int old_xstatus; - TCHAR old_xstatus_name[1024]; - TCHAR old_xstatus_message[1024]; -}; - -ProtocolInfo *GetProtoInfo(char *proto); -int m_log(const TCHAR *function, const TCHAR *fmt, ...); - - -static bool IsEmpty(const char *str) -{ - return str == NULL || str[0] == 0; -} -static bool IsEmpty(const WCHAR *str) -{ - return str == NULL || str[0] == 0; -} - -#define DUP(_X_) ( IsEmpty(_X_) ? NULL : mir_tstrdup(_X_)) -#define DUPD(_X_, _DEF_) ( IsEmpty(_X_) ? mir_tstrdup(_DEF_) : mir_tstrdup(_X_)) -#define U2T(_X_) ( IsEmpty(_X_) ? NULL : mir_u2t(_X_)) -#define U2TD(_X_, _DEF_) ( IsEmpty(_X_) ? mir_u2t(_DEF_) : mir_u2t(_X_)) - - -#endif // __COMMONS_H__ diff --git a/plugins/ListeningTo/src/listeningto.cpp b/plugins/ListeningTo/src/listeningto.cpp index c1472b79cb..6c6007e8fe 100644 --- a/plugins/ListeningTo/src/listeningto.cpp +++ b/plugins/ListeningTo/src/listeningto.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "commons.h" +#include "stdafx.h" CLIST_INTERFACE *pcli; int hLangpack; diff --git a/plugins/ListeningTo/src/music.cpp b/plugins/ListeningTo/src/music.cpp index 2495c09bfd..ca630a8a8c 100644 --- a/plugins/ListeningTo/src/music.cpp +++ b/plugins/ListeningTo/src/music.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "commons.h" +#include "stdafx.h" Player *players[NUM_PLAYERS]; static LISTENINGTOINFO current = {0}; diff --git a/plugins/ListeningTo/src/music.h b/plugins/ListeningTo/src/music.h index ded7c92ea6..2ec93e7f53 100644 --- a/plugins/ListeningTo/src/music.h +++ b/plugins/ListeningTo/src/music.h @@ -22,7 +22,7 @@ Boston, MA 02111-1307, USA. # define __MUSIC_H__ -#include "commons.h" +#include "stdafx.h" // Players diff --git a/plugins/ListeningTo/src/options.cpp b/plugins/ListeningTo/src/options.cpp index 81e1257b20..722300ee90 100644 --- a/plugins/ListeningTo/src/options.cpp +++ b/plugins/ListeningTo/src/options.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "commons.h" +#include "stdafx.h" // Prototypes ///////////////////////////////////////////////////////////////////////////////////// diff --git a/plugins/ListeningTo/src/options.h b/plugins/ListeningTo/src/options.h index 8c14185eb3..0aff9030fd 100644 --- a/plugins/ListeningTo/src/options.h +++ b/plugins/ListeningTo/src/options.h @@ -22,7 +22,7 @@ Boston, MA 02111-1307, USA. # define __OPTIONS_H__ -#include "commons.h" +#include "stdafx.h" #include diff --git a/plugins/ListeningTo/src/players/foobar.cpp b/plugins/ListeningTo/src/players/foobar.cpp index bcb42dbf3f..2b27f8d7a7 100644 --- a/plugins/ListeningTo/src/players/foobar.cpp +++ b/plugins/ListeningTo/src/players/foobar.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" static TCHAR *wcs[] = { _T("{DA7CD0DE-1602-45e6-89A1-C2CA151E008E}/1"), // Foobar 0.9.1 diff --git a/plugins/ListeningTo/src/players/generic.cpp b/plugins/ListeningTo/src/players/generic.cpp index 72ee921605..cc0ecae708 100644 --- a/plugins/ListeningTo/src/players/generic.cpp +++ b/plugins/ListeningTo/src/players/generic.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" static LRESULT CALLBACK ReceiverWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam); diff --git a/plugins/ListeningTo/src/players/itunes.cpp b/plugins/ListeningTo/src/players/itunes.cpp index b0b5fc5e21..af479f22c8 100644 --- a/plugins/ListeningTo/src/players/itunes.cpp +++ b/plugins/ListeningTo/src/players/itunes.cpp @@ -18,7 +18,7 @@ Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" extern "C" { #include "iTunesCOMInterface_i.c" diff --git a/plugins/ListeningTo/src/players/mradio.cpp b/plugins/ListeningTo/src/players/mradio.cpp index c3921dc188..54dd45a8d1 100644 --- a/plugins/ListeningTo/src/players/mradio.cpp +++ b/plugins/ListeningTo/src/players/mradio.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" MRadio::MRadio() { diff --git a/plugins/ListeningTo/src/players/player.cpp b/plugins/ListeningTo/src/players/player.cpp index aea9eed1ba..f87818a90b 100644 --- a/plugins/ListeningTo/src/players/player.cpp +++ b/plugins/ListeningTo/src/players/player.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" extern void HasNewListeningInfo(); diff --git a/plugins/ListeningTo/src/players/watrack.cpp b/plugins/ListeningTo/src/players/watrack.cpp index eab20cf7c5..4af891b39a 100644 --- a/plugins/ListeningTo/src/players/watrack.cpp +++ b/plugins/ListeningTo/src/players/watrack.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" static WATrack *instance = NULL; diff --git a/plugins/ListeningTo/src/players/winamp.cpp b/plugins/ListeningTo/src/players/winamp.cpp index 6ce85ab775..c3e08a02af 100644 --- a/plugins/ListeningTo/src/players/winamp.cpp +++ b/plugins/ListeningTo/src/players/winamp.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" static TCHAR *wcs[] = { _T("Winamp v1.x") diff --git a/plugins/ListeningTo/src/players/wmp.cpp b/plugins/ListeningTo/src/players/wmp.cpp index ad3bf87886..7dc2c6fff0 100644 --- a/plugins/ListeningTo/src/players/wmp.cpp +++ b/plugins/ListeningTo/src/players/wmp.cpp @@ -17,7 +17,7 @@ not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "..\commons.h" +#include "..\stdafx.h" #define WMP_WINDOWCLASS _T("MsnMsgrUIManager") diff --git a/plugins/ListeningTo/src/stdafx.cpp b/plugins/ListeningTo/src/stdafx.cpp deleted file mode 100644 index a1f3bfd522..0000000000 --- a/plugins/ListeningTo/src/stdafx.cpp +++ /dev/null @@ -1,18 +0,0 @@ -/* -Copyright (C) 2012-15 Miranda NG project (http://miranda-ng.org) - -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 version 2 -of the License. - -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. If not, see . -*/ - -#include "commons.h" \ No newline at end of file diff --git a/plugins/ListeningTo/src/stdafx.cxx b/plugins/ListeningTo/src/stdafx.cxx new file mode 100644 index 0000000000..6fb37564b7 --- /dev/null +++ b/plugins/ListeningTo/src/stdafx.cxx @@ -0,0 +1,18 @@ +/* +Copyright (C) 2012-15 Miranda NG project (http://miranda-ng.org) + +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 version 2 +of the License. + +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. If not, see . +*/ + +#include "stdafx.h" \ No newline at end of file diff --git a/plugins/ListeningTo/src/stdafx.h b/plugins/ListeningTo/src/stdafx.h new file mode 100644 index 0000000000..6f7c04d010 --- /dev/null +++ b/plugins/ListeningTo/src/stdafx.h @@ -0,0 +1,118 @@ +/* +Copyright (C) 2006 Ricardo Pescuma Domenecci + +This is free software; you can redistribute it and/or +modify it under the terms of the GNU Library General Public +License as published by the Free Software Foundation; either +version 2 of the License, or (at your option) any later version. + +This 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 +Library General Public License for more details. + +You should have received a copy of the GNU Library General Public +License along with this file; see the file license.txt. If +not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, +Boston, MA 02111-1307, USA. +*/ + + +#ifndef __COMMONS_H__ +# define __COMMONS_H__ + +#define _CRT_SECURE_NO_WARNINGS +#define _CRT_NONSTDC_NO_DEPRECATE + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include "..\utils\mir_options.h" +#include "..\utils\mir_buffer.h" +#include "..\utils\utf8_helpers.h" + +#include "music.h" +#include "resource.h" +#include "options.h" +#include "Version.h" + +// Prototypes /////////////////////////////////////////////////////////////////////////// + +// Service called by the main menu +#define MS_LISTENINGTO_MAINMENU "ListeningTo/MainMenu" + +// Service called by toptoolbar +#define MS_LISTENINGTO_TTB "ListeningTo/TopToolBar" + +// Services called by hotkeys +#define MS_LISTENINGTO_HOTKEYS_ENABLE "ListeningTo/HotkeysEnable" +#define MS_LISTENINGTO_HOTKEYS_DISABLE "ListeningTo/HotkeysDisable" +#define MS_LISTENINGTO_HOTKEYS_TOGGLE "ListeningTo/HotkeysToggle" + +#define MODULE_NAME "ListeningTo" + + +// Global Variables +extern HINSTANCE hInst; +extern BOOL loaded; + +#define MIR_FREE(_X_) { mir_free(_X_); _X_ = NULL; } + +#define MIN_TIME_BEETWEEN_SETS 10000 // ms + + +void RebuildMenu(); +void StartTimer(); + +struct ProtocolInfo +{ + char proto[128]; + TCHAR account[128]; + HGENMENU hMenu; + int old_xstatus; + TCHAR old_xstatus_name[1024]; + TCHAR old_xstatus_message[1024]; +}; + +ProtocolInfo *GetProtoInfo(char *proto); +int m_log(const TCHAR *function, const TCHAR *fmt, ...); + + +static bool IsEmpty(const char *str) +{ + return str == NULL || str[0] == 0; +} +static bool IsEmpty(const WCHAR *str) +{ + return str == NULL || str[0] == 0; +} + +#define DUP(_X_) ( IsEmpty(_X_) ? NULL : mir_tstrdup(_X_)) +#define DUPD(_X_, _DEF_) ( IsEmpty(_X_) ? mir_tstrdup(_DEF_) : mir_tstrdup(_X_)) +#define U2T(_X_) ( IsEmpty(_X_) ? NULL : mir_u2t(_X_)) +#define U2TD(_X_, _DEF_) ( IsEmpty(_X_) ? mir_u2t(_DEF_) : mir_u2t(_X_)) + + +#endif // __COMMONS_H__ diff --git a/plugins/WinterSpeak/WinterSpeak.vcxproj b/plugins/WinterSpeak/WinterSpeak.vcxproj index 7cbbe83c8d..632327d8a1 100644 --- a/plugins/WinterSpeak/WinterSpeak.vcxproj +++ b/plugins/WinterSpeak/WinterSpeak.vcxproj @@ -27,6 +27,7 @@ + spchwrap.lib;%(AdditionalDependencies) src\SAPI 4.0\Lib;$(CommonLibDir) -- cgit v1.2.3