OSDN Git Service

Merge branch 'feature/37178_プロジェクトとソリューションファイルの英語化' into develop
[dtxmania/dtxmania.git] / DTXCreatorプロジェクト / コード / 06.汎用 / Cファイル選択・パス変換.cs
diff --git a/DTXCreatorプロジェクト/コード/06.汎用/Cファイル選択・パス変換.cs b/DTXCreatorプロジェクト/コード/06.汎用/Cファイル選択・パス変換.cs
deleted file mode 100644 (file)
index f693d33..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-using System;\r
-using System.Collections.Generic;\r
-using System.Text;\r
-using System.IO;\r
-\r
-namespace DTXCreator.汎用\r
-{\r
-       public class Cファイル選択_パス変換\r
-       {\r
-               public static bool b絶対パスである( string strパス )\r
-               {\r
-                       try\r
-                       {\r
-                               new Uri( strパス );\r
-                       }\r
-                       catch\r
-                       {\r
-                               return false;\r
-                       }\r
-                       return true;\r
-               }\r
-               public static string str基点からの相対パスに変換して返す( string str変換対象の絶対パス, string str基点となる絶対パス )\r
-               {\r
-                       if( str基点となる絶対パス == "" )\r
-                       {\r
-                               return str変換対象の絶対パス;\r
-                       }\r
-                       if( str変換対象の絶対パス == "" )\r
-                       {\r
-                               return "";\r
-                       }\r
-                       Uri uri = new Uri( str基点となる絶対パス );\r
-                       return Uri.UnescapeDataString( uri.MakeRelativeUri( new Uri( str変換対象の絶対パス ) ).ToString() ).Replace( '/', '\\' );\r
-               }\r
-               public static string str指定されたファイルの存在するフォルダを絶対パスで返す( string strファイルのパス, string strパスが相対の場合の基点絶対パス )\r
-               {\r
-                       if( !b絶対パスである( strファイルのパス ) )\r
-                       {\r
-                               strファイルのパス = strパスが相対の場合の基点絶対パス + strファイルのパス;\r
-                       }\r
-                       string directoryName = Path.GetDirectoryName( strファイルのパス );\r
-                       if( directoryName == null )\r
-                       {\r
-                               return @"\";\r
-                       }\r
-                       if( !directoryName.EndsWith( @"\" ) )\r
-                       {\r
-                               directoryName = directoryName + @"\";\r
-                       }\r
-                       return directoryName;\r
-               }\r
-       }\r
-}\r