mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-27 00:07:58 +01:00
Replace #define UNIX_KEY_BINDINGS with conditional PlatformID.Unix.
This commit is contained in:
@@ -1,7 +1,3 @@
|
||||
#define UNIX_KEY_BINDINGS
|
||||
|
||||
using System.Net.Mime;
|
||||
|
||||
namespace Terminal.Gui;
|
||||
|
||||
/// <summary>
|
||||
@@ -126,8 +122,12 @@ public partial class Toplevel : View
|
||||
KeyBindings.Add (Application.AlternateForwardKey, Command.NextViewOrTop); // Needed on Unix
|
||||
KeyBindings.Add (Application.AlternateBackwardKey, Command.PreviousViewOrTop); // Needed on Unix
|
||||
|
||||
if (Environment.OSVersion.Platform == PlatformID.Unix)
|
||||
{
|
||||
KeyBindings.Add (Key.Z.WithCtrl, Command.Suspend);
|
||||
}
|
||||
|
||||
#if UNIX_KEY_BINDINGS
|
||||
KeyBindings.Add (Key.Z.WithCtrl, Command.Suspend);
|
||||
KeyBindings.Add (Key.L.WithCtrl, Command.Refresh); // Unix
|
||||
KeyBindings.Add (Key.F.WithCtrl, Command.NextView); // Unix
|
||||
KeyBindings.Add (Key.I.WithCtrl, Command.NextView); // Unix
|
||||
|
||||
Reference in New Issue
Block a user