mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-20 08:58:00 +02:00
Initial checkin
This commit is contained in:
parent
c74712dad9
commit
078564ac9e
3242 changed files with 1616395 additions and 0 deletions
48
IDE/src/ui/MainFrame.bf
Normal file
48
IDE/src/ui/MainFrame.bf
Normal file
|
@ -0,0 +1,48 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Beefy;
|
||||
using Beefy.gfx;
|
||||
using Beefy.widgets;
|
||||
using Beefy.theme;
|
||||
using Beefy.theme.dark;
|
||||
|
||||
namespace IDE.ui
|
||||
{
|
||||
public class MainFrame : Widget
|
||||
{
|
||||
public StatusBar mStatusBar;
|
||||
public DarkDockingFrame mDockingFrame;
|
||||
|
||||
public this()
|
||||
{
|
||||
mStatusBar = new StatusBar();
|
||||
AddWidget(mStatusBar);
|
||||
mDockingFrame = (DarkDockingFrame)ThemeFactory.mDefault.CreateDockingFrame();
|
||||
AddWidget(mDockingFrame);
|
||||
}
|
||||
|
||||
public void Reset()
|
||||
{
|
||||
mDockingFrame.RemoveSelf();
|
||||
gApp.DeferDelete(mDockingFrame);
|
||||
mDockingFrame = (DarkDockingFrame)ThemeFactory.mDefault.CreateDockingFrame();
|
||||
AddWidget(mDockingFrame);
|
||||
|
||||
RehupSize();
|
||||
}
|
||||
|
||||
public ~this()
|
||||
{
|
||||
}
|
||||
|
||||
public override void Resize(float x, float y, float width, float height)
|
||||
{
|
||||
base.Resize(x, y, width, height);
|
||||
int32 statusHeight = GS!(20);
|
||||
mDockingFrame.Resize(0, 0, width, height - statusHeight);
|
||||
mStatusBar.Resize(0, mHeight - statusHeight, width, statusHeight);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue