Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

changed: remove old virtualpath code

this was replaced by multipaths back in 2006 or thereabout
  • Loading branch information...
commit 18ef66b75b4d467dc4caa99592d0d5b19ed1f61c 1 parent 0653ebd
spiff authored
6 XBMC-ATV2.xcodeproj/project.pbxproj
@@ -376,7 +376,6 @@
376 376 F56C79E8131EC154000AD0F6 /* QueryParams.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C748E131EC152000AD0F6 /* QueryParams.cpp */; };
377 377 F56C79E9131EC154000AD0F6 /* VideoDatabaseDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C7490131EC152000AD0F6 /* VideoDatabaseDirectory.cpp */; };
378 378 F56C79EA131EC154000AD0F6 /* VirtualDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C7492131EC152000AD0F6 /* VirtualDirectory.cpp */; };
379   - F56C79EB131EC154000AD0F6 /* VirtualPathDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C7494131EC152000AD0F6 /* VirtualPathDirectory.cpp */; };
380 379 F56C79ED131EC154000AD0F6 /* ZeroconfDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C7499131EC152000AD0F6 /* ZeroconfDirectory.cpp */; };
381 380 F56C79EE131EC154000AD0F6 /* ZipDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C749B131EC152000AD0F6 /* ZipDirectory.cpp */; };
382 381 F56C79EF131EC154000AD0F6 /* ZipManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C749D131EC152000AD0F6 /* ZipManager.cpp */; };
@@ -1769,8 +1768,6 @@
1769 1768 F56C7491131EC152000AD0F6 /* VideoDatabaseDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VideoDatabaseDirectory.h; sourceTree = "<group>"; };
1770 1769 F56C7492131EC152000AD0F6 /* VirtualDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VirtualDirectory.cpp; sourceTree = "<group>"; };
1771 1770 F56C7493131EC152000AD0F6 /* VirtualDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VirtualDirectory.h; sourceTree = "<group>"; };
1772   - F56C7494131EC152000AD0F6 /* VirtualPathDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VirtualPathDirectory.cpp; sourceTree = "<group>"; };
1773   - F56C7495131EC152000AD0F6 /* VirtualPathDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VirtualPathDirectory.h; sourceTree = "<group>"; };
1774 1771 F56C7498131EC152000AD0F6 /* ZeroconfDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ZeroconfDirectory.h; sourceTree = "<group>"; };
1775 1772 F56C7499131EC152000AD0F6 /* ZeroconfDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ZeroconfDirectory.cpp; sourceTree = "<group>"; };
1776 1773 F56C749A131EC152000AD0F6 /* zconf.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = zconf.h; sourceTree = "<group>"; };
@@ -4127,8 +4124,6 @@
4127 4124 F56C7491131EC152000AD0F6 /* VideoDatabaseDirectory.h */,
4128 4125 F56C7492131EC152000AD0F6 /* VirtualDirectory.cpp */,
4129 4126 F56C7493131EC152000AD0F6 /* VirtualDirectory.h */,
4130   - F56C7494131EC152000AD0F6 /* VirtualPathDirectory.cpp */,
4131   - F56C7495131EC152000AD0F6 /* VirtualPathDirectory.h */,
4132 4127 F56C7498131EC152000AD0F6 /* ZeroconfDirectory.h */,
4133 4128 F56C7499131EC152000AD0F6 /* ZeroconfDirectory.cpp */,
4134 4129 F56C749A131EC152000AD0F6 /* zconf.h */,
@@ -6233,7 +6228,6 @@
6233 6228 F56C79E8131EC154000AD0F6 /* QueryParams.cpp in Sources */,
6234 6229 F56C79E9131EC154000AD0F6 /* VideoDatabaseDirectory.cpp in Sources */,
6235 6230 F56C79EA131EC154000AD0F6 /* VirtualDirectory.cpp in Sources */,
6236   - F56C79EB131EC154000AD0F6 /* VirtualPathDirectory.cpp in Sources */,
6237 6231 F56C79ED131EC154000AD0F6 /* ZeroconfDirectory.cpp in Sources */,
6238 6232 F56C79EE131EC154000AD0F6 /* ZipDirectory.cpp in Sources */,
6239 6233 F56C79EF131EC154000AD0F6 /* ZipManager.cpp in Sources */,
6 XBMC-IOS.xcodeproj/project.pbxproj
@@ -467,7 +467,6 @@
467 467 F56C89D2131F42ED000AD0F6 /* QueryParams.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C8471131F42E8000AD0F6 /* QueryParams.cpp */; };
468 468 F56C89D3131F42ED000AD0F6 /* VideoDatabaseDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C8473131F42E8000AD0F6 /* VideoDatabaseDirectory.cpp */; };
469 469 F56C89D4131F42ED000AD0F6 /* VirtualDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C8475131F42E8000AD0F6 /* VirtualDirectory.cpp */; };
470   - F56C89D5131F42ED000AD0F6 /* VirtualPathDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C8477131F42E8000AD0F6 /* VirtualPathDirectory.cpp */; };
471 470 F56C89D7131F42ED000AD0F6 /* ZeroconfDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C847C131F42E9000AD0F6 /* ZeroconfDirectory.cpp */; };
472 471 F56C89D8131F42ED000AD0F6 /* ZipDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C847E131F42E9000AD0F6 /* ZipDirectory.cpp */; };
473 472 F56C89D9131F42ED000AD0F6 /* ZipManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F56C8480131F42E9000AD0F6 /* ZipManager.cpp */; };
@@ -1967,8 +1966,6 @@
1967 1966 F56C8474131F42E8000AD0F6 /* VideoDatabaseDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VideoDatabaseDirectory.h; sourceTree = "<group>"; };
1968 1967 F56C8475131F42E8000AD0F6 /* VirtualDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VirtualDirectory.cpp; sourceTree = "<group>"; };
1969 1968 F56C8476131F42E8000AD0F6 /* VirtualDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VirtualDirectory.h; sourceTree = "<group>"; };
1970   - F56C8477131F42E8000AD0F6 /* VirtualPathDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VirtualPathDirectory.cpp; sourceTree = "<group>"; };
1971   - F56C8478131F42E8000AD0F6 /* VirtualPathDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VirtualPathDirectory.h; sourceTree = "<group>"; };
1972 1969 F56C847B131F42E9000AD0F6 /* ZeroconfDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ZeroconfDirectory.h; sourceTree = "<group>"; };
1973 1970 F56C847C131F42E9000AD0F6 /* ZeroconfDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ZeroconfDirectory.cpp; sourceTree = "<group>"; };
1974 1971 F56C847D131F42E9000AD0F6 /* zconf.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = zconf.h; sourceTree = "<group>"; };
@@ -4486,8 +4483,6 @@
4486 4483 F56C8474131F42E8000AD0F6 /* VideoDatabaseDirectory.h */,
4487 4484 F56C8475131F42E8000AD0F6 /* VirtualDirectory.cpp */,
4488 4485 F56C8476131F42E8000AD0F6 /* VirtualDirectory.h */,
4489   - F56C8477131F42E8000AD0F6 /* VirtualPathDirectory.cpp */,
4490   - F56C8478131F42E8000AD0F6 /* VirtualPathDirectory.h */,
4491 4486 F56C847B131F42E9000AD0F6 /* ZeroconfDirectory.h */,
4492 4487 F56C847C131F42E9000AD0F6 /* ZeroconfDirectory.cpp */,
4493 4488 F56C847D131F42E9000AD0F6 /* zconf.h */,
@@ -6340,7 +6335,6 @@
6340 6335 F56C89D2131F42ED000AD0F6 /* QueryParams.cpp in Sources */,
6341 6336 F56C89D3131F42ED000AD0F6 /* VideoDatabaseDirectory.cpp in Sources */,
6342 6337 F56C89D4131F42ED000AD0F6 /* VirtualDirectory.cpp in Sources */,
6343   - F56C89D5131F42ED000AD0F6 /* VirtualPathDirectory.cpp in Sources */,
6344 6338 F56C89D7131F42ED000AD0F6 /* ZeroconfDirectory.cpp in Sources */,
6345 6339 F56C89D8131F42ED000AD0F6 /* ZipDirectory.cpp in Sources */,
6346 6340 F56C89D9131F42ED000AD0F6 /* ZipManager.cpp in Sources */,
8 XBMC.xcodeproj/project.pbxproj
@@ -797,7 +797,6 @@
797 797 E38E20720D25F9FD00618676 /* QueryParams.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E17880D25F9FA00618676 /* QueryParams.cpp */; };
798 798 E38E20730D25F9FD00618676 /* VideoDatabaseDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E178A0D25F9FA00618676 /* VideoDatabaseDirectory.cpp */; };
799 799 E38E20740D25F9FD00618676 /* VirtualDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E178C0D25F9FA00618676 /* VirtualDirectory.cpp */; };
800   - E38E20750D25F9FD00618676 /* VirtualPathDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E178E0D25F9FA00618676 /* VirtualPathDirectory.cpp */; };
801 800 E38E20770D25F9FD00618676 /* ZipDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E17930D25F9FA00618676 /* ZipDirectory.cpp */; };
802 801 E38E20780D25F9FD00618676 /* ZipManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E17950D25F9FA00618676 /* ZipManager.cpp */; };
803 802 E38E207B0D25F9FD00618676 /* GUIDialogBoxBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E179C0D25F9FA00618676 /* GUIDialogBoxBase.cpp */; };
@@ -1382,7 +1381,6 @@
1382 1381 F5A1C9A10F6B06CF00A96ABD /* QueryParams.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E17880D25F9FA00618676 /* QueryParams.cpp */; };
1383 1382 F5A1C9A20F6B06CF00A96ABD /* VideoDatabaseDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E178A0D25F9FA00618676 /* VideoDatabaseDirectory.cpp */; };
1384 1383 F5A1C9A30F6B06CF00A96ABD /* VirtualDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E178C0D25F9FA00618676 /* VirtualDirectory.cpp */; };
1385   - F5A1C9A40F6B06CF00A96ABD /* VirtualPathDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E178E0D25F9FA00618676 /* VirtualPathDirectory.cpp */; };
1386 1384 F5A1C9A50F6B06CF00A96ABD /* ZipDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E17930D25F9FA00618676 /* ZipDirectory.cpp */; };
1387 1385 F5A1C9A60F6B06CF00A96ABD /* ZipManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E17950D25F9FA00618676 /* ZipManager.cpp */; };
1388 1386 F5A1C9A90F6B06CF00A96ABD /* GUIDialogBoxBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E179C0D25F9FA00618676 /* GUIDialogBoxBase.cpp */; };
@@ -2954,8 +2952,6 @@
2954 2952 E38E178B0D25F9FA00618676 /* VideoDatabaseDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VideoDatabaseDirectory.h; sourceTree = "<group>"; };
2955 2953 E38E178C0D25F9FA00618676 /* VirtualDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VirtualDirectory.cpp; sourceTree = "<group>"; };
2956 2954 E38E178D0D25F9FA00618676 /* VirtualDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VirtualDirectory.h; sourceTree = "<group>"; };
2957   - E38E178E0D25F9FA00618676 /* VirtualPathDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VirtualPathDirectory.cpp; sourceTree = "<group>"; };
2958   - E38E178F0D25F9FA00618676 /* VirtualPathDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VirtualPathDirectory.h; sourceTree = "<group>"; };
2959 2955 E38E17920D25F9FA00618676 /* zconf.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = zconf.h; sourceTree = "<group>"; };
2960 2956 E38E17930D25F9FA00618676 /* ZipDirectory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ZipDirectory.cpp; sourceTree = "<group>"; };
2961 2957 E38E17940D25F9FA00618676 /* ZipDirectory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ZipDirectory.h; sourceTree = "<group>"; };
@@ -5654,8 +5650,6 @@
5654 5650 E38E178B0D25F9FA00618676 /* VideoDatabaseDirectory.h */,
5655 5651 E38E178C0D25F9FA00618676 /* VirtualDirectory.cpp */,
5656 5652 E38E178D0D25F9FA00618676 /* VirtualDirectory.h */,
5657   - E38E178E0D25F9FA00618676 /* VirtualPathDirectory.cpp */,
5658   - E38E178F0D25F9FA00618676 /* VirtualPathDirectory.h */,
5659 5653 E49ACD8A100745C400A86ECD /* ZeroconfDirectory.h */,
5660 5654 E49ACD8B100745C400A86ECD /* ZeroconfDirectory.cpp */,
5661 5655 E38E17920D25F9FA00618676 /* zconf.h */,
@@ -7340,7 +7334,6 @@
7340 7334 E38E20720D25F9FD00618676 /* QueryParams.cpp in Sources */,
7341 7335 E38E20730D25F9FD00618676 /* VideoDatabaseDirectory.cpp in Sources */,
7342 7336 E38E20740D25F9FD00618676 /* VirtualDirectory.cpp in Sources */,
7343   - E38E20750D25F9FD00618676 /* VirtualPathDirectory.cpp in Sources */,
7344 7337 E38E20770D25F9FD00618676 /* ZipDirectory.cpp in Sources */,
7345 7338 E38E20780D25F9FD00618676 /* ZipManager.cpp in Sources */,
7346 7339 E38E207B0D25F9FD00618676 /* GUIDialogBoxBase.cpp in Sources */,
@@ -8228,7 +8221,6 @@
8228 8221 F5A1C9A10F6B06CF00A96ABD /* QueryParams.cpp in Sources */,
8229 8222 F5A1C9A20F6B06CF00A96ABD /* VideoDatabaseDirectory.cpp in Sources */,
8230 8223 F5A1C9A30F6B06CF00A96ABD /* VirtualDirectory.cpp in Sources */,
8231   - F5A1C9A40F6B06CF00A96ABD /* VirtualPathDirectory.cpp in Sources */,
8232 8224 F5A1C9A50F6B06CF00A96ABD /* ZipDirectory.cpp in Sources */,
8233 8225 F5A1C9A60F6B06CF00A96ABD /* ZipManager.cpp in Sources */,
8234 8226 F5A1C9A90F6B06CF00A96ABD /* GUIDialogBoxBase.cpp in Sources */,
4 project/VS2010Express/XBMC.vcxproj
@@ -1044,7 +1044,6 @@
1044 1044 <ClCompile Include="..\..\xbmc\FileSystem\UPnPDirectory.cpp" />
1045 1045 <ClCompile Include="..\..\xbmc\FileSystem\VideoDatabaseDirectory.cpp" />
1046 1046 <ClCompile Include="..\..\xbmc\FileSystem\VirtualDirectory.cpp" />
1047   - <ClCompile Include="..\..\xbmc\FileSystem\VirtualPathDirectory.cpp" />
1048 1047 <ClCompile Include="..\..\xbmc\FileSystem\VTPDirectory.cpp" />
1049 1048 <ClCompile Include="..\..\xbmc\FileSystem\VTPFile.cpp" />
1050 1049 <ClCompile Include="..\..\xbmc\FileSystem\VTPSession.cpp" />
@@ -1894,7 +1893,6 @@
1894 1893 <ClInclude Include="..\..\xbmc\FileSystem\SourcesDirectory.h" />
1895 1894 <ClInclude Include="..\..\xbmc\FileSystem\UPnPDirectory.h" />
1896 1895 <ClInclude Include="..\..\xbmc\FileSystem\VideoDatabaseDirectory.h" />
1897   - <ClInclude Include="..\..\xbmc\FileSystem\VirtualPathDirectory.h" />
1898 1896 <ClInclude Include="..\..\xbmc\FileSystem\VTPDirectory.h" />
1899 1897 <ClInclude Include="..\..\xbmc\FileSystem\VTPFile.h" />
1900 1898 <ClInclude Include="..\..\xbmc\FileSystem\VTPSession.h" />
@@ -2041,4 +2039,4 @@
2041 2039 <UserProperties RESOURCE_FILE="XBMC_PC.rc" />
2042 2040 </VisualStudio>
2043 2041 </ProjectExtensions>
2044   -</Project>
  2042 +</Project>
