Fixed build warnings.

This commit is contained in:
the_fiddler 2008-12-09 10:06:25 +00:00
parent e6303e9e5b
commit 057759177b
4 changed files with 28 additions and 21 deletions

View file

@ -66,6 +66,8 @@ namespace OpenTK.Platform.Windows
currentWindow = (WinWindowInfo)window;
if (currentWindow.WindowHandle == IntPtr.Zero) throw new ArgumentException("window", "Must be a valid window.");
this.format = format;
Debug.Print("OpenGL will be bound to handle: {0}", currentWindow.WindowHandle);
Debug.Write("Setting pixel format... ");
@ -110,7 +112,7 @@ namespace OpenTK.Platform.Windows
public void CreateContext()
{
throw new NotSupportedException();
this.CreateContext(true, null);
//this.CreateContext(true, null);
}
#endregion
@ -120,7 +122,7 @@ namespace OpenTK.Platform.Windows
public void CreateContext(bool direct)
{
throw new NotSupportedException();
this.CreateContext(direct, null);
//this.CreateContext(direct, null);
}
#endregion

View file

@ -40,13 +40,13 @@ namespace OpenTK.Platform.Windows
private WindowState windowState = WindowState.Normal;
private int top, bottom, left, right;
private int width = 0, height = 0;
//private int width = 0, height = 0;
private Rectangle previous_client_area;
private Point position = new Point();
private Rectangle client_rectangle = new Rectangle();
private Size window_size = new Size();
private Rectangle borders = new Rectangle();
//private Rectangle borders = new Rectangle();
private ResizeEventArgs resizeEventArgs = new ResizeEventArgs();
@ -603,10 +603,13 @@ namespace OpenTK.Platform.Windows
#region public void OnResize
public event ResizeEvent Resize = null;
public event ResizeEvent Resize;
public void OnResize(ResizeEventArgs e)
{
if (Resize != null)
Resize(this, e);
throw new NotImplementedException("Use GameWindow.OnResize instead.");
//this.width = e.Width;
//this.height = e.Height;

View file

@ -57,7 +57,7 @@ namespace OpenTK.Platform.X11
static int screenCount;
internal static Display DefaultDisplay { get { return defaultDisplay; } }
//internal static int DefaultScreen { get { return defaultScreen; } }
static int DefaultScreen { get { return defaultScreen; } }
//internal static Window RootWindow { get { return rootWindow; } }
internal static int ScreenCount { get { return screenCount; } }
@ -743,6 +743,8 @@ XF86VidModeGetGammaRampSize(
#region unsafe internal class XExtData
#pragma warning disable 0169, 0649
unsafe internal class XExtData
{
int number; /* number returned by XRegisterExtension */

View file

@ -61,16 +61,16 @@ namespace OpenTK.Platform.X11
IntPtr _atom_net_wm_action_maximize_horizontally;
IntPtr _atom_net_wm_action_maximize_vertically;
IntPtr _atom_motif_wm_hints;
IntPtr _atom_kde_wm_hints;
IntPtr _atom_kde_net_wm_hints;
//IntPtr _atom_motif_wm_hints;
//IntPtr _atom_kde_wm_hints;
//IntPtr _atom_kde_net_wm_hints;
static readonly IntPtr _atom_remove = (IntPtr)0;
static readonly IntPtr _atom_add = (IntPtr)1;
static readonly IntPtr _atom_toggle = (IntPtr)2;
// Number of pending events.
int pending = 0;
//int pending = 0;
int width, height;
int top, bottom, left, right;
@ -86,11 +86,11 @@ namespace OpenTK.Platform.X11
bool isExiting;
// XAtoms for window properties
static IntPtr WMTitle; // The title of the GameWindow.
static IntPtr UTF8String; // No idea.
//static IntPtr WMTitle; // The title of the GameWindow.
//static IntPtr UTF8String; // No idea.
// Fields used for fullscreen mode changes.
int pre_fullscreen_width, pre_fullscreen_height;
//int pre_fullscreen_width, pre_fullscreen_height;
//bool fullscreen = false;
bool _decorations_hidden = false;
@ -646,7 +646,7 @@ namespace OpenTK.Platform.X11
IntPtr bytes_after;
IntPtr prop = IntPtr.Zero;
IntPtr atom;
XWindowAttributes attributes;
//XWindowAttributes attributes;
bool fullscreen = false;
int maximized = 0;
bool minimized = false;
@ -995,7 +995,7 @@ namespace OpenTK.Platform.X11
IntPtr bytes_after;
IntPtr prop = IntPtr.Zero;
IntPtr atom;
XWindowAttributes attributes;
//XWindowAttributes attributes;
Functions.XGetWindowProperty(window.Display, window.WindowHandle,
_atom_net_wm_allowed_actions, IntPtr.Zero, new IntPtr(256), false,
@ -1023,13 +1023,13 @@ namespace OpenTK.Platform.X11
{
get
{
IntPtr actual_atom;
int actual_format;
IntPtr nitems;
IntPtr bytes_after;
//IntPtr actual_atom;
//int actual_format;
//IntPtr nitems;
//IntPtr bytes_after;
IntPtr prop = IntPtr.Zero;
IntPtr atom;
XWindowAttributes attributes;
//IntPtr atom;
//XWindowAttributes attributes;
// Test if decorations have been disabled through Motif.
IntPtr motif_hints_atom = Functions.XInternAtom(this.window.Display, MOTIF_WM_ATOM, true);