improve gui in audio window

This commit is contained in:
in0finite 2019-08-28 22:00:02 +02:00
parent 2fd586cfe0
commit e163290126
2 changed files with 11 additions and 3 deletions

View file

@ -157,6 +157,7 @@ namespace SanAndreasUnity.UI {
// float startingY = this.toolbarAreaHeight + this.timingAreaHeight + 40f;
GUILayout.BeginHorizontal ();
GUILayout.Space(1);
// SIDEBAR
@ -233,7 +234,9 @@ namespace SanAndreasUnity.UI {
// we can't display a list, because there is no way to enumerate all sounds
// for now, just display text field for bank index
GUILayout.Space (5);
GUILayout.Space (15);
GUILayout.BeginVertical();
if (null == this.SelectedAudioFile)
{
@ -242,7 +245,7 @@ namespace SanAndreasUnity.UI {
if (this.SelectedAudioFile != null)
{
GUILayout.Label ("Enter bank index [0 - " + (this.SelectedAudioFile.NumBanks - 1) + "]:", GUILayout.ExpandWidth(false));
GUILayout.Label ("bank index [0 - " + (this.SelectedAudioFile.NumBanks - 1) + "]:", GUILayout.ExpandWidth(false));
m_bankIndexStr = GUILayout.TextField (m_bankIndexStr, 6, GUILayout.Width (120));
}
@ -255,12 +258,15 @@ namespace SanAndreasUnity.UI {
bool isValidBankIndex = uint.TryParse(m_bankIndexStr, out bankIndex);
bool displayAudioIndex = isValidBankIndex && bankIndex < m_selectedSfxFile.NumBanks;
GUILayout.Label ("Enter audio index " + (displayAudioIndex ? "[0 - " + (m_selectedSfxFile.GetNumAudioClipsFromBank(bankIndex) - 1).ToString() + "]" : "") + ":", GUILayout.ExpandWidth(false));
GUILayout.Label ("audio index " + (displayAudioIndex ? "[0 - " + (m_selectedSfxFile.GetNumAudioClipsFromBank(bankIndex) - 1).ToString() + "]" : "") + ":", GUILayout.ExpandWidth(false));
m_audioIndexStr = GUILayout.TextField (m_audioIndexStr, 6, GUILayout.Width (120));
}
// GUILayout.EndArea ();
GUILayout.EndVertical();
GUILayout.Space(1);
GUILayout.EndHorizontal ();
}

View file

@ -23,6 +23,8 @@
- Does 'O' button changes quality level ?
- Restore physics update rate to 50
- Chat
- Remove unused packages added by Unity