Show the color of a player while selecting channels

This commit is contained in:
Flamefire committed 2014-03-10 21:13:28 +01:00
1 parent 5b478a185e
commit 070777eb68
3 files changed
+50 -37

No files matched your search

@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<root> <root>
<ScreenOptionsRecord> <ScreenOptionsRecord>
<ScreenVersion>3</ScreenVersion> <ScreenVersion>4</ScreenVersion>
<Background1> <Background1>
<!--<Type>: Background type: None, Color, Texture, Video--> <!--<Type>: Background type: None, Color, Texture, Video-->
<Type>Video</Type> <Type>Video</Type>
@@ -216,6 +216,35 @@
<!-- <Height>: Reflection Height--> <!-- <Height>: Reflection Height-->
</Text2> </Text2>
<Text3> <Text3>
<!--<X>, <Y>: Text position-->
<X>75</X>
<Y>347</Y>
<!--<Z>: Text position-->
<Z>0,00</Z>
<!--<H>: Text height-->
<H>27</H>
<!--<MaxW>: Maximum text width (if exists)-->
<!--<Color>: Text color from ColorScheme (high priority)-->
<!--or <R>, <G>, <B>, <A> (lower priority)-->
<Color>StaticColor</Color>
<!--<SColor>: Selected Text color from ColorScheme (high priority)-->
<!--or <SR>, <SG>, <SB>, <SA> (lower priority)-->
<SColor>TextSColor</SColor>
<!--<Align>: Text align horizontal: Left, Center, Right-->
<Align>Left</Align>
<!--<ResizeAlign>: Text align vertical (on downsizing): Top, Center, Bottom-->
<HAlign>Center</HAlign>
<!--<Style>: Text style: Normal, Italic, Bold, BoldItalic-->
<Style>Bold</Style>
<!--<Font>: Text font name-->
<Font>Outline</Font>
<!--<Text>: Nothing or translation tag-->
<Text>TR_SCREENORECORD_MIC_DELAY</Text>
<!--<Reflection> If exists:-->
<!-- <Space>: Reflection Space-->
<!-- <Height>: Reflection Height-->
</Text3>
<TextChannel1>
<!--<X>, <Y>: Text position--> <!--<X>, <Y>: Text position-->
<X>75</X> <X>75</X>
<Y>227</Y> <Y>227</Y>
@@ -243,8 +272,8 @@
<!--<Reflection> If exists:--> <!--<Reflection> If exists:-->
<!-- <Space>: Reflection Space--> <!-- <Space>: Reflection Space-->
<!-- <Height>: Reflection Height--> <!-- <Height>: Reflection Height-->
</Text3> </TextChannel1>
<Text4> <TextChannel2>
<!--<X>, <Y>: Text position--> <!--<X>, <Y>: Text position-->
<X>75</X> <X>75</X>
<Y>287</Y> <Y>287</Y>
@@ -272,36 +301,7 @@
<!--<Reflection> If exists:--> <!--<Reflection> If exists:-->
<!-- <Space>: Reflection Space--> <!-- <Space>: Reflection Space-->
<!-- <Height>: Reflection Height--> <!-- <Height>: Reflection Height-->
</Text4> </TextChannel2>
<Text5>
<!--<X>, <Y>: Text position-->
<X>75</X>
<Y>347</Y>
<!--<Z>: Text position-->
<Z>0,00</Z>
<!--<H>: Text height-->
<H>27</H>
<!--<MaxW>: Maximum text width (if exists)-->
<!--<Color>: Text color from ColorScheme (high priority)-->
<!--or <R>, <G>, <B>, <A> (lower priority)-->
<Color>StaticColor</Color>
<!--<SColor>: Selected Text color from ColorScheme (high priority)-->
<!--or <SR>, <SG>, <SB>, <SA> (lower priority)-->
<SColor>TextSColor</SColor>
<!--<Align>: Text align horizontal: Left, Center, Right-->
<Align>Left</Align>
<!--<ResizeAlign>: Text align vertical (on downsizing): Top, Center, Bottom-->
<HAlign>Center</HAlign>
<!--<Style>: Text style: Normal, Italic, Bold, BoldItalic-->
<Style>Bold</Style>
<!--<Font>: Text font name-->
<Font>Outline</Font>
<!--<Text>: Nothing or translation tag-->
<Text>TR_SCREENORECORD_MIC_DELAY</Text>
<!--<Reflection> If exists:-->
<!-- <Space>: Reflection Space-->
<!-- <Height>: Reflection Height-->
</Text5>
<TextWarning> <TextWarning>
<!--<X>, <Y>: Text position--> <!--<X>, <Y>: Text position-->
<X>640</X> <X>640</X>
@@ -7,3 +7,6 @@ Add:
<EqualizerChannel1> and <EqualizerChannel2>. <EqualizerChannel1> and <EqualizerChannel2>.
This is a new theme-element. Check ScreenOptionsRecord.xml for style-possibilities. This is a new theme-element. Check ScreenOptionsRecord.xml for style-possibilities.
++++++++++ ++++++++++
Version 4:
Rename Text 3/4 to TextChannel1/2
Rename Text5 to Text3
+14 -4
View File
@@ -37,7 +37,7 @@ namespace Vocaluxe.Screens
// Version number for theme files. Increment it, if you've changed something on the theme files! // Version number for theme files. Increment it, if you've changed something on the theme files!
protected override int _ScreenVersion protected override int _ScreenVersion
{ {
get { return 3; } get { return 4; }
} }
private const float _MaxDelayTime = 1f; private const float _MaxDelayTime = 1f;
@@ -53,6 +53,9 @@ namespace Vocaluxe.Screens
private const string _ButtonExit = "ButtonExit"; private const string _ButtonExit = "ButtonExit";
private const string _ButtonDelayTest = "ButtonDelayTest"; private const string _ButtonDelayTest = "ButtonDelayTest";
private const string _TextChannel1 = "TextChannel1";
private const string _TextChannel2 = "TextChannel2";
private const string _TextDelayChannel1 = "TextDelayChannel1"; private const string _TextDelayChannel1 = "TextDelayChannel1";
private const string _TextDelayChannel2 = "TextDelayChannel2"; private const string _TextDelayChannel2 = "TextDelayChannel2";
@@ -77,7 +80,7 @@ namespace Vocaluxe.Screens
values.AddRange(_StaticEnergyChannel); values.AddRange(_StaticEnergyChannel);
_ThemeStatics = values.ToArray(); _ThemeStatics = values.ToArray();
_ThemeTexts = new string[] {_TextWarning, _TextDelayChannel1, _TextDelayChannel2}; _ThemeTexts = new string[] {_TextWarning, _TextChannel1, _TextChannel2, _TextDelayChannel1, _TextDelayChannel2};
_ThemeButtons = new string[] {_ButtonExit, _ButtonDelayTest}; _ThemeButtons = new string[] {_ButtonExit, _ButtonDelayTest};
_ThemeSelectSlides = new string[] {_SelectSlideRecordDevices, _SelectSlideRecordChannel1, _SelectSlideRecordChannel2, _SelectSlideDelay}; _ThemeSelectSlides = new string[] {_SelectSlideRecordDevices, _SelectSlideRecordChannel1, _SelectSlideRecordChannel2, _SelectSlideDelay};
_ThemeEqualizers = new string[] {_EqualizerChannel1, _EqualizerChannel2}; _ThemeEqualizers = new string[] {_EqualizerChannel1, _EqualizerChannel2};
@@ -248,8 +251,7 @@ namespace Vocaluxe.Screens
_DelayTest[i].Timer.Stop(); _DelayTest[i].Timer.Stop();
_DelayTestRunning = false; _DelayTestRunning = false;
} }
else if (CSound.RecordGetMaxVolume(player - 1) > 0.1f && else if (CSound.RecordGetMaxVolume(player - 1) > 0.1f && CSound.RecordGetToneAbs(player - 1) % 12 == 9)
(CSound.RecordGetToneAbs(player - 1) == 9 || CSound.RecordGetToneAbs(player - 1) == 21 || CSound.RecordGetToneAbs(player - 1) == 33))
{ {
_DelayTest[i].Delay = _DelayTest[i].Timer.ElapsedMilliseconds; _DelayTest[i].Delay = _DelayTest[i].Timer.ElapsedMilliseconds;
_DelayTest[i].Timer.Stop(); _DelayTest[i].Timer.Stop();
@@ -444,6 +446,12 @@ namespace Vocaluxe.Screens
CSound.RecordStart(); CSound.RecordStart();
} }
private void _SetPlayerColors()
{
_Texts[_TextChannel1].Color = CTheme.GetPlayerColor(_SelectSlides[_SelectSlideRecordChannel1].Selection);
_Texts[_TextChannel2].Color = CTheme.GetPlayerColor(_SelectSlides[_SelectSlideRecordChannel2].Selection);
}
private void _SetMicConfig() private void _SetMicConfig()
{ {
if (_DeviceNr < 0) if (_DeviceNr < 0)
@@ -451,6 +459,7 @@ namespace Vocaluxe.Screens
CRecordDevice device = _Devices[_DeviceNr]; CRecordDevice device = _Devices[_DeviceNr];
device.PlayerChannel1 = _SelectSlides[_SelectSlideRecordChannel1].Selection; device.PlayerChannel1 = _SelectSlides[_SelectSlideRecordChannel1].Selection;
device.PlayerChannel2 = _SelectSlides[_SelectSlideRecordChannel2].Selection; device.PlayerChannel2 = _SelectSlides[_SelectSlideRecordChannel2].Selection;
_SetPlayerColors();
} }
private void _UpdateChannels() private void _UpdateChannels()
@@ -459,6 +468,7 @@ namespace Vocaluxe.Screens
_SelectSlides[_SelectSlideRecordChannel2].Selection = _Devices[_DeviceNr].PlayerChannel2; _SelectSlides[_SelectSlideRecordChannel2].Selection = _Devices[_DeviceNr].PlayerChannel2;
_SaveMicConfig(); _SaveMicConfig();
_SetPlayerColors();
} }
private bool _CheckMicConfig() private bool _CheckMicConfig()