Sfoglia il codice sorgente

MenuItem code cleanup

Tig 1 anno fa
parent
commit
b6a925ea97
1 ha cambiato i file con 3 aggiunte e 4 eliminazioni
  1. 3 4
      Terminal.Gui/Views/Menu/MenuItem.cs

+ 3 - 4
Terminal.Gui/Views/Menu/MenuItem.cs

@@ -154,10 +154,10 @@ public class MenuItem
                                : 0); // Pad two spaces before shortcut tag (which are also aligned right)
                                : 0); // Pad two spaces before shortcut tag (which are also aligned right)
 
 
     /// <summary>Merely a debugging aid to see the interaction with main.</summary>
     /// <summary>Merely a debugging aid to see the interaction with main.</summary>
-    public bool GetMenuBarItem () { return IsFromSubMenu; }
+    internal bool GetMenuBarItem () { return IsFromSubMenu; }
 
 
     /// <summary>Merely a debugging aid to see the interaction with main.</summary>
     /// <summary>Merely a debugging aid to see the interaction with main.</summary>
-    public MenuItem GetMenuItem () { return this; }
+    internal MenuItem GetMenuItem () { return this; }
 
 
     /// <summary>
     /// <summary>
     ///     Returns <see langword="true"/> if the menu item is enabled. This method is a wrapper around
     ///     Returns <see langword="true"/> if the menu item is enabled. This method is a wrapper around
@@ -217,7 +217,6 @@ public class MenuItem
     ///     <para>See also <see cref="Shortcut"/> which enable global key-bindings to menu items.</para>
     ///     <para>See also <see cref="Shortcut"/> which enable global key-bindings to menu items.</para>
     /// </summary>
     /// </summary>
     public Rune HotKey { get; set; }
     public Rune HotKey { get; set; }
-
     private void GetHotKey ()
     private void GetHotKey ()
     {
     {
         var nextIsHot = false;
         var nextIsHot = false;
@@ -271,4 +270,4 @@ public class MenuItem
                                      : Key.ToString (_shortcutHelper.Shortcut, MenuBar.ShortcutDelimiter);
                                      : Key.ToString (_shortcutHelper.Shortcut, MenuBar.ShortcutDelimiter);
 
 
     #endregion Keyboard Handling
     #endregion Keyboard Handling
-}
+}