This commit is contained in:
29
source/WBI/App_Code/ThemeManager.cs
Normal file
29
source/WBI/App_Code/ThemeManager.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Data;
|
||||
using System.Configuration;
|
||||
using System.Web;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.Web.UI.WebControls.WebParts;
|
||||
using System.Web.UI.HtmlControls;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
public class ThemeManager
|
||||
{
|
||||
#region Theme-Related Method
|
||||
public static List<Theme> GetThemes()
|
||||
{
|
||||
DirectoryInfo dInfo = new DirectoryInfo(System.Web.HttpContext.Current.Server.MapPath("App_Themes"));
|
||||
DirectoryInfo[] dArrInfo = dInfo.GetDirectories();
|
||||
List<Theme> list = new List<Theme>();
|
||||
foreach (DirectoryInfo sDirectory in dArrInfo)
|
||||
{
|
||||
Theme temp = new Theme(sDirectory.Name);
|
||||
list.Add(temp);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
Reference in New Issue
Block a user