diff --git a/BizHawk.Client.Common/movie/bk2/StringLogs.cs b/BizHawk.Client.Common/movie/bk2/StringLogs.cs index b2a32559c7..6478b8a63a 100644 --- a/BizHawk.Client.Common/movie/bk2/StringLogs.cs +++ b/BizHawk.Client.Common/movie/bk2/StringLogs.cs @@ -19,7 +19,9 @@ namespace BizHawk.Client.Common if (DefaultToAWE) { - return new StreamStringLog(false); + return OSTailoredCode.IsUnixHost + ? throw new InvalidOperationException("logging to AWE is only available on Windows for now") + : new StreamStringLog(false); } return new ListStringLog(); diff --git a/BizHawk.Client.EmuHawk/CustomControls/FolderBrowserDialogEx.cs b/BizHawk.Client.EmuHawk/CustomControls/FolderBrowserDialogEx.cs index 25167cee17..5861d8da7b 100644 --- a/BizHawk.Client.EmuHawk/CustomControls/FolderBrowserDialogEx.cs +++ b/BizHawk.Client.EmuHawk/CustomControls/FolderBrowserDialogEx.cs @@ -15,7 +15,7 @@ namespace BizHawk.Client.EmuHawk /// Component wrapping access to the Browse For Folder common dialog box. /// Call the ShowDialog() method to bring the dialog box up. /// - public sealed class FolderBrowserEx : Component + public sealed class FolderBrowserEx : Component //TODO inherit CommonDialog { private const int MAX_PATH = 260; diff --git a/BizHawk.Client.EmuHawk/MainForm.Designer.cs b/BizHawk.Client.EmuHawk/MainForm.Designer.cs index 85cb5efd7f..7627bf5948 100644 --- a/BizHawk.Client.EmuHawk/MainForm.Designer.cs +++ b/BizHawk.Client.EmuHawk/MainForm.Designer.cs @@ -2865,6 +2865,7 @@ this.GBASubMenu.Name = "GBASubMenu"; this.GBASubMenu.Size = new System.Drawing.Size(39, 17); this.GBASubMenu.Text = "GBA"; + this.GBASubMenu.DropDownOpened += new System.EventHandler(this.GBASubMenu_DropDownOpened); // // GBACoreSelectionSubMenu // diff --git a/BizHawk.Client.EmuHawk/MainForm.Events.cs b/BizHawk.Client.EmuHawk/MainForm.Events.cs index 325f737f92..ca599666b6 100644 --- a/BizHawk.Client.EmuHawk/MainForm.Events.cs +++ b/BizHawk.Client.EmuHawk/MainForm.Events.cs @@ -284,11 +284,12 @@ namespace BizHawk.Client.EmuHawk StopAVIMenuItem.ShortcutKeyDisplayString = Config.HotkeyBindings["Stop A/V"].Bindings; CaptureOSDMenuItem.Checked = Config.AVI_CaptureOSD; - RecordAVMenuItem.Enabled = !string.IsNullOrEmpty(Config.VideoWriter) && _currAviWriter == null; + RecordAVMenuItem.Enabled = OSTailoredCode.IsUnixHost || !string.IsNullOrEmpty(Global.Config.VideoWriter) && _currAviWriter == null; + SynclessRecordingMenuItem.Enabled = !OSTailoredCode.IsUnixHost; if (_currAviWriter == null) { - ConfigAndRecordAVMenuItem.Enabled = true; + ConfigAndRecordAVMenuItem.Enabled = !OSTailoredCode.IsUnixHost; StopAVIMenuItem.Enabled = false; } else @@ -751,6 +752,8 @@ namespace BizHawk.Client.EmuHawk DisplayLagCounterMenuItem.Enabled = Emulator.CanPollInput(); DisplayMessagesMenuItem.Checked = Config.DisplayMessages; + + DisplayLogWindowMenuItem.Enabled = !OSTailoredCode.IsUnixHost; } private void WindowSizeSubMenu_DropDownOpened(object sender, EventArgs e) @@ -2108,6 +2111,7 @@ namespace BizHawk.Client.EmuHawk private void GBSubMenu_DropDownOpened(object sender, EventArgs e) { LoadGBInSGBMenuItem.Checked = Config.GB_AsSGB; + GBGPUViewerMenuItem.Enabled = !OSTailoredCode.IsUnixHost; } private void GBCoreSettingsMenuItem_Click(object sender, EventArgs e) @@ -2168,6 +2172,11 @@ namespace BizHawk.Client.EmuHawk FlagNeedsReboot(); } + private void GBASubMenu_DropDownOpened(object sender, EventArgs e) + { + GbaGpuViewerMenuItem.Enabled = !OSTailoredCode.IsUnixHost; + } + private void GBACoreSelectionSubMenu_DropDownOpened(object sender, EventArgs e) { GBAmGBAMenuItem.Checked = Config.GBA_UsemGBA; @@ -2231,6 +2240,7 @@ namespace BizHawk.Client.EmuHawk } SNESControllerConfigurationMenuItem.Enabled = !MovieSession.Movie.IsActive; + SnesGfxDebuggerMenuItem.Enabled = !OSTailoredCode.IsUnixHost; } private void SNESControllerConfigurationMenuItem_Click(object sender, EventArgs e) diff --git a/BizHawk.Client.EmuHawk/MainForm.Hotkey.cs b/BizHawk.Client.EmuHawk/MainForm.Hotkey.cs index b75d64bb23..44034f238a 100644 --- a/BizHawk.Client.EmuHawk/MainForm.Hotkey.cs +++ b/BizHawk.Client.EmuHawk/MainForm.Hotkey.cs @@ -1,4 +1,6 @@ using System.Linq; + +using BizHawk.Common; using BizHawk.Emulation.Common.IEmulatorExtensions; using BizHawk.Emulation.Cores.Nintendo.Gameboy; @@ -102,7 +104,8 @@ namespace BizHawk.Client.EmuHawk _exitRequestPending = true; break; case "Record A/V": - RecordAv(); + if (OSTailoredCode.IsUnixHost) GlobalWin.OSD.AddMessage("(A/V only available on Windows for now)"); + else RecordAv(); break; case "Stop A/V": StopAv(); diff --git a/BizHawk.Client.EmuHawk/MainForm.cs b/BizHawk.Client.EmuHawk/MainForm.cs index cc9dda8021..2d4724b920 100644 --- a/BizHawk.Client.EmuHawk/MainForm.cs +++ b/BizHawk.Client.EmuHawk/MainForm.cs @@ -223,7 +223,7 @@ namespace BizHawk.Client.EmuHawk InitializeComponent(); SetImages(); Game = GameInfo.NullInstance; - if (Config.ShowLogWindow) + if (Config.ShowLogWindow && !OSTailoredCode.IsUnixHost) { LogConsole.ShowConsole(); DisplayLogWindowMenuItem.Checked = true; @@ -493,7 +493,8 @@ namespace BizHawk.Client.EmuHawk // start dumping, if appropriate if (_argParser.cmdDumpType != null && _argParser.cmdDumpName != null) { - RecordAv(_argParser.cmdDumpType, _argParser.cmdDumpName); + if (OSTailoredCode.IsUnixHost) Console.WriteLine("A/V dump requires Win32 API calls, ignored"); + else RecordAv(_argParser.cmdDumpType, _argParser.cmdDumpName); } SetMainformMovieInfo(); @@ -511,7 +512,7 @@ namespace BizHawk.Client.EmuHawk public int ProgramRunLoop() { CheckMessages(); // can someone leave a note about why this is needed? - LogConsole.PositionConsole(); + if (!OSTailoredCode.IsUnixHost) LogConsole.PositionConsole(); // needs to be done late, after the log console snaps on top // fullscreen should snap on top even harder! @@ -3218,10 +3219,7 @@ namespace BizHawk.Client.EmuHawk /// private void RecordAvBase(string videoWriterName, string filename, bool unattended) { - if (_currAviWriter != null) - { - return; - } + if (_currAviWriter != null || OSTailoredCode.IsUnixHost) return; // select IVideoWriter to use IVideoWriter aw;