7 xbmc/MediaSource.cpp
@@ -47,10 +47,7 @@ void CMediaSource::FromNameAndPaths(const CStdString &category, const CStdString
47 47 }
48 48 else
49 49 { // multiple valid paths?
50   - if (g_advancedSettings.m_useMultipaths) // use new multipath:// protocol
51   - strPath = CMultiPathDirectory::ConstructMultiPath(vecPaths);
52   - else // use older virtualpath:// protocol
53   - strPath.Format("virtualpath://%s/%s/", category.c_str(), name.c_str());
  50 + strPath = CMultiPathDirectory::ConstructMultiPath(vecPaths);
54 51 }
55 52
56 53 strName = name;
@@ -59,7 +56,7 @@ void CMediaSource::FromNameAndPaths(const CStdString &category, const CStdString
59 56 m_iBadPwdCount = 0;
60 57 m_iHasLock = 0;
61 58
62   - if (URIUtils::IsVirtualPath(strPath) || URIUtils::IsMultiPath(strPath))
  59 + if (URIUtils::IsMultiPath(strPath))
63 60 m_iDriveType = SOURCE_TYPE_VPATH;
64 61 else if (strPath.Left(4).Equals("udf:"))
65 62 {
1  xbmc/Util.cpp
@@ -43,7 +43,6 @@
43 43 #include "addons/Addon.h"
44 44 #include "storage/IoSupport.h"
45 45 #include "filesystem/StackDirectory.h"
46   -#include "filesystem/VirtualPathDirectory.h"
47 46 #include "filesystem/MultiPathDirectory.h"
48 47 #include "filesystem/DirectoryCache.h"
49 48 #include "filesystem/SpecialProtocol.h"
2  xbmc/filesystem/FactoryDirectory.cpp
@@ -26,7 +26,6 @@
26 26 #include "FactoryDirectory.h"
27 27 #include "HDDirectory.h"
28 28 #include "SpecialProtocolDirectory.h"
29   -#include "VirtualPathDirectory.h"
30 29 #include "MultiPathDirectory.h"
31 30 #include "StackDirectory.h"
32 31 #include "FactoryFileDirectory.h"
@@ -129,7 +128,6 @@ IDirectory* CFactoryDirectory::Create(const CStdString& strPath)
129 128 #ifdef HAS_FILESYSTEM_RAR
130 129 if (strProtocol == "rar") return new CRarDirectory();
131 130 #endif
132   - if (strProtocol == "virtualpath") return new CVirtualPathDirectory();
133 131 if (strProtocol == "multipath") return new CMultiPathDirectory();
134 132 if (strProtocol == "stack") return new CStackDirectory();
135 133 if (strProtocol == "playlistmusic") return new CPlaylistDirectory();
1  xbmc/filesystem/Makefile.in
@@ -79,7 +79,6 @@ SRCS=AddonsDirectory.cpp \
79 79 UPnPDirectory.cpp \
80 80 VideoDatabaseDirectory.cpp \
81 81 VirtualDirectory.cpp \
82   - VirtualPathDirectory.cpp \
83 82 VTPDirectory.cpp \
84 83 VTPFile.cpp \
85 84 VTPSession.cpp \
185 xbmc/filesystem/VirtualPathDirectory.cpp
... ... @@ -1,185 +0,0 @@
1   -/*
2   - * Copyright (C) 2005-2008 Team XBMC
3   - * http://www.xbmc.org
4   - *
5   - * This Program is free software; you can redistribute it and/or modify
6   - * it under the terms of the GNU General Public License as published by
7   - * the Free Software Foundation; either version 2, or (at your option)
8   - * any later version.
9   - *
10   - * This Program is distributed in the hope that it will be useful,
11   - * but WITHOUT ANY WARRANTY; without even the implied warranty of
12   - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13   - * GNU General Public License for more details.
14   - *
15   - * You should have received a copy of the GNU General Public License
16   - * along with XBMC; see the file COPYING. If not, write to
17   - * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
18   - * http://www.gnu.org/copyleft/gpl.html
19   - *
20   - */
21   -
22   -#include "VirtualPathDirectory.h"
23   -#include "Directory.h"
24   -#include "settings/Settings.h"
25   -#include "Util.h"
26   -#include "utils/URIUtils.h"
27   -#include "URL.h"
28   -#include "guilib/GUIWindowManager.h"
29   -#include "dialogs/GUIDialogProgress.h"
30   -#include "FileItem.h"
31   -#include "utils/log.h"
32   -#include "utils/TimeUtils.h"
33   -
34   -using namespace std;
35   -using namespace XFILE;
36   -
37   -// virtualpath://type/sourcename
38   -
39   -CVirtualPathDirectory::CVirtualPathDirectory()
40   -{}
41   -
42   -CVirtualPathDirectory::~CVirtualPathDirectory()
43   -{}
44   -
45   -bool CVirtualPathDirectory::GetDirectory(const CStdString& strPath, CFileItemList &items)
46   -{
47   - CLog::Log(LOGDEBUG,"CVirtualPathDirectory::GetDirectory(%s)", strPath.c_str());
48   -
49   - CMediaSource share;
50   - if (!GetMatchingSource(strPath, share))
51   - return false;
52   -
53   - unsigned int progressTime = CTimeUtils::GetTimeMS() + 3000L; // 3 seconds before showing progress bar
54   - CGUIDialogProgress* dlgProgress = NULL;
55   -
56   - unsigned int iFailures = 0;
57   - for (int i = 0; i < (int)share.vecPaths.size(); ++i)
58   - {
59   - // show the progress dialog if we have passed our time limit
60   - if (CTimeUtils::GetTimeMS() > progressTime && !dlgProgress)
61   - {
62   - dlgProgress = (CGUIDialogProgress *)g_windowManager.GetWindow(WINDOW_DIALOG_PROGRESS);
63   - if (dlgProgress)
64   - {
65   - dlgProgress->SetHeading(15310);
66   - dlgProgress->SetLine(0, 15311);
67   - dlgProgress->SetLine(1, "");
68   - dlgProgress->SetLine(2, "");
69   - dlgProgress->StartModal();
70   - dlgProgress->ShowProgressBar(true);
71   - dlgProgress->SetProgressMax((int)share.vecPaths.size()*2);
72   - dlgProgress->Progress();
73   - }
74   - }
75   - if (dlgProgress)
76   - {
77   - CURL url(share.vecPaths[i]);
78   - dlgProgress->SetLine(1, url.GetWithoutUserDetails());
79   - dlgProgress->SetProgressAdvance();
80   - dlgProgress->Progress();
81   - }
82   -
83   - CFileItemList tempItems;
84   - CLog::Log(LOGDEBUG,"Getting Directory (%s)", share.vecPaths[i].c_str());
85   - if (CDirectory::GetDirectory(share.vecPaths[i], tempItems, m_strFileMask, m_useFileDirectories, m_allowPrompting, m_cacheDirectory, m_extFileInfo, true))
86   - items.Append(tempItems);
87   - else
88   - {
89   - CLog::Log(LOGERROR,"Error Getting Directory (%s)", share.vecPaths[i].c_str());
90   - iFailures++;
91   - }
92   -
93   - if (dlgProgress)
94   - {
95   - dlgProgress->SetProgressAdvance();
96   - dlgProgress->Progress();
97   - }
98   - }
99   -
100   - if (dlgProgress)
101   - dlgProgress->Close();
102   -
103   - if (iFailures == share.vecPaths.size())
104   - return false;
105   -
106   - return true;
107   -}
108   -
109   -bool CVirtualPathDirectory::Exists(const CStdString& strPath)
110   -{
111   - CLog::Log(LOGDEBUG,"Testing Existence (%s)", strPath.c_str());
112   - CMediaSource share;
113   - if (!GetMatchingSource(strPath, share))
114   - return false;
115   -
116   - unsigned int iFailures = 0;
117   - for (int i = 0; i < (int)share.vecPaths.size(); ++i)
118   - {
119   - CLog::Log(LOGDEBUG,"Testing Existence (%s)", share.vecPaths[i].c_str());
120   - if (!CDirectory::Exists(share.vecPaths[i]))
121   - {
122   - CLog::Log(LOGERROR,"Error Testing Existence (%s)", share.vecPaths[i].c_str());
123   - iFailures++;
124   - }
125   - }
126   -
127   - if (iFailures == share.vecPaths.size())
128   - return false;
129   -
130   - return true;
131   -}
132   -
133   -bool CVirtualPathDirectory::GetPathes(const CStdString& strPath, vector<CStdString>& vecPaths)
134   -{
135   - CMediaSource share;
136   - if (!GetMatchingSource(strPath, share))
137   - return false;
138   - vecPaths = share.vecPaths;
139   - return true;
140   -}
141   -
142   -bool CVirtualPathDirectory::GetTypeAndSource(const CStdString& strPath, CStdString& strType, CStdString& strSource)
143   -{
144   - // format: virtualpath://type/sourcename
145   - CStdString strTemp = strPath;
146   - URIUtils::RemoveSlashAtEnd(strTemp);
147   - CStdString strTest = "virtualpath://";
148   - if (strTemp.Left(strTest.length()).Equals(strTest))
149   - {
150   - strTemp = strTemp.Mid(strTest.length());
151   - int iPos = strTemp.Find('/');
152   - if (iPos < 1)
153   - return false;
154   - strType = strTemp.Mid(0, iPos);
155   - strSource = strTemp.Mid(iPos + 1);
156   - //CLog::Log(LOGDEBUG,"CVirtualPathDirectory::GetTypeAndSource(%s) = [%s],[%s]", strPath.c_str(), strType.c_str(), strSource.c_str());
157   - return true;
158   - }
159   - return false;
160   -}
161   -
162   -bool CVirtualPathDirectory::GetMatchingSource(const CStdString &strPath, CMediaSource& share)
163   -{
164   - CStdString strType, strSource;
165   - if (!GetTypeAndSource(strPath, strType, strSource))
166   - return false;
167   -
168   - // no support for "files" operation
169   - if (strType == "files")
170   - return false;
171   - VECSOURCES *VECSOURCES = g_settings.GetSourcesFromType(strType);
172   - if (!VECSOURCES)
173   - return false;
174   -
175   - bool bIsSourceName = false;
176   - int iIndex = CUtil::GetMatchingSource(strSource, *VECSOURCES, bIsSourceName);
177   - if (!bIsSourceName)
178   - return false;
179   - if (iIndex < 0 || iIndex >= (int)VECSOURCES->size())
180   - return false;
181   -
182   - share = (*VECSOURCES)[iIndex];
183   - return true;
184   -}
185   -
44 xbmc/filesystem/VirtualPathDirectory.h
... ... @@ -1,44 +0,0 @@
1   -#pragma once
2   -/*
3   - * Copyright (C) 2005-2008 Team XBMC
4   - * http://www.xbmc.org
5   - *
6   - * This Program is free software; you can redistribute it and/or modify
7   - * it under the terms of the GNU General Public License as published by
8   - * the Free Software Foundation; either version 2, or (at your option)
9   - * any later version.
10   - *
11   - * This Program is distributed in the hope that it will be useful,
12   - * but WITHOUT ANY WARRANTY; without even the implied warranty of
13   - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14   - * GNU General Public License for more details.
15   - *
16   - * You should have received a copy of the GNU General Public License
17   - * along with XBMC; see the file COPYING. If not, write to
18   - * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
19   - * http://www.gnu.org/copyleft/gpl.html
20   - *
21   - */
22   -
23   -#include "IDirectory.h"
24   -
25   -class CMediaSource;
26   -
27   -namespace XFILE
28   -{
29   -class CVirtualPathDirectory :
30   - public IDirectory
31   -{
32   -public:
33   - CVirtualPathDirectory(void);
34   - virtual ~CVirtualPathDirectory(void);
35   - virtual bool GetDirectory(const CStdString& strPath, CFileItemList &items);
36   - virtual bool Exists(const CStdString& strPath);
37   -
38   - bool GetPathes(const CStdString& strPath, std::vector<CStdString>& vecPaths);
39   -
40   -protected:
41   - bool GetTypeAndSource(const CStdString& strPath, CStdString& strType, CStdString& strSource);
42   - bool GetMatchingSource(const CStdString &strPath, CMediaSource& share);
43   -};
44   -}
3  xbmc/settings/AdvancedSettings.cpp
@@ -45,8 +45,6 @@ CAdvancedSettings::CAdvancedSettings()
45 45
46 46 void CAdvancedSettings::Initialize()
47 47 {
48   - m_useMultipaths = true;
49   -
50 48 m_audioHeadRoom = 0;
51 49 m_ac3Gain = 12.0f;
52 50 m_audioApplyDrc = true;
@@ -632,7 +630,6 @@ bool CAdvancedSettings::Load()
632 630 XMLUtils::GetBoolean(pRootElement, "handlemounting", m_handleMounting);
633 631
634 632 XMLUtils::GetBoolean(pRootElement, "nodvdrom", m_noDVDROM);
635   - XMLUtils::GetBoolean(pRootElement, "usemultipaths", m_useMultipaths);
636 633 #ifdef HAS_SDL
637 634 XMLUtils::GetBoolean(pRootElement, "fullscreen", m_startFullScreen);
638 635 #endif
3  xbmc/settings/AdvancedSettings.h
@@ -77,9 +77,6 @@ class CAdvancedSettings
77 77 static void GetCustomRegexpReplacers(TiXmlElement *pRootElement, CStdStringArray& settings);
78 78 static void GetCustomExtensions(TiXmlElement *pRootElement, CStdString& extensions);
79 79
80   - // multipath testing
81   - bool m_useMultipaths;
82   -
83 80 int m_audioHeadRoom;
84 81 float m_ac3Gain;
85 82 CStdString m_audioDefaultPlayer;
16 xbmc/settings/Settings.cpp
@@ -284,7 +284,7 @@ bool CSettings::GetSource(const CStdString &category, const TiXmlNode *source, C
284 284 strPath = CSpecialProtocol::ReplaceOldPath(strPath, pathVersion);
285 285 // make sure there are no virtualpaths or stack paths defined in xboxmediacenter.xml
286 286 //CLog::Log(LOGDEBUG," Found path: %s", strPath.c_str());
287   - if (!URIUtils::IsVirtualPath(strPath) && !URIUtils::IsStack(strPath))
  287 + if (!URIUtils::IsStack(strPath))
288 288 {
289 289 // translate special tags
290 290 if (!strPath.IsEmpty() && strPath.at(0) == '$')
@@ -362,16 +362,6 @@ bool CSettings::GetSource(const CStdString &category, const TiXmlNode *source, C
362 362
363 363 share.FromNameAndPaths(category, strName, verifiedPaths);
364 364
365   -/* CLog::Log(LOGDEBUG," Adding source:");
366   - CLog::Log(LOGDEBUG," Name: %s", share.strName.c_str());
367   - if (URIUtils::IsVirtualPath(share.strPath) || URIUtils::IsMultiPath(share.strPath))
368   - {
369   - for (int i = 0; i < (int)share.vecPaths.size(); ++i)
370   - CLog::Log(LOGDEBUG," Path (%02i): %s", i+1, share.vecPaths.at(i).c_str());
371   - }
372   - else
373   - CLog::Log(LOGDEBUG," Path: %s", share.strPath.c_str());
374   -*/
375 365 share.m_iBadPwdCount = 0;
376 366 if (pLockMode)
377 367 {
@@ -1170,10 +1160,6 @@ bool CSettings::UpdateSource(const CStdString &strType, const CStdString strOldN
1170 1160
1171 1161 if (!pShares) return false;
1172 1162
1173   - // disallow virtual paths
1174   - if (strUpdateElement.Equals("path") && URIUtils::IsVirtualPath(strUpdateText))
1175   - return false;
1176   -
1177 1163 for (IVECSOURCES it = pShares->begin(); it != pShares->end(); it++)
1178 1164 {
1179 1165 if ((*it).strName == strOldName)
18 xbmc/utils/URIUtils.cpp
@@ -26,7 +26,6 @@
26 26 #include "filesystem/MythDirectory.h"
27 27 #include "filesystem/SpecialProtocol.h"
28 28 #include "filesystem/StackDirectory.h"
29   -#include "filesystem/VirtualPathDirectory.h"
30 29 #include "network/DNSNameCache.h"
31 30 #include "settings/Settings.h"
32 31 #include "URL.h"
@@ -328,18 +327,6 @@ bool URIUtils::IsRemote(const CStdString& strFile)
328 327 if(IsStack(strFile))
329 328 return IsRemote(CStackDirectory::GetFirstStackedFile(strFile));
330 329
331   - if (IsVirtualPath(strFile))
332   - { // virtual paths need to be checked separately
333   - CVirtualPathDirectory dir;
334   - vector<CStdString> paths;
335   - if (dir.GetPathes(strFile, paths))
336   - {
337   - for (unsigned int i = 0; i < paths.size(); i++)
338   - if (IsRemote(paths[i])) return true;
339   - }
340   - return false;
341   - }
342   -
343 330 if(IsMultiPath(strFile))
344 331 { // virtual paths need to be checked separately
345 332 vector<CStdString> paths;
@@ -492,11 +479,6 @@ bool URIUtils::IsDVD(const CStdString& strFile)
492 479 return false;
493 480 }
494 481
495   -bool URIUtils::IsVirtualPath(const CStdString& strFile)
496   -{
497   - return strFile.Left(12).Equals("virtualpath:");
498   -}
499   -
500 482 bool URIUtils::IsStack(const CStdString& strFile)
501 483 {
502 484 return strFile.Left(6).Equals("stack:");
1  xbmc/utils/URIUtils.h
@@ -79,7 +79,6 @@ class URIUtils
79 79 static bool IsUPnP(const CStdString& strFile);
80 80 static bool IsURL(const CStdString& strFile);
81 81 static bool IsVideoDb(const CStdString& strFile);
82   - static bool IsVirtualPath(const CStdString& strFile);
83 82 static bool IsVTP(const CStdString& strFile);
84 83 static bool IsZIP(const CStdString& strFile);
85 84

0 comments on commit 18ef66b

Please sign in to comment.
Something went wrong with that request. Please try again.