reactosdbg/RosDBG/HostWindow.cs
Art Yerkes 6030ecd415 A debugging shell for use with KDBG. Not perfect yet but it can display the
locals and stack trace at the place where reactos is stopped.

svn path=/trunk/tools/reactosdbg/; revision=759
2008-07-31 07:00:10 +00:00

61 lines
1.7 KiB
C#

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace RosDBG
{
public partial class HostWindow : Form
{
public HostWindow()
{
InitializeComponent();
}
public delegate void RedockControlEventHandler(object sender, RedockControlEventArgs args);
public event RedockControlEventHandler RedockControlEvent;
public Control Content
{
get
{
if (ContentSplitter.Panel2.Controls.Count > 0)
return ContentSplitter.Panel2.Controls[0];
else
return null;
}
set
{
ContentSplitter.Panel2.Controls.Clear();
if (value != null)
ContentSplitter.Panel2.Controls.Add(value);
}
}
private void redockToolStripMenuItem_Click(object sender, EventArgs e)
{
RedockControlEventArgs args = new RedockControlEventArgs(Content);
Content = null;
if (RedockControlEvent != null)
RedockControlEvent(this, args);
Close();
}
private void closeToolStripMenuItem_Click(object sender, EventArgs e)
{
Close();
}
}
public class RedockControlEventArgs : EventArgs
{
Control mControl;
public Control Control { get { return mControl; } }
public RedockControlEventArgs(Control ctrl) { mControl = ctrl; }
}
}