Cleans up legacy stylesheet code to wrap the new APIs better, creates a new OriginalPath property on IFile to track if the path has changed, updates FileRepository to deal with path's changing and automatically deal with renaming files. Adds new methods to IFileService: GetStylesheetsAtPath. Fixes up the stylesheet and stylesheet property editors to use the file names, gets tree syncing working nicely for them both even with files or properties are renamed. Updates stylesheet editors and controllers to use the new APIs
This commit is contained in:
@@ -374,6 +374,11 @@ namespace Umbraco.Core
|
||||
return input.EndsWith(value.ToString(CultureInfo.InvariantCulture)) ? input : input + value;
|
||||
}
|
||||
|
||||
public static string EnsureEndsWith(this string input, string toEndWith)
|
||||
{
|
||||
return input.EndsWith(toEndWith.ToString(CultureInfo.InvariantCulture)) ? input : input + toEndWith;
|
||||
}
|
||||
|
||||
public static bool IsLowerCase(this char ch)
|
||||
{
|
||||
return ch.ToString(CultureInfo.InvariantCulture) == ch.ToString(CultureInfo.InvariantCulture).ToLowerInvariant();
|
||||
|
||||
Reference in New Issue
Block a user