Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added lots of ui functionality #1

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
8 changes: 1 addition & 7 deletions About.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Windows.Forms;

namespace NBTExplorer
{
Expand Down
32 changes: 32 additions & 0 deletions DataNode.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
namespace NBTExplorer
{
public class DataNode
{
public DataNode()
{
}

public DataNode(DataNode parent)
{
Parent = parent;
}

public DataNode Parent { get; set; }

private bool _modified;
public bool Modified
{
get { return _modified; }
set
{
if (value && Parent != null)
{
Parent.Modified = value;
}
_modified = value;
}
}

public bool Expanded { get; set; }
}
}
18 changes: 18 additions & 0 deletions DirectoryData.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
namespace NBTExplorer
{
public class DirectoryData : DataNode
{
public DirectoryData(string path)
: this(null, path)
{
}

public DirectoryData(DataNode parent, string path)
: base(parent)
{
Path = path;
}

public string Path { get; private set; }
}
}
14 changes: 5 additions & 9 deletions EditValue.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Collections.Generic;
using System.Windows.Forms;
using Substrate.Nbt;

Expand All @@ -17,11 +13,11 @@ public enum EditValueType

public partial class EditValue : Form
{
private string _name;
private TagNode _tag;
private EditValueType _type;
string _name;
readonly TagNode _tag;
readonly EditValueType _type;

private List<string> _invalidNames = new List<string>();
readonly List<string> _invalidNames = new List<string>();

public EditValue (TagNode tag)
{
Expand Down
7 changes: 1 addition & 6 deletions Find.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,4 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System;
using System.Windows.Forms;

namespace NBTExplorer
Expand Down
1,222 changes: 629 additions & 593 deletions Form1.Designer.cs

Large diffs are not rendered by default.

Loading