mirror of
https://github.com/Ryujinx/Opentk.git
synced 2024-12-26 04:05:36 +00:00
Moved GraphicsContext creation to the HandleCreated event.
This commit is contained in:
parent
b2b9cd1353
commit
d9143c7654
|
@ -15,14 +15,16 @@ namespace OpenTK.Platform
|
|||
/// An empty IGraphicsContext implementation to be used inside the Visual Studio designer.
|
||||
/// This class supports OpenTK, and is not intended for use by OpenTK programs.
|
||||
/// </summary>
|
||||
internal sealed class DummyGLContext : IGraphicsContext
|
||||
internal sealed class DummyGLContext : IGraphicsContext, IGraphicsContextInternal
|
||||
{
|
||||
GraphicsMode format;
|
||||
bool vsync;
|
||||
static int dummy_context_count = 0;
|
||||
IntPtr context;
|
||||
|
||||
#region --- Constructors ---
|
||||
|
||||
public DummyGLContext(GraphicsMode format) { this.format = format; }
|
||||
public DummyGLContext(GraphicsMode format) { this.format = format; context = new IntPtr(dummy_context_count++); }
|
||||
|
||||
#endregion
|
||||
|
||||
|
@ -65,5 +67,18 @@ namespace OpenTK.Platform
|
|||
public void Dispose() { }
|
||||
|
||||
#endregion
|
||||
|
||||
#region IGraphicsContextInternal Members
|
||||
|
||||
public void LoadAll()
|
||||
{
|
||||
}
|
||||
|
||||
ContextHandle IGraphicsContextInternal.Context
|
||||
{
|
||||
get { return context; }
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue