Move hardcoded static asset browser hotkeys to yaml.
This commit is contained in:
@@ -149,7 +149,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
var playButton = panel.GetOrNull<ButtonWidget>("BUTTON_PLAY");
|
||||
if (playButton != null)
|
||||
{
|
||||
playButton.Key = new Hotkey(Keycode.SPACE, Modifiers.None);
|
||||
playButton.OnClick = () =>
|
||||
{
|
||||
if (isVideoLoaded)
|
||||
@@ -164,7 +163,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
var pauseButton = panel.GetOrNull<ButtonWidget>("BUTTON_PAUSE");
|
||||
if (pauseButton != null)
|
||||
{
|
||||
pauseButton.Key = new Hotkey(Keycode.SPACE, Modifiers.None);
|
||||
pauseButton.OnClick = () =>
|
||||
{
|
||||
if (isVideoLoaded)
|
||||
@@ -179,7 +177,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
var stopButton = panel.GetOrNull<ButtonWidget>("BUTTON_STOP");
|
||||
if (stopButton != null)
|
||||
{
|
||||
stopButton.Key = new Hotkey(Keycode.RETURN, Modifiers.None);
|
||||
stopButton.OnClick = () =>
|
||||
{
|
||||
if (isVideoLoaded)
|
||||
@@ -196,7 +193,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
var nextButton = panel.GetOrNull<ButtonWidget>("BUTTON_NEXT");
|
||||
if (nextButton != null)
|
||||
{
|
||||
nextButton.Key = new Hotkey(Keycode.RIGHT, Modifiers.None);
|
||||
nextButton.OnClick = () =>
|
||||
{
|
||||
if (!isVideoLoaded)
|
||||
@@ -209,7 +205,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
var prevButton = panel.GetOrNull<ButtonWidget>("BUTTON_PREV");
|
||||
if (prevButton != null)
|
||||
{
|
||||
prevButton.Key = new Hotkey(Keycode.LEFT, Modifiers.None);
|
||||
prevButton.OnClick = () =>
|
||||
{
|
||||
if (!isVideoLoaded)
|
||||
|
||||
Reference in New Issue
Block a user