Fixed naming conventions and changed new classes to internal since we shouldn't expose these publicly (they are already legacy)
This commit is contained in:
@@ -8,7 +8,7 @@ using System.Web.UI.WebControls;
|
||||
|
||||
namespace umbraco.uicontrols
|
||||
{
|
||||
public class DataAttributes : Dictionary<string,string>
|
||||
internal class DataAttributes : Dictionary<string,string>
|
||||
{
|
||||
public DataAttributes()
|
||||
{
|
||||
|
||||
@@ -2,13 +2,14 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Umbraco.Core.IO;
|
||||
|
||||
namespace umbraco.uicontrols
|
||||
{
|
||||
public class MenuButton : System.Web.UI.WebControls.LinkButton
|
||||
internal class MenuButton : System.Web.UI.WebControls.LinkButton
|
||||
{
|
||||
public MenuButtonType ButtonType { get; set; }
|
||||
public DataAttributes Data { get; private set; }
|
||||
internal DataAttributes Data { get; private set; }
|
||||
public string Hotkey { get; set; }
|
||||
|
||||
public string Icon { get; set; }
|
||||
@@ -25,7 +26,7 @@ namespace umbraco.uicontrols
|
||||
//setup a hotkey if present
|
||||
if (ButtonType == MenuButtonType.Primary && String.IsNullOrEmpty(Hotkey))
|
||||
Data.Add("shortcut", "ctrl+" + this.Text.ToLower()[0]);
|
||||
else if (!String.IsNullOrEmpty(Hotkey))
|
||||
else if (!string.IsNullOrEmpty(Hotkey))
|
||||
Data.Add("shortcut", Hotkey);
|
||||
|
||||
Data.AppendTo(this);
|
||||
@@ -42,7 +43,7 @@ namespace umbraco.uicontrols
|
||||
this.ToolTip = this.Text;
|
||||
|
||||
if (i.Contains("."))
|
||||
this.Text = "<img src='" + umbraco.IO.IOHelper.ResolveUrl(Icon) + "' alt='" + this.ToolTip + "'/> " + this.ToolTip;
|
||||
this.Text = "<img src='" + IOHelper.ResolveUrl(Icon) + "' alt='" + this.ToolTip + "'/> " + this.ToolTip;
|
||||
else
|
||||
this.Text = "<i class='icon icon-" + Icon.Replace("icon-", "") + "'></i> " + this.ToolTip;
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ using System.Web.UI.WebControls;
|
||||
|
||||
namespace umbraco.uicontrols
|
||||
{
|
||||
public class MenuSplitButton : Panel
|
||||
internal class MenuSplitButton : Panel
|
||||
{
|
||||
|
||||
public string Text { get; set; }
|
||||
|
||||
@@ -18,4 +18,5 @@ using System.Runtime.InteropServices;
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("1292737a-7e2d-464a-9850-9380792f668e")]
|
||||
|
||||
[assembly: InternalsVisibleTo("Umbraco.Web.UI")]
|
||||
[assembly: InternalsVisibleTo("Umbraco.Web.UI")]
|
||||
[assembly: InternalsVisibleTo("umbraco")]
|
||||
@@ -34,17 +34,17 @@ namespace umbraco.uicontrols
|
||||
writer.WriteLine("</div>");
|
||||
}
|
||||
|
||||
public void addProperty(string Caption, Control C)
|
||||
public void AddProperty(string caption, Control c)
|
||||
{
|
||||
|
||||
PropertyPanel pp = new PropertyPanel();
|
||||
pp.Controls.Add(C);
|
||||
pp.Text = Caption;
|
||||
pp.Controls.Add(c);
|
||||
pp.Text = caption;
|
||||
|
||||
this.Controls.Add(pp);
|
||||
}
|
||||
|
||||
public void addProperty(Control ctrl)
|
||||
public void AddProperty(Control ctrl)
|
||||
{
|
||||
|
||||
PropertyPanel pp = new PropertyPanel();
|
||||
|
||||
@@ -36,14 +36,14 @@ namespace umbraco.uicontrols
|
||||
return icon;
|
||||
}
|
||||
|
||||
public MenuSplitButton NewSplitButton()
|
||||
internal MenuSplitButton NewSplitButton()
|
||||
{
|
||||
var menu = new MenuSplitButton();
|
||||
Icons.Add(menu);
|
||||
return menu;
|
||||
}
|
||||
|
||||
public MenuButton NewButton(int index = -1)
|
||||
internal MenuButton NewButton(int index = -1)
|
||||
{
|
||||
MenuButton btn = new MenuButton();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user