mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
linux build quick fix
This commit is contained in:
parent
5a31cc35ba
commit
81a2f95279
7 changed files with 3841 additions and 3828 deletions
|
@ -299,6 +299,7 @@ void bf::System::Console::PutChar(char c)
|
||||||
|
|
||||||
void bf::System::Console::ReopenHandles()
|
void bf::System::Console::ReopenHandles()
|
||||||
{
|
{
|
||||||
|
#ifdef _MSC_VER
|
||||||
FILE* fDummy;
|
FILE* fDummy;
|
||||||
freopen_s(&fDummy, "CONOUT$", "w", stdout);
|
freopen_s(&fDummy, "CONOUT$", "w", stdout);
|
||||||
freopen_s(&fDummy, "CONOUT$", "w", stderr);
|
freopen_s(&fDummy, "CONOUT$", "w", stderr);
|
||||||
|
@ -310,6 +311,7 @@ void bf::System::Console::ReopenHandles()
|
||||||
SetStdHandle(STD_OUTPUT_HANDLE, hConOut);
|
SetStdHandle(STD_OUTPUT_HANDLE, hConOut);
|
||||||
SetStdHandle(STD_ERROR_HANDLE, hConOut);
|
SetStdHandle(STD_ERROR_HANDLE, hConOut);
|
||||||
SetStdHandle(STD_INPUT_HANDLE, hConIn);
|
SetStdHandle(STD_INPUT_HANDLE, hConIn);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void bf::System::Runtime::Init(int version, int flags, BfRtCallbacks* callbacks)
|
void bf::System::Runtime::Init(int version, int flags, BfRtCallbacks* callbacks)
|
||||||
|
|
7634
IDE/src/IDEApp.bf
7634
IDE/src/IDEApp.bf
File diff suppressed because it is too large
Load diff
|
@ -14,7 +14,7 @@ using System.Threading;
|
||||||
using IDE.util;
|
using IDE.util;
|
||||||
|
|
||||||
namespace IDE.ui;
|
namespace IDE.ui;
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
class ConsolePanel : Panel
|
class ConsolePanel : Panel
|
||||||
{
|
{
|
||||||
class View : Widget
|
class View : Widget
|
||||||
|
@ -369,7 +369,9 @@ class ConsolePanel : Panel
|
||||||
|
|
||||||
public virtual void Init()
|
public virtual void Init()
|
||||||
{
|
{
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
mConsoleProvider = new WinNativeConsoleProvider();
|
mConsoleProvider = new WinNativeConsoleProvider();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void Serialize(StructuredData data)
|
public override void Serialize(StructuredData data)
|
||||||
|
@ -809,4 +811,5 @@ class ConsolePanel : Panel
|
||||||
{
|
{
|
||||||
mView.SetFocus();
|
mView.SetFocus();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
|
@ -83,8 +83,11 @@ namespace IDE.ui
|
||||||
data.GetString("Type", type);
|
data.GetString("Type", type);
|
||||||
Panel panel = null;
|
Panel panel = null;
|
||||||
|
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
if (type == "")
|
if (type == "")
|
||||||
return gApp.mTerminalPanel;
|
return gApp.mTerminalPanel;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
if (type == "CallStackPanel")
|
if (type == "CallStackPanel")
|
||||||
panel = gApp.mCallStackPanel;
|
panel = gApp.mCallStackPanel;
|
||||||
|
@ -97,8 +100,10 @@ namespace IDE.ui
|
||||||
panel = gApp.mOutputPanel;
|
panel = gApp.mOutputPanel;
|
||||||
}
|
}
|
||||||
else if (type == "TerminalPanel")
|
else if (type == "TerminalPanel")
|
||||||
{
|
{
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
panel = gApp.mTerminalPanel;
|
panel = gApp.mTerminalPanel;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
else if (type == "ImmediatePanel")
|
else if (type == "ImmediatePanel")
|
||||||
{
|
{
|
||||||
|
@ -167,12 +172,16 @@ namespace IDE.ui
|
||||||
panel = gApp.mBookmarksPanel;
|
panel = gApp.mBookmarksPanel;
|
||||||
}
|
}
|
||||||
else if (type == "TerminalPanel")
|
else if (type == "TerminalPanel")
|
||||||
{
|
{
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
panel = gApp.mTerminalPanel;
|
panel = gApp.mTerminalPanel;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
else if (type == "ConsolePanel")
|
else if (type == "ConsolePanel")
|
||||||
{
|
{
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
panel = gApp.mConsolePanel;
|
panel = gApp.mConsolePanel;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
if (panel != null)
|
if (panel != null)
|
||||||
|
|
|
@ -3047,8 +3047,10 @@ namespace IDE.ui
|
||||||
|
|
||||||
if (!path.IsWhiteSpace)
|
if (!path.IsWhiteSpace)
|
||||||
{
|
{
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
gApp.ShowTerminal();
|
gApp.ShowTerminal();
|
||||||
gApp.mTerminalPanel.OpenDirectory(path);
|
gApp.mTerminalPanel.OpenDirectory(path);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@ using Beefy.utils;
|
||||||
using IDE.util;
|
using IDE.util;
|
||||||
|
|
||||||
namespace IDE.ui;
|
namespace IDE.ui;
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
class TerminalPanel : ConsolePanel
|
class TerminalPanel : ConsolePanel
|
||||||
{
|
{
|
||||||
public override void Serialize(StructuredData data)
|
public override void Serialize(StructuredData data)
|
||||||
|
@ -57,4 +57,5 @@ class TerminalPanel : ConsolePanel
|
||||||
consoleProvider.Detach();
|
consoleProvider.Detach();
|
||||||
consoleProvider.Attach();
|
consoleProvider.Attach();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
|
@ -8,6 +8,7 @@ using System.IO;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
namespace IDE.util;
|
namespace IDE.util;
|
||||||
|
|
||||||
|
#if BF_PLATFORM_WINDOWS
|
||||||
class ConsoleProvider
|
class ConsoleProvider
|
||||||
{
|
{
|
||||||
public enum UpdateState
|
public enum UpdateState
|
||||||
|
@ -1324,4 +1325,5 @@ class BeefConConsoleProvider : ConsoleProvider
|
||||||
mPipe.Stream.Write((int32)dy);
|
mPipe.Stream.Write((int32)dy);
|
||||||
mPipe.EndMessage();
|
mPipe.EndMessage();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
Loading…
Add table
Add a link
Reference in a new issue