Deleted some unused code.

This commit is contained in:
the_fiddler 2007-11-06 13:37:42 +00:00
parent ffadaeb024
commit 2520233f26

View file

@ -14,8 +14,6 @@ namespace OpenTK
{ {
class TexturePacker<T> where T : IPackable<T> class TexturePacker<T> where T : IPackable<T>
{ {
//Dictionary<T, Node> items = new Dictionary<T, Node>();
Node root; Node root;
#region --- Constructors --- #region --- Constructors ---
@ -59,32 +57,11 @@ namespace OpenTK
//items.Add(item, node); //items.Add(item, node);
return node.Rect; return node.Rect;
} }
throw new ArgumentException("The item already exists in the TexturePacker.", "item"); //throw new ArgumentException("The item already exists in the TexturePacker.", "item");
} }
#endregion #endregion
#region public bool Find(T item, out Rectangle rect)
/// <summary>
/// Searches for the item given and returns its bounding rectangle if it exists.
/// </summary>
/// <param name="item">The item to search for.</param>
/// <param name="rect">The bounding box of the item, if the item exists.</param>
/// <returns>True if the item exists, false otherwise.</returns>
//public bool Find(T item, out Rectangle rect)
//{
// Node node;
// bool found = items.TryGetValue(item, out node);
// if (found)
// rect = node.Rect;
// else
// rect = new Rectangle();
// return found;
//}
#endregion
#region public void Clear() #region public void Clear()
/// <summary> /// <summary>
@ -109,8 +86,7 @@ namespace OpenTK
/// <seealso cref="Clear"/> /// <seealso cref="Clear"/>
public void ChangeSize(int new_width, int new_height) public void ChangeSize(int new_width, int new_height)
{ {
Clear(); throw new NotImplementedException();
root.Rect = new Rectangle(0, 0, new_width, new_height);
} }
#endregion #endregion