mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-25 02:58:02 +02:00
Initial console support
This commit is contained in:
parent
45a5978611
commit
186c2125fa
21 changed files with 1244 additions and 29 deletions
|
@ -242,7 +242,7 @@ namespace IDE.ui
|
|||
{
|
||||
base.KeyDown(keyCode, isRepeat);
|
||||
|
||||
if ((keyCode == (.)'C') && (mWidgetWindow.GetKeyFlags() == .Ctrl))
|
||||
if ((keyCode == (.)'C') && (mWidgetWindow.GetKeyFlags(true) == .Ctrl))
|
||||
{
|
||||
String versionInfo = scope String();
|
||||
versionInfo.AppendF("Beef IDE Version {}", gApp.mVersionInfo.FileVersion);
|
||||
|
|
1031
IDE/src/ui/ConsolePanel.bf
Normal file
1031
IDE/src/ui/ConsolePanel.bf
Normal file
File diff suppressed because it is too large
Load diff
|
@ -83,6 +83,9 @@ namespace IDE.ui
|
|||
data.GetString("Type", type);
|
||||
Panel panel = null;
|
||||
|
||||
if (type == "")
|
||||
return gApp.mTerminalPanel;
|
||||
|
||||
if (type == "CallStackPanel")
|
||||
panel = gApp.mCallStackPanel;
|
||||
else if (type == "BreakpointPanel")
|
||||
|
@ -93,6 +96,10 @@ namespace IDE.ui
|
|||
{
|
||||
panel = gApp.mOutputPanel;
|
||||
}
|
||||
else if (type == "TerminalPanel")
|
||||
{
|
||||
panel = gApp.mTerminalPanel;
|
||||
}
|
||||
else if (type == "ImmediatePanel")
|
||||
{
|
||||
panel = gApp.mImmediatePanel;
|
||||
|
@ -159,6 +166,14 @@ namespace IDE.ui
|
|||
{
|
||||
panel = gApp.mBookmarksPanel;
|
||||
}
|
||||
else if (type == "TerminalPanel")
|
||||
{
|
||||
panel = gApp.mTerminalPanel;
|
||||
}
|
||||
else if (type == "ConsolePanel")
|
||||
{
|
||||
panel = gApp.mConsolePanel;
|
||||
}
|
||||
|
||||
if (panel != null)
|
||||
{
|
||||
|
|
|
@ -2375,7 +2375,7 @@ namespace IDE.ui
|
|||
|
||||
base.KeyDown(keyCode, isRepeat);
|
||||
|
||||
if (mWidgetWindow.GetKeyFlags() == .Ctrl)
|
||||
if (mWidgetWindow.GetKeyFlags(true) == .Ctrl)
|
||||
{
|
||||
switch (keyCode)
|
||||
{
|
||||
|
@ -2388,7 +2388,7 @@ namespace IDE.ui
|
|||
default:
|
||||
}
|
||||
}
|
||||
else if (mWidgetWindow.GetKeyFlags() == .None)
|
||||
else if (mWidgetWindow.GetKeyFlags(true) == .None)
|
||||
{
|
||||
if (keyCode == KeyCode.Delete)
|
||||
RemoveSelectedItems();
|
||||
|
|
|
@ -394,7 +394,7 @@ namespace IDE.ui
|
|||
{
|
||||
var focusedListViewItem = GetRoot().FindFocusedItem();
|
||||
|
||||
bool changeFocus = (keyCode == .Tab) && (mWidgetWindow.GetKeyFlags() == .None);
|
||||
bool changeFocus = (keyCode == .Tab) && (mWidgetWindow.GetKeyFlags(true) == .None);
|
||||
if ((keyCode == .Right) && ((focusedListViewItem == null) || (focusedListViewItem.GetChildCount() == 0)))
|
||||
changeFocus = true;
|
||||
|
||||
|
@ -454,7 +454,7 @@ namespace IDE.ui
|
|||
{
|
||||
var propertiesDialog = (PropertiesDialog)mParent;
|
||||
|
||||
let keyFlags = mWidgetWindow.GetKeyFlags();
|
||||
let keyFlags = mWidgetWindow.GetKeyFlags(true);
|
||||
bool changeFocus = (keyCode == .Tab) && (keyFlags == .Shift);
|
||||
if (keyCode == .Left)
|
||||
{
|
||||
|
|
24
IDE/src/ui/TerminalPanel.bf
Normal file
24
IDE/src/ui/TerminalPanel.bf
Normal file
|
@ -0,0 +1,24 @@
|
|||
#pragma warning disable 168
|
||||
|
||||
using System;
|
||||
using Beefy.geom;
|
||||
using Beefy.gfx;
|
||||
using System.Text;
|
||||
using Beefy.theme.dark;
|
||||
using System.Security.Cryptography;
|
||||
using Beefy.widgets;
|
||||
using Beefy.events;
|
||||
using System.Diagnostics;
|
||||
using Beefy.utils;
|
||||
|
||||
namespace IDE.ui;
|
||||
|
||||
class TerminalPanel : Panel
|
||||
{
|
||||
public override void Serialize(StructuredData data)
|
||||
{
|
||||
base.Serialize(data);
|
||||
|
||||
data.Add("Type", "TerminalPanel");
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue