mirror of
https://github.com/GTA-ASM/SanAndreasUnity
synced 2025-02-16 12:58:27 +00:00
draw main menu entries with respect to font size
This commit is contained in:
parent
5bdcf84ee0
commit
c17559b80b
3 changed files with 9 additions and 4 deletions
|
@ -59,7 +59,7 @@ namespace SanAndreasUnity.UI
|
|||
}
|
||||
}
|
||||
|
||||
// draw buttons at bottom of screen: Main scene, Demo scene, Options, Change path to GTA, Exit
|
||||
// draw menu entries at bottom of screen
|
||||
|
||||
s_buttonOptions = new GUILayoutOption[]{ GUILayout.MinWidth(minButtonWidth), GUILayout.MinHeight(minButtonHeight) };
|
||||
|
||||
|
@ -81,7 +81,7 @@ namespace SanAndreasUnity.UI
|
|||
GUILayout.Space (this.spaceBetweenButtons);
|
||||
}
|
||||
|
||||
if (GUILayout.Button ("Exit", s_buttonOptions))
|
||||
if (MainMenu.DrawMenuEntry ("Exit"))
|
||||
{
|
||||
GameManager.ExitApplication ();
|
||||
}
|
||||
|
@ -98,6 +98,11 @@ namespace SanAndreasUnity.UI
|
|||
|
||||
}
|
||||
|
||||
public static bool DrawMenuEntry(string text)
|
||||
{
|
||||
return GUIUtils.ButtonWithCalculatedSize(text);
|
||||
}
|
||||
|
||||
public static void RegisterMenuEntry (MenuEntry menuEntry)
|
||||
{
|
||||
s_rootMenuEntry.AddChild (menuEntry);
|
||||
|
|
|
@ -278,7 +278,7 @@ namespace SanAndreasUnity.UI {
|
|||
if (this.IsOpened)
|
||||
GUI.contentColor = MainMenu.Instance.openedWindowTextColor;
|
||||
|
||||
if (GUILayout.Button (this.windowName, MainMenu.ButtonLayoutOptions))
|
||||
if (MainMenu.DrawMenuEntry (this.windowName))
|
||||
{
|
||||
this.IsOpened = !this.IsOpened;
|
||||
}
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
- Chat
|
||||
|
||||
- Android: set font size to 20 ; adapt UI: StartGame button, JoinGame button, Console "Clear", main menu ; sliders should be larger ; camera zoom should be configurable (no need for persistence) ; use unsigned (debug) key alias ; increment build number ;
|
||||
- Android: set font size to 20 ; adapt UI: StartGame scrollview style, JoinGame scrollview style, main menu, options (save, load, use box as scrollview style, size), Utilities size, file browser size ; sliders should be larger ; camera zoom should be configurable (no need for persistence) ; use unsigned (debug) key alias ; increment build number ; test at 800x480 resolution ;
|
||||
|
||||
- Touch input:
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue