Corrected NRE in X11Keyboard

This commit is contained in:
the_fiddler 2007-08-05 16:54:14 +00:00
parent 3974dbde8e
commit 3e47153aa4
3 changed files with 5 additions and 5 deletions

View file

@ -31,8 +31,8 @@ namespace OpenTK.Platform.Windows
public override string ToString() public override string ToString()
{ {
return String.Format("Windows.WindowInfo: Handle {0}{1} Parent {2}", return String.Format("Windows.WindowInfo: Handle {0}, Parent {1}",
this.Handle, System.Environment.NewLine, this.Parent != null ? this.Parent.ToString() : "null"); this.Handle, this.Parent != null ? this.Parent.ToString() : "null");
} }
} }

View file

@ -34,8 +34,8 @@ namespace OpenTK.Platform.X11
public override string ToString() public override string ToString()
{ {
return String.Format("X11.WindowInfo: Display {0}, Screen {1}, Handle {2}{3} Parent {4}", return String.Format("X11.WindowInfo: Display {0}, Screen {1}, Handle {2}, Parent {3}",
this.Display, this.Screen, this.Handle, System.Environment.NewLine, this.Parent != null ? this.Parent.ToString() : "null"); this.Display, this.Screen, this.Handle, this.Parent != null ? this.Parent.ToString() : "null");
} }
} }
} }

View file

@ -19,7 +19,7 @@ namespace OpenTK.Platform.X11
WindowInfo window; WindowInfo window;
private bool[] keys = new bool[(int)OpenTK.Input.Key.MaxKeys]; private bool[] keys = new bool[(int)OpenTK.Input.Key.MaxKeys];
private List<Keyboard> keyboards; private List<Keyboard> keyboards = new List<Keyboard>();
private static Dictionary<XKey, Key> keymap = new Dictionary<XKey, Key>((int)Key.MaxKeys); private static Dictionary<XKey, Key> keymap = new Dictionary<XKey, Key>((int)Key.MaxKeys);
/// <summary> /// <summary>
/// The smallest and largest KeyCode supported by the X server. Queried through API.DisplayKeycodes() /// The smallest and largest KeyCode supported by the X server. Queried through API.DisplayKeycodes()