diff options
Diffstat (limited to 'lib')
12 files changed, 1258 insertions, 0 deletions
diff --git a/lib/addons/library.xbmc.addon/Makefile.in b/lib/addons/library.xbmc.addon/Makefile.in new file mode 100644 index 0000000000..cd8b00991b --- /dev/null +++ b/lib/addons/library.xbmc.addon/Makefile.in @@ -0,0 +1,27 @@ +ARCH=@ARCH@ +INCLUDES=-I. -I../../../xbmc/addons/include -I../../../xbmc +DEFINES+= +CXXFLAGS=-fPIC +LIBNAME=libXBMC_addon +OBJS=$(LIBNAME).o + +LIB_SHARED=../../../addons/library.xbmc.addon/$(LIBNAME)-$(ARCH).so + +all: $(LIB_SHARED) + +$(LIB_SHARED): $(OBJS) +ifeq ($(findstring osx,$(ARCH)), osx) + $(CXX) $(LDFLAGS) -Wl,-alias_list,@abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper_mach_alias \ + -bundle -undefined dynamic_lookup -read_only_relocs suppress -o $@ \ + @abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper.o $(OBJS) +else + $(CXX) $(CFLAGS) $(LDFLAGS) -shared -g -o $(LIB_SHARED) $(OBJS) +endif + +CLEAN_FILES = \ + $(LIBNAME).so \ + +DISTCLEAN_FILES= \ + Makefile \ + +include ../../../Makefile.include diff --git a/lib/addons/library.xbmc.addon/libXBMC_addon.cpp b/lib/addons/library.xbmc.addon/libXBMC_addon.cpp new file mode 100644 index 0000000000..8d8f026a95 --- /dev/null +++ b/lib/addons/library.xbmc.addon/libXBMC_addon.cpp @@ -0,0 +1,128 @@ +/* + * Copyright (C) 2012 Team XBMC + * http://www.xbmc.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; either version 2, 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 XBMC; see the file COPYING. If not, write to + * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + * http://www.gnu.org/copyleft/gpl.html + * + */ + +#include <stdio.h> +#include <stdlib.h> +#include <stdarg.h> +#include <string> +#include "../../../addons/library.xbmc.addon/libXBMC_addon.h" +#include "../../../xbmc/addons/AddonCallbacks.h" + +#ifdef _WIN32 +#include <windows.h> +#define DLLEXPORT __declspec(dllexport) +#else +#define DLLEXPORT +#endif + + +using namespace std; +using namespace ADDON; + +AddonCB *m_Handle = NULL; +CB_AddOnLib *m_cb = NULL; + +extern "C" +{ + +DLLEXPORT int XBMC_register_me(void *hdl) +{ + if (!hdl) + fprintf(stderr, "libXBMC_addon-ERROR: XBMC_register_me is called with NULL handle !!!\n"); + else + { + m_Handle = (AddonCB*) hdl; + m_cb = m_Handle->AddOnLib_RegisterMe(m_Handle->addonData); + if (!m_cb) + fprintf(stderr, "libXBMC_addon-ERROR: XBMC_register_me can't get callback table from XBMC !!!\n"); + else + return 1; + } + return 0; +} + +DLLEXPORT void XBMC_unregister_me() +{ + if (m_Handle && m_cb) + m_Handle->AddOnLib_UnRegisterMe(m_Handle->addonData, m_cb); +} + +DLLEXPORT void XBMC_log(const addon_log_t loglevel, const char *format, ... ) +{ + if (m_cb == NULL) + return; + + char buffer[16384]; + va_list args; + va_start (args, format); + vsprintf (buffer, format, args); + va_end (args); + m_cb->Log(m_Handle->addonData, loglevel, buffer); +} + +DLLEXPORT bool XBMC_get_setting(const char* settingName, void *settingValue) +{ + if (m_cb == NULL) + return false; + + return m_cb->GetSetting(m_Handle->addonData, settingName, settingValue); +} + +DLLEXPORT void XBMC_queue_notification(const queue_msg_t type, const char *format, ... ) +{ + if (m_cb == NULL) + return; + + char buffer[16384]; + va_list args; + va_start (args, format); + vsprintf (buffer, format, args); + va_end (args); + m_cb->QueueNotification(m_Handle->addonData, type, buffer); +} + +DLLEXPORT void XBMC_unknown_to_utf8(string &str) +{ + if (m_cb == NULL) + return; + + string buffer = m_cb->UnknownToUTF8(str.c_str()); + str = buffer; +} + +DLLEXPORT const char* XBMC_get_localized_string(int dwCode) +{ + if (m_cb == NULL) + return ""; + + return m_cb->GetLocalizedString(m_Handle->addonData, dwCode); +} + +DLLEXPORT const char* XBMC_get_dvd_menu_language() +{ + if (m_cb == NULL) + return ""; + + string buffer = m_cb->GetDVDMenuLanguage(m_Handle->addonData); + return buffer.c_str(); +} + +}; diff --git a/lib/addons/library.xbmc.addon/project/VS2010Express/libXBMC_addon.vcxproj b/lib/addons/library.xbmc.addon/project/VS2010Express/libXBMC_addon.vcxproj new file mode 100644 index 0000000000..af5c26fc7a --- /dev/null +++ b/lib/addons/library.xbmc.addon/project/VS2010Express/libXBMC_addon.vcxproj @@ -0,0 +1,88 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup Label="ProjectConfigurations"> + <ProjectConfiguration Include="Debug|Win32"> + <Configuration>Debug</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Release|Win32"> + <Configuration>Release</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + </ItemGroup> + <PropertyGroup Label="Globals"> + <ProjectGuid>{2DCEA60B-4EBC-4DB7-9FBD-297C1EFD95D7}</ProjectGuid> + <RootNamespace>XBMC_VDR</RootNamespace> + <Keyword>Win32Proj</Keyword> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> + <ImportGroup Label="ExtensionSettings"> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" /> + </ImportGroup> + <PropertyGroup Label="UserMacros" /> + <PropertyGroup> + <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\..\..\..\addons\library.xbmc.addon\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Debug\</IntDir> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\..\..\..\addons\library.xbmc.addon\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Release\</IntDir> + </PropertyGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ClCompile> + <Optimization>Disabled</Optimization> + <AdditionalIncludeDirectories>..\..\..\..\..\xbmc\addons\include;..\..\..\..\..\xbmc\addons;..\..\..\..\..\xbmc\cores\dvdplayer\DVDDemuxers;..\..\..\..\..\xbmc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions>_WIN32;_DEBUG;_WINDOWS;VDR_EXPORTS;_WIN32PC;_WINSOCKAPI_;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <MinimalRebuild>true</MinimalRebuild> + <ExceptionHandling>Sync</ExceptionHandling> + <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks> + <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> + </ClCompile> + <Link> + <OutputFile>..\..\..\..\..\addons\library.xbmc.addon\$(ProjectName).dll</OutputFile> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ClCompile> + <AdditionalIncludeDirectories>..\..\..\..\..\xbmc\addons\include;..\..\..\..\..\xbmc\addons;..\..\..\..\..\xbmc\cores\dvdplayer\DVDDemuxers;..\..\..\..\..\xbmc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;HAS_SDL_OPENGL;HAS_SDL;_USRDLL;XBMC_VDR_EXPORTS;_WIN32PC;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <ExceptionHandling>Sync</ExceptionHandling> + <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> + </ClCompile> + <Link> + <OutputFile>..\..\..\..\..\addons\library.xbmc.addon\$(ProjectName).dll</OutputFile> + </Link> + </ItemDefinitionGroup> + <ItemGroup> + <ClCompile Include="..\..\libXBMC_addon.cpp" /> + </ItemGroup> + <ItemGroup> + <ClInclude Include="..\..\..\..\..\addons\library.xbmc.addon\libXBMC_addon.h" /> + </ItemGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> + <ImportGroup Label="ExtensionTargets"> + </ImportGroup> +</Project>
\ No newline at end of file diff --git a/lib/addons/library.xbmc.addon/project/VS2010Express/libXBMC_addon.vcxproj.filters b/lib/addons/library.xbmc.addon/project/VS2010Express/libXBMC_addon.vcxproj.filters new file mode 100644 index 0000000000..916673ca41 --- /dev/null +++ b/lib/addons/library.xbmc.addon/project/VS2010Express/libXBMC_addon.vcxproj.filters @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup> + <Filter Include="Source Files"> + <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier> + <Extensions>cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions> + </Filter> + </ItemGroup> + <ItemGroup> + <ClCompile Include="..\..\libXBMC_addon.cpp"> + <Filter>Source Files</Filter> + </ClCompile> + </ItemGroup> + <ItemGroup> + <ClInclude Include="..\..\..\..\..\addons\library.xbmc.addon\libXBMC_addon.h"> + <Filter>Source Files</Filter> + </ClInclude> + </ItemGroup> +</Project>
\ No newline at end of file diff --git a/lib/addons/library.xbmc.gui/Makefile.in b/lib/addons/library.xbmc.gui/Makefile.in new file mode 100644 index 0000000000..b5df484c2d --- /dev/null +++ b/lib/addons/library.xbmc.gui/Makefile.in @@ -0,0 +1,27 @@ +ARCH=@ARCH@ +INCLUDES=-I. -I../../../xbmc/addons/include -I../../../xbmc -I../../../xbmc/cores/dvdplayer/DVDDemuxers +DEFINES+= +CXXFLAGS=-fPIC +LIBNAME=libXBMC_gui +OBJS=$(LIBNAME).o + +LIB_SHARED=../../../addons/library.xbmc.gui/$(LIBNAME)-$(ARCH).so + +all: $(LIB_SHARED) + +$(LIB_SHARED): $(OBJS) +ifeq ($(findstring osx,$(ARCH)), osx) + $(CXX) $(LDFLAGS) -Wl,-alias_list,@abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper_mach_alias \ + -bundle -undefined dynamic_lookup -read_only_relocs suppress -o $@ \ + @abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper.o $(OBJS) +else + $(CXX) $(CFLAGS) $(LDFLAGS) -shared -g -o $(LIB_SHARED) $(OBJS) +endif + +CLEAN_FILES = \ + $(LIB_SHARED) \ + +DISTCLEAN_FILES= \ + Makefile \ + +include ../../../Makefile.include diff --git a/lib/addons/library.xbmc.gui/libXBMC_gui.cpp b/lib/addons/library.xbmc.gui/libXBMC_gui.cpp new file mode 100644 index 0000000000..752c2483cb --- /dev/null +++ b/lib/addons/library.xbmc.gui/libXBMC_gui.cpp @@ -0,0 +1,555 @@ +/* + * Copyright (C) 2012 Team XBMC + * http://www.xbmc.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; either version 2, 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 XBMC; see the file COPYING. If not, write to + * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + * http://www.gnu.org/copyleft/gpl.html + * + */ + +#include <stdio.h> +#include <stdlib.h> +#include <stdarg.h> +#include <string> +#include "../../../addons/library.xbmc.gui/libXBMC_gui.h" +#include "addons/AddonCallbacks.h" + +#ifdef _WIN32 +#include <windows.h> +#define DLLEXPORT __declspec(dllexport) +#else +#define DLLEXPORT +#endif + +using namespace std; + +AddonCB *m_Handle = NULL; +CB_GUILib *m_cb = NULL; + +extern "C" +{ + +DLLEXPORT int GUI_register_me(void *hdl) +{ + if (!hdl) + fprintf(stderr, "libXBMC_gui-ERROR: GUILib_register_me is called with NULL handle !!!\n"); + else + { + m_Handle = (AddonCB*) hdl; + m_cb = m_Handle->GUILib_RegisterMe(m_Handle->addonData); + if (!m_cb) + fprintf(stderr, "libXBMC_gui-ERROR: GUILib_register_me can't get callback table from XBMC !!!\n"); + else + return 1; + } + return 0; +} + +DLLEXPORT void GUI_unregister_me() +{ + if (m_Handle && m_cb) + m_Handle->GUILib_UnRegisterMe(m_Handle->addonData, m_cb); +} + +DLLEXPORT void GUI_lock() +{ + m_cb->Lock(); +} + +DLLEXPORT void GUI_unlock() +{ + m_cb->Unlock(); +} + +DLLEXPORT int GUI_get_screen_height() +{ + return m_cb->GetScreenHeight(); +} + +DLLEXPORT int GUI_get_screen_width() +{ + return m_cb->GetScreenWidth(); +} + +DLLEXPORT int GUI_get_video_resolution() +{ + return m_cb->GetVideoResolution(); +} + +DLLEXPORT CAddonGUIWindow* GUI_Window_create(const char *xmlFilename, const char *defaultSkin, bool forceFallback, bool asDialog) +{ + return new CAddonGUIWindow(xmlFilename, defaultSkin, forceFallback, asDialog); +} + +DLLEXPORT void GUI_Window_destroy(CAddonGUIWindow* p) +{ + delete p; +} + +DLLEXPORT bool GUI_Window_OnClick(GUIHANDLE handle, int controlId) +{ + CAddonGUIWindow *window = (CAddonGUIWindow*) handle; + return window->OnClick(controlId); +} + +DLLEXPORT bool GUI_Window_OnFocus(GUIHANDLE handle, int controlId) +{ + CAddonGUIWindow *window = (CAddonGUIWindow*) handle; + return window->OnFocus(controlId); +} + +DLLEXPORT bool GUI_Window_OnInit(GUIHANDLE handle) +{ + CAddonGUIWindow *window = (CAddonGUIWindow*) handle; + return window->OnInit(); +} + +DLLEXPORT bool GUI_Window_OnAction(GUIHANDLE handle, int actionId) +{ + CAddonGUIWindow *window = (CAddonGUIWindow*) handle; + return window->OnAction(actionId); +} + + +CAddonGUIWindow::CAddonGUIWindow(const char *xmlFilename, const char *defaultSkin, bool forceFallback, bool asDialog) +{ + CBOnInit = NULL; + CBOnClick = NULL; + CBOnFocus = NULL; + if (m_Handle && m_cb) + { + m_WindowHandle = m_cb->Window_New(m_Handle->addonData, xmlFilename, defaultSkin, forceFallback, asDialog); + if (!m_WindowHandle) + fprintf(stderr, "libXBMC_gui-ERROR: cGUIWindow can't create window class from XBMC !!!\n"); + + m_cb->Window_SetCallbacks(m_Handle->addonData, m_WindowHandle, this, GUI_Window_OnInit, GUI_Window_OnClick, GUI_Window_OnFocus, GUI_Window_OnAction); + } +} + +CAddonGUIWindow::~CAddonGUIWindow() +{ + if (m_Handle && m_cb && m_WindowHandle) + { + m_cb->Window_Delete(m_Handle->addonData, m_WindowHandle); + m_WindowHandle = NULL; + } +} + +bool CAddonGUIWindow::Show() +{ + return m_cb->Window_Show(m_Handle->addonData, m_WindowHandle); +} + +void CAddonGUIWindow::Close() +{ + m_cb->Window_Close(m_Handle->addonData, m_WindowHandle); +} + +void CAddonGUIWindow::DoModal() +{ + m_cb->Window_DoModal(m_Handle->addonData, m_WindowHandle); +} + +bool CAddonGUIWindow::OnInit() +{ + if (!CBOnInit) + return false; + + return CBOnInit(m_cbhdl); +} + +bool CAddonGUIWindow::OnClick(int controlId) +{ + if (!CBOnClick) + return false; + + return CBOnClick(m_cbhdl, controlId); +} + +bool CAddonGUIWindow::OnFocus(int controlId) +{ + if (!CBOnFocus) + return false; + + return CBOnFocus(m_cbhdl, controlId); +} + +bool CAddonGUIWindow::OnAction(int actionId) +{ + if (!CBOnAction) + return false; + + return CBOnAction(m_cbhdl, actionId); +} + +bool CAddonGUIWindow::SetFocusId(int iControlId) +{ + return m_cb->Window_SetFocusId(m_Handle->addonData, m_WindowHandle, iControlId); +} + +int CAddonGUIWindow::GetFocusId() +{ + return m_cb->Window_GetFocusId(m_Handle->addonData, m_WindowHandle); +} + +bool CAddonGUIWindow::SetCoordinateResolution(int res) +{ + return m_cb->Window_SetCoordinateResolution(m_Handle->addonData, m_WindowHandle, res); +} + +void CAddonGUIWindow::SetProperty(const char *key, const char *value) +{ + m_cb->Window_SetProperty(m_Handle->addonData, m_WindowHandle, key, value); +} + +void CAddonGUIWindow::SetPropertyInt(const char *key, int value) +{ + m_cb->Window_SetPropertyInt(m_Handle->addonData, m_WindowHandle, key, value); +} + +void CAddonGUIWindow::SetPropertyBool(const char *key, bool value) +{ + m_cb->Window_SetPropertyBool(m_Handle->addonData, m_WindowHandle, key, value); +} + +void CAddonGUIWindow::SetPropertyDouble(const char *key, double value) +{ + m_cb->Window_SetPropertyDouble(m_Handle->addonData, m_WindowHandle, key, value); +} + +const char *CAddonGUIWindow::GetProperty(const char *key) const +{ + return m_cb->Window_GetProperty(m_Handle->addonData, m_WindowHandle, key); +} + +int CAddonGUIWindow::GetPropertyInt(const char *key) const +{ + return m_cb->Window_GetPropertyInt(m_Handle->addonData, m_WindowHandle, key); +} + +bool CAddonGUIWindow::GetPropertyBool(const char *key) const +{ + return m_cb->Window_GetPropertyBool(m_Handle->addonData, m_WindowHandle, key); +} + +double CAddonGUIWindow::GetPropertyDouble(const char *key) const +{ + return m_cb->Window_GetPropertyDouble(m_Handle->addonData, m_WindowHandle, key); +} + +void CAddonGUIWindow::ClearProperties() +{ + m_cb->Window_ClearProperties(m_Handle->addonData, m_WindowHandle); +} + +int CAddonGUIWindow::GetListSize() +{ + return m_cb->Window_GetListSize(m_Handle->addonData, m_WindowHandle); +} + +void CAddonGUIWindow::ClearList() +{ + m_cb->Window_ClearList(m_Handle->addonData, m_WindowHandle); +} + +GUIHANDLE CAddonGUIWindow::AddStringItem(const char *name, int itemPosition) +{ + return m_cb->Window_AddStringItem(m_Handle->addonData, m_WindowHandle, name, itemPosition); +} + +void CAddonGUIWindow::AddItem(GUIHANDLE item, int itemPosition) +{ + m_cb->Window_AddItem(m_Handle->addonData, m_WindowHandle, item, itemPosition); +} + +void CAddonGUIWindow::AddItem(CAddonListItem *item, int itemPosition) +{ + m_cb->Window_AddItem(m_Handle->addonData, m_WindowHandle, item->m_ListItemHandle, itemPosition); +} + +void CAddonGUIWindow::RemoveItem(int itemPosition) +{ + m_cb->Window_RemoveItem(m_Handle->addonData, m_WindowHandle, itemPosition); +} + +GUIHANDLE CAddonGUIWindow::GetListItem(int listPos) +{ + return m_cb->Window_GetListItem(m_Handle->addonData, m_WindowHandle, listPos); +} + +void CAddonGUIWindow::SetCurrentListPosition(int listPos) +{ + m_cb->Window_SetCurrentListPosition(m_Handle->addonData, m_WindowHandle, listPos); +} + +int CAddonGUIWindow::GetCurrentListPosition() +{ + return m_cb->Window_GetCurrentListPosition(m_Handle->addonData, m_WindowHandle); +} + +void CAddonGUIWindow::SetControlLabel(int controlId, const char *label) +{ + m_cb->Window_SetControlLabel(m_Handle->addonData, m_WindowHandle, controlId, label); +} + +///------------------------------------- +/// cGUISpinControl + +DLLEXPORT CAddonGUISpinControl* GUI_control_get_spin(CAddonGUIWindow *window, int controlId) +{ + return new CAddonGUISpinControl(window, controlId); +} + +DLLEXPORT void GUI_control_release_spin(CAddonGUISpinControl* p) +{ + delete p; +} + +CAddonGUISpinControl::CAddonGUISpinControl(CAddonGUIWindow *window, int controlId) + : m_Window(window) + , m_ControlId(controlId) +{ + m_SpinHandle = m_cb->Window_GetControl_Spin(m_Handle->addonData, m_Window->m_WindowHandle, controlId); +} + +void CAddonGUISpinControl::SetVisible(bool yesNo) +{ + if (m_SpinHandle) + m_cb->Control_Spin_SetVisible(m_Handle->addonData, m_SpinHandle, yesNo); +} + +void CAddonGUISpinControl::SetText(const char *label) +{ + if (m_SpinHandle) + m_cb->Control_Spin_SetText(m_Handle->addonData, m_SpinHandle, label); +} + +void CAddonGUISpinControl::Clear() +{ + if (m_SpinHandle) + m_cb->Control_Spin_Clear(m_Handle->addonData, m_SpinHandle); +} + +void CAddonGUISpinControl::AddLabel(const char *label, int iValue) +{ + if (m_SpinHandle) + m_cb->Control_Spin_AddLabel(m_Handle->addonData, m_SpinHandle, label, iValue); +} + +int CAddonGUISpinControl::GetValue() +{ + if (!m_SpinHandle) + return -1; + + return m_cb->Control_Spin_GetValue(m_Handle->addonData, m_SpinHandle); +} + +void CAddonGUISpinControl::SetValue(int iValue) +{ + if (m_SpinHandle) + m_cb->Control_Spin_SetValue(m_Handle->addonData, m_SpinHandle, iValue); +} + +///------------------------------------- +/// cGUIRadioButton + +DLLEXPORT CAddonGUIRadioButton* GUI_control_get_radiobutton(CAddonGUIWindow *window, int controlId) +{ + return new CAddonGUIRadioButton(window, controlId); +} + +DLLEXPORT void GUI_control_release_radiobutton(CAddonGUIRadioButton* p) +{ + delete p; +} + +CAddonGUIRadioButton::CAddonGUIRadioButton(CAddonGUIWindow *window, int controlId) + : m_Window(window) + , m_ControlId(controlId) +{ + m_ButtonHandle = m_cb->Window_GetControl_RadioButton(m_Handle->addonData, m_Window->m_WindowHandle, controlId); +} + +void CAddonGUIRadioButton::SetVisible(bool yesNo) +{ + if (m_ButtonHandle) + m_cb->Control_RadioButton_SetVisible(m_Handle->addonData, m_ButtonHandle, yesNo); +} + +void CAddonGUIRadioButton::SetText(const char *label) +{ + if (m_ButtonHandle) + m_cb->Control_RadioButton_SetText(m_Handle->addonData, m_ButtonHandle, label); +} + +void CAddonGUIRadioButton::SetSelected(bool yesNo) +{ + if (m_ButtonHandle) + m_cb->Control_RadioButton_SetSelected(m_Handle->addonData, m_ButtonHandle, yesNo); +} + +bool CAddonGUIRadioButton::IsSelected() +{ + if (!m_ButtonHandle) + return false; + + return m_cb->Control_RadioButton_IsSelected(m_Handle->addonData, m_ButtonHandle); +} + + +///------------------------------------- +/// cGUIProgressControl + +DLLEXPORT CAddonGUIProgressControl* GUI_control_get_progress(CAddonGUIWindow *window, int controlId) +{ + return new CAddonGUIProgressControl(window, controlId); +} + +DLLEXPORT void GUI_control_release_progress(CAddonGUIProgressControl* p) +{ + delete p; +} + +CAddonGUIProgressControl::CAddonGUIProgressControl(CAddonGUIWindow *window, int controlId) + : m_Window(window) + , m_ControlId(controlId) +{ + m_ProgressHandle = m_cb->Window_GetControl_Progress(m_Handle->addonData, m_Window->m_WindowHandle, controlId); +} + +void CAddonGUIProgressControl::SetPercentage(float fPercent) +{ + if (m_ProgressHandle) + m_cb->Control_Progress_SetPercentage(m_Handle->addonData, m_ProgressHandle, fPercent); +} + +float CAddonGUIProgressControl::GetPercentage() const +{ + if (!m_ProgressHandle) + return 0.0; + + return m_cb->Control_Progress_GetPercentage(m_Handle->addonData, m_ProgressHandle); +} + +void CAddonGUIProgressControl::SetInfo(int iInfo) +{ + if (m_ProgressHandle) + m_cb->Control_Progress_SetInfo(m_Handle->addonData, m_ProgressHandle, iInfo); +} + +int CAddonGUIProgressControl::GetInfo() const +{ + if (!m_ProgressHandle) + return -1; + + return m_cb->Control_Progress_GetInfo(m_Handle->addonData, m_ProgressHandle); +} + +string CAddonGUIProgressControl::GetDescription() const +{ + if (!m_ProgressHandle) + return ""; + + return m_cb->Control_Progress_GetDescription(m_Handle->addonData, m_ProgressHandle); +} + + +///------------------------------------- +/// cListItem + +DLLEXPORT CAddonListItem* GUI_ListItem_create(const char *label, const char *label2, const char *iconImage, const char *thumbnailImage, const char *path) +{ + return new CAddonListItem(label, label2, iconImage, thumbnailImage, path); +} + +DLLEXPORT void GUI_ListItem_destroy(CAddonListItem* p) +{ + delete p; +} + + +CAddonListItem::CAddonListItem(const char *label, const char *label2, const char *iconImage, const char *thumbnailImage, const char *path) +{ + m_ListItemHandle = m_cb->ListItem_Create(m_Handle->addonData, label, label2, iconImage, thumbnailImage, path); +} + +const char *CAddonListItem::GetLabel() +{ + if (!m_ListItemHandle) + return ""; + + return m_cb->ListItem_GetLabel(m_Handle->addonData, m_ListItemHandle); +} + +void CAddonListItem::SetLabel(const char *label) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetLabel(m_Handle->addonData, m_ListItemHandle, label); +} + +const char *CAddonListItem::GetLabel2() +{ + if (!m_ListItemHandle) + return ""; + + return m_cb->ListItem_GetLabel2(m_Handle->addonData, m_ListItemHandle); +} + +void CAddonListItem::SetLabel2(const char *label) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetLabel2(m_Handle->addonData, m_ListItemHandle, label); +} + +void CAddonListItem::SetIconImage(const char *image) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetIconImage(m_Handle->addonData, m_ListItemHandle, image); +} + +void CAddonListItem::SetThumbnailImage(const char *image) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetThumbnailImage(m_Handle->addonData, m_ListItemHandle, image); +} + +void CAddonListItem::SetInfo(const char *Info) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetInfo(m_Handle->addonData, m_ListItemHandle, Info); +} + +void CAddonListItem::SetProperty(const char *key, const char *value) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetProperty(m_Handle->addonData, m_ListItemHandle, key, value); +} + +const char *CAddonListItem::GetProperty(const char *key) const +{ + if (!m_ListItemHandle) + return ""; + + return m_cb->ListItem_GetProperty(m_Handle->addonData, m_ListItemHandle, key); +} + +void CAddonListItem::SetPath(const char *Path) +{ + if (m_ListItemHandle) + m_cb->ListItem_SetPath(m_Handle->addonData, m_ListItemHandle, Path); +} + + +}; diff --git a/lib/addons/library.xbmc.gui/project/VS2010Express/libXBMC_gui.vcxproj b/lib/addons/library.xbmc.gui/project/VS2010Express/libXBMC_gui.vcxproj new file mode 100644 index 0000000000..1a09551b92 --- /dev/null +++ b/lib/addons/library.xbmc.gui/project/VS2010Express/libXBMC_gui.vcxproj @@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup Label="ProjectConfigurations"> + <ProjectConfiguration Include="Debug|Win32"> + <Configuration>Debug</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Release|Win32"> + <Configuration>Release</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + </ItemGroup> + <PropertyGroup Label="Globals"> + <ProjectGuid>{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}</ProjectGuid> + <RootNamespace>XBMC_VDR</RootNamespace> + <Keyword>Win32Proj</Keyword> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> + <ImportGroup Label="ExtensionSettings"> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" /> + </ImportGroup> + <PropertyGroup Label="UserMacros" /> + <PropertyGroup> + <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\..\..\..\addons\library.xbmc.gui\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Debug\</IntDir> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\..\..\..\addons\library.xbmc.gui\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Release\</IntDir> + </PropertyGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ClCompile> + <Optimization>Disabled</Optimization> + <AdditionalIncludeDirectories>..\..\..\..\..\xbmc;..\..\..\..\..\xbmc\addons\include;..\..\..\..\..\xbmc\cores\dvdplayer\DVDDemuxers;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions>_WIN32;_DEBUG;_WINDOWS;VDR_EXPORTS;_WIN32PC;_WINSOCKAPI_;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <MinimalRebuild>true</MinimalRebuild> + <ExceptionHandling>Sync</ExceptionHandling> + <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks> + <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> + </ClCompile> + <Link> + <OutputFile>..\..\..\..\..\addons\library.xbmc.gui\$(ProjectName).dll</OutputFile> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ClCompile> + <AdditionalIncludeDirectories>..\..\..\..\..\xbmc;..\..\..\..\..\xbmc\addons\include;..\..\..\..\..\xbmc\cores\dvdplayer\DVDDemuxers;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;HAS_SDL_OPENGL;HAS_SDL;_USRDLL;XBMC_VDR_EXPORTS;_WIN32PC;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <ExceptionHandling>Sync</ExceptionHandling> + <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> + </ClCompile> + <Link> + <OutputFile>../../../../../addons/library.xbmc.gui/$(ProjectName).dll</OutputFile> + </Link> + </ItemDefinitionGroup> + <ItemGroup> + <ClCompile Include="..\..\libXBMC_gui.cpp" /> + </ItemGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> + <ImportGroup Label="ExtensionTargets"> + </ImportGroup> +</Project>
\ No newline at end of file diff --git a/lib/addons/library.xbmc.gui/project/VS2010Express/libXBMC_gui.vcxproj.filters b/lib/addons/library.xbmc.gui/project/VS2010Express/libXBMC_gui.vcxproj.filters new file mode 100644 index 0000000000..166719621f --- /dev/null +++ b/lib/addons/library.xbmc.gui/project/VS2010Express/libXBMC_gui.vcxproj.filters @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup> + <Filter Include="Source Files"> + <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier> + <Extensions>cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions> + </Filter> + <Filter Include="Header Files"> + <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier> + <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions> + </Filter> + </ItemGroup> + <ItemGroup> + <ClCompile Include="..\..\libXBMC_gui.cpp"> + <Filter>Source Files</Filter> + </ClCompile> + </ItemGroup> +</Project>
\ No newline at end of file diff --git a/lib/addons/library.xbmc.pvr/Makefile.in b/lib/addons/library.xbmc.pvr/Makefile.in new file mode 100644 index 0000000000..1edf41120a --- /dev/null +++ b/lib/addons/library.xbmc.pvr/Makefile.in @@ -0,0 +1,27 @@ +ARCH=@ARCH@ +INCLUDES=-I. -I../../../xbmc/addons/include -I../../../xbmc -I../../../xbmc/cores/dvdplayer/DVDDemuxers +DEFINES+= +CXXFLAGS=-fPIC +LIBNAME=libXBMC_pvr +OBJS=$(LIBNAME).o + +LIB_SHARED=../../../addons/library.xbmc.pvr/$(LIBNAME)-$(ARCH).so + +all: $(LIB_SHARED) + +$(LIB_SHARED): $(OBJS) +ifeq ($(findstring osx,$(ARCH)), osx) + $(CXX) $(LDFLAGS) -Wl,-alias_list,@abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper_mach_alias \ + -bundle -undefined dynamic_lookup -read_only_relocs suppress -o $@ \ + @abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper.o $(OBJS) +else + $(CXX) $(CFLAGS) $(LDFLAGS) -shared -g -o $(LIB_SHARED) $(OBJS) +endif + +CLEAN_FILES = \ + $(LIB_SHARED) \ + +DISTCLEAN_FILES= \ + Makefile \ + +include ../../../Makefile.include diff --git a/lib/addons/library.xbmc.pvr/libXBMC_pvr.cpp b/lib/addons/library.xbmc.pvr/libXBMC_pvr.cpp new file mode 100644 index 0000000000..8ef4b595f3 --- /dev/null +++ b/lib/addons/library.xbmc.pvr/libXBMC_pvr.cpp @@ -0,0 +1,181 @@ +/* + * Copyright (C) 2012 Team XBMC + * http://www.xbmc.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; either version 2, 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 XBMC; see the file COPYING. If not, write to + * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + * http://www.gnu.org/copyleft/gpl.html + * + */ + +#define USE_DEMUX // enable including of the demuxer packet structure + +#include <stdio.h> +#include <stdlib.h> +#include <stdarg.h> +#include <string> +#include "../../../addons/library.xbmc.pvr/libXBMC_pvr.h" +#include "addons/AddonCallbacks.h" +#include "cores/dvdplayer/DVDDemuxers/DVDDemuxPacket.h" + +#ifdef _WIN32 +#include <windows.h> +#define DLLEXPORT __declspec(dllexport) +#else +#define DLLEXPORT +#endif + +using namespace std; + +AddonCB *m_Handle = NULL; +CB_PVRLib *m_cb = NULL; + +extern "C" +{ + +DLLEXPORT int PVR_register_me(void *hdl) +{ + if (!hdl) + fprintf(stderr, "libXBMC_pvr-ERROR: PVRLib_register_me is called with NULL handle !!!\n"); + else + { + m_Handle = (AddonCB*) hdl; + m_cb = m_Handle->PVRLib_RegisterMe(m_Handle->addonData); + if (!m_cb) + fprintf(stderr, "libXBMC_pvr-ERROR: PVRLib_register_me can't get callback table from XBMC !!!\n"); + else + return 1; + } + return 0; +} + +DLLEXPORT void PVR_unregister_me() +{ + if (m_Handle && m_cb) + m_Handle->PVRLib_UnRegisterMe(m_Handle->addonData, m_cb); +} + +DLLEXPORT void PVR_transfer_epg_entry(const ADDON_HANDLE handle, const EPG_TAG *epgentry) +{ + if (m_cb == NULL) + return; + + m_cb->TransferEpgEntry(m_Handle->addonData, handle, epgentry); +} + +DLLEXPORT void PVR_transfer_channel_entry(const ADDON_HANDLE handle, const PVR_CHANNEL *chan) +{ + if (m_cb == NULL) + return; + + m_cb->TransferChannelEntry(m_Handle->addonData, handle, chan); +} + +DLLEXPORT void PVR_transfer_timer_entry(const ADDON_HANDLE handle, const PVR_TIMER *timer) +{ + if (m_cb == NULL) + return; + + m_cb->TransferTimerEntry(m_Handle->addonData, handle, timer); +} + +DLLEXPORT void PVR_transfer_recording_entry(const ADDON_HANDLE handle, const PVR_RECORDING *recording) +{ + if (m_cb == NULL) + return; + + m_cb->TransferRecordingEntry(m_Handle->addonData, handle, recording); +} + +DLLEXPORT void PVR_add_menu_hook(PVR_MENUHOOK *hook) +{ + if (m_cb == NULL) + return; + + m_cb->AddMenuHook(m_Handle->addonData, hook); +} + +DLLEXPORT void PVR_recording(const char *Name, const char *FileName, bool On) +{ + if (m_cb == NULL) + return; + + m_cb->Recording(m_Handle->addonData, Name, FileName, On); +} + +DLLEXPORT void PVR_trigger_channel_update() +{ + if (m_cb == NULL) + return; + + m_cb->TriggerChannelUpdate(m_Handle->addonData); +} + +DLLEXPORT void PVR_trigger_channel_groups_update() +{ + if (m_cb == NULL) + return; + + m_cb->TriggerChannelGroupsUpdate(m_Handle->addonData); +} + +DLLEXPORT void PVR_trigger_timer_update() +{ + if (m_cb == NULL) + return; + + m_cb->TriggerTimerUpdate(m_Handle->addonData); +} + +DLLEXPORT void PVR_trigger_recording_update() +{ + if (m_cb == NULL) + return; + + m_cb->TriggerRecordingUpdate(m_Handle->addonData); +} + +DLLEXPORT void PVR_free_demux_packet(DemuxPacket* pPacket) +{ + if (m_cb == NULL) + return; + + m_cb->FreeDemuxPacket(m_Handle->addonData, pPacket); +} + +DLLEXPORT DemuxPacket* PVR_allocate_demux_packet(int iDataSize) +{ + if (m_cb == NULL) + return NULL; + + return m_cb->AllocateDemuxPacket(m_Handle->addonData, iDataSize); +} + +DLLEXPORT void PVR_transfer_channel_group(const ADDON_HANDLE handle, const PVR_CHANNEL_GROUP *group) +{ + if (m_cb == NULL) + return; + + m_cb->TransferChannelGroup(m_Handle->addonData, handle, group); +} + +DLLEXPORT void PVR_transfer_channel_group_member(const ADDON_HANDLE handle, const PVR_CHANNEL_GROUP_MEMBER *member) +{ + if (m_cb == NULL) + return; + + m_cb->TransferChannelGroupMember(m_Handle->addonData, handle, member); +} + +}; diff --git a/lib/addons/library.xbmc.pvr/project/VS2010Express/libXBMC_pvr.vcxproj b/lib/addons/library.xbmc.pvr/project/VS2010Express/libXBMC_pvr.vcxproj new file mode 100644 index 0000000000..3e386a06e4 --- /dev/null +++ b/lib/addons/library.xbmc.pvr/project/VS2010Express/libXBMC_pvr.vcxproj @@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup Label="ProjectConfigurations"> + <ProjectConfiguration Include="Debug|Win32"> + <Configuration>Debug</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Release|Win32"> + <Configuration>Release</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + </ItemGroup> + <PropertyGroup Label="Globals"> + <ProjectGuid>{6D8C91F8-992F-4C83-9DE3-485D64EF8420}</ProjectGuid> + <RootNamespace>XBMC_VDR</RootNamespace> + <Keyword>Win32Proj</Keyword> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> + <ImportGroup Label="ExtensionSettings"> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" /> + </ImportGroup> + <PropertyGroup Label="UserMacros" /> + <PropertyGroup> + <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\..\..\..\addons\library.xbmc.pvr\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Debug\</IntDir> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\..\..\..\addons\library.xbmc.pvr\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Release\</IntDir> + </PropertyGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ClCompile> + <Optimization>Disabled</Optimization> + <AdditionalIncludeDirectories>..\..\..\..\..\xbmc;..\..\..\..\..\xbmc\addons\include;..\..\..\..\..\xbmc\cores\dvdplayer\DVDDemuxers;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions>_WIN32;_DEBUG;_WINDOWS;VDR_EXPORTS;_WIN32PC;_WINSOCKAPI_;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <MinimalRebuild>true</MinimalRebuild> + <ExceptionHandling>Sync</ExceptionHandling> + <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks> + <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> + </ClCompile> + <Link> + <OutputFile>..\..\..\..\..\addons\library.xbmc.pvr\$(ProjectName).dll</OutputFile> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ClCompile> + <AdditionalIncludeDirectories>..\..\..\..\..\xbmc;..\..\..\..\..\xbmc\addons\include;..\..\..\..\..\xbmc\cores\dvdplayer\DVDDemuxers;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;HAS_SDL_OPENGL;HAS_SDL;_USRDLL;XBMC_VDR_EXPORTS;_WIN32PC;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <ExceptionHandling>Sync</ExceptionHandling> + <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> + </ClCompile> + <Link> + <OutputFile>..\..\..\..\..\addons\library.xbmc.pvr\$(ProjectName).dll</OutputFile> + </Link> + </ItemDefinitionGroup> + <ItemGroup> + <ClCompile Include="..\..\libXBMC_pvr.cpp" /> + </ItemGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> + <ImportGroup Label="ExtensionTargets"> + </ImportGroup> +</Project>
\ No newline at end of file diff --git a/lib/addons/library.xbmc.pvr/project/VS2010Express/libXBMC_pvr.vcxproj.filters b/lib/addons/library.xbmc.pvr/project/VS2010Express/libXBMC_pvr.vcxproj.filters new file mode 100644 index 0000000000..db93c59c90 --- /dev/null +++ b/lib/addons/library.xbmc.pvr/project/VS2010Express/libXBMC_pvr.vcxproj.filters @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup> + <Filter Include="Source Files"> + <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier> + <Extensions>cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions> + </Filter> + <Filter Include="Header Files"> + <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier> + <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions> + </Filter> + </ItemGroup> + <ItemGroup> + <ClCompile Include="..\..\libXBMC_pvr.cpp"> + <Filter>Source Files</Filter> + </ClCompile> + </ItemGroup> +</Project>
\ No newline at end of file |