deactivated JumpTo (it has a bug and should be for version 0.2)
This commit is contained in:
1 parent
aca6087488
commit
3520545138
1 file changed
+34
-32
@@ -54,9 +54,16 @@ namespace Vocaluxe.Screens
|
|||||||
{
|
{
|
||||||
base.HandleInput(KeyEvent);
|
base.HandleInput(KeyEvent);
|
||||||
|
|
||||||
if (KeyEvent.KeyPressed && !Char.IsControl(KeyEvent.Unicode) && _SearchActive)
|
if (KeyEvent.KeyPressed && !Char.IsControl(KeyEvent.Unicode))
|
||||||
{
|
{
|
||||||
ApplyNewSearchFilter(_SearchText + KeyEvent.Unicode);
|
if (_SearchActive)
|
||||||
|
ApplyNewSearchFilter(_SearchText + KeyEvent.Unicode);
|
||||||
|
/*
|
||||||
|
else if (!Char.IsControl(KeyEvent.Unicode))
|
||||||
|
{
|
||||||
|
JumpTo(KeyEvent.Unicode);
|
||||||
|
return true;
|
||||||
|
}*/
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -65,12 +72,6 @@ namespace Vocaluxe.Screens
|
|||||||
if (KeyEvent.Handled)
|
if (KeyEvent.Handled)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
if (!Char.IsControl(KeyEvent.Unicode))
|
|
||||||
{
|
|
||||||
JumpTo(KeyEvent.Unicode);
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
switch (KeyEvent.Key)
|
switch (KeyEvent.Key)
|
||||||
{
|
{
|
||||||
case Keys.Escape:
|
case Keys.Escape:
|
||||||
@@ -107,31 +108,31 @@ namespace Vocaluxe.Screens
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
//case Keys.A:
|
case Keys.A:
|
||||||
// if (!_SearchActive && KeyEvent.Mod == Modifier.None)
|
if (!_SearchActive && KeyEvent.Mod == Modifier.None)
|
||||||
// {
|
{
|
||||||
// StartRandomAllSongs();
|
StartRandomAllSongs();
|
||||||
// }
|
}
|
||||||
// if (KeyEvent.Mod == Modifier.Ctrl)
|
if (KeyEvent.Mod == Modifier.Ctrl)
|
||||||
// {
|
{
|
||||||
// StartRandomVisibleSongs();
|
StartRandomVisibleSongs();
|
||||||
// }
|
}
|
||||||
// break;
|
break;
|
||||||
|
|
||||||
//case Keys.F:
|
case Keys.F:
|
||||||
// if (KeyEvent.Mod == Modifier.Ctrl){
|
if (KeyEvent.Mod == Modifier.Ctrl){
|
||||||
// if (_SearchActive)
|
if (_SearchActive)
|
||||||
// {
|
{
|
||||||
// _SearchActive = false;
|
_SearchActive = false;
|
||||||
// _SearchText = String.Empty;
|
_SearchText = String.Empty;
|
||||||
// ApplyNewSearchFilter(_SearchText);
|
ApplyNewSearchFilter(_SearchText);
|
||||||
// }
|
}
|
||||||
// else
|
else
|
||||||
// {
|
{
|
||||||
// _SearchActive = true;
|
_SearchActive = true;
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// break;
|
break;
|
||||||
|
|
||||||
case Keys.R:
|
case Keys.R:
|
||||||
if (CSongs.Category != -1 && KeyEvent.Mod == Modifier.Ctrl)
|
if (CSongs.Category != -1 && KeyEvent.Mod == Modifier.Ctrl)
|
||||||
@@ -303,6 +304,7 @@ namespace Vocaluxe.Screens
|
|||||||
id = CSongs.VisibleSongs[song].ID;
|
id = CSongs.VisibleSongs[song].ID;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// here is a fault: SetSelectedSong should point to the visible index
|
||||||
Vocaluxe.Lib.Song.CSong s = Array.Find<Vocaluxe.Lib.Song.CSong>(CSongs.VisibleSongs, element => element.Artist.StartsWith(Letter.ToString(), StringComparison.OrdinalIgnoreCase));
|
Vocaluxe.Lib.Song.CSong s = Array.Find<Vocaluxe.Lib.Song.CSong>(CSongs.VisibleSongs, element => element.Artist.StartsWith(Letter.ToString(), StringComparison.OrdinalIgnoreCase));
|
||||||
if (s != null && s.ID > -1)
|
if (s != null && s.ID > -1)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in new issue
Block a user