mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-04-13 20:47:24 +00:00
refactor: Removing preprocessors and adding better multi-platform support
This commit is contained in:
parent
3a4438ec1e
commit
1d7ada87c5
2 changed files with 5 additions and 5 deletions
|
|
@ -19,17 +19,18 @@ namespace ICD.Common.Utils.IO
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#if SIMPLSHARP
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This gets the application root directory for Crestron systems
|
/// This gets the application root directory for Crestron systems
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static string GetApplicationRootDirectory()
|
public static string GetApplicationRootDirectory()
|
||||||
{
|
{
|
||||||
|
#if SIMPLSHARP
|
||||||
return Directory.GetApplicationRootDirectory();
|
return Directory.GetApplicationRootDirectory();
|
||||||
}
|
#else
|
||||||
|
return Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().CodeBase);
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
public static bool Exists(string path)
|
public static bool Exists(string path)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -20,10 +20,9 @@ namespace ICD.Common.Utils
|
||||||
public static string RootPath {
|
public static string RootPath {
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
#if SIMPLSHARP
|
|
||||||
if (IcdEnvironment.RuntimeEnvironment == IcdEnvironment.eRuntimeEnvironment.SimplSharpProMono)
|
if (IcdEnvironment.RuntimeEnvironment == IcdEnvironment.eRuntimeEnvironment.SimplSharpProMono)
|
||||||
return IcdDirectory.GetApplicationRootDirectory();
|
return IcdDirectory.GetApplicationRootDirectory();
|
||||||
#endif
|
|
||||||
return IcdDirectory.GetDirectoryRoot(IcdPath.DirectorySeparatorChar.ToString());
|
return IcdDirectory.GetDirectoryRoot(IcdPath.DirectorySeparatorChar.ToString());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue