Merge pull request #6281 from mizipzor/tab-completion
Added tab completion to in-game and lobby chat.
This commit is contained in:
@@ -30,6 +30,7 @@ namespace OpenRA.Widgets
|
||||
public Func<bool> OnEnterKey = () => false;
|
||||
public Func<bool> OnTabKey = () => false;
|
||||
public Func<bool> OnEscKey = () => false;
|
||||
public Func<bool> OnAltKey = () => false;
|
||||
public Action OnLoseFocus = () => { };
|
||||
public Action OnTextEdited = () => { };
|
||||
public int CursorPosition { get; set; }
|
||||
@@ -121,6 +122,9 @@ namespace OpenRA.Widgets
|
||||
if (e.Key == Keycode.ESCAPE && OnEscKey())
|
||||
return true;
|
||||
|
||||
if (e.Key == Keycode.LALT && OnAltKey())
|
||||
return true;
|
||||
|
||||
if (e.Key == Keycode.LEFT)
|
||||
{
|
||||
if (CursorPosition > 0)
|
||||
|
||||
Reference in New Issue
Block a user