mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-06 23:15:18 +00:00
Abstract GSFrameBase class and callback
This commit is contained in:
parent
50b5d72bb2
commit
84c5899faf
7 changed files with 94 additions and 109 deletions
|
|
@ -12,10 +12,49 @@ GLGSFrame::GLGSFrame()
|
|||
canvas->Bind(wxEVT_LEFT_DCLICK, &GSFrame::OnLeftDclick, this);
|
||||
}
|
||||
|
||||
void GLGSFrame::Flip(wxGLContext *context)
|
||||
GLGSFrame::~GLGSFrame()
|
||||
{
|
||||
}
|
||||
|
||||
void GLGSFrame::Close()
|
||||
{
|
||||
GSFrame::Close();
|
||||
}
|
||||
|
||||
bool GLGSFrame::IsShown()
|
||||
{
|
||||
return GSFrame::IsShown();
|
||||
}
|
||||
|
||||
void GLGSFrame::Hide()
|
||||
{
|
||||
GSFrame::Hide();
|
||||
}
|
||||
|
||||
void GLGSFrame::Show()
|
||||
{
|
||||
GSFrame::Show();
|
||||
}
|
||||
|
||||
void* GLGSFrame::GetNewContext()
|
||||
{
|
||||
return new wxGLContext(GetCanvas());
|
||||
}
|
||||
|
||||
void GLGSFrame::SetCurrent(void* ctx)
|
||||
{
|
||||
GetCanvas()->SetCurrent(*(wxGLContext*)ctx);
|
||||
}
|
||||
|
||||
void GLGSFrame::DeleteContext(void* ctx)
|
||||
{
|
||||
delete (wxGLContext*)ctx;
|
||||
}
|
||||
|
||||
void GLGSFrame::Flip(void* context)
|
||||
{
|
||||
if (!canvas) return;
|
||||
canvas->SetCurrent(*context);
|
||||
canvas->SetCurrent(*(wxGLContext*)context);
|
||||
|
||||
static Timer fps_t;
|
||||
canvas->SwapBuffers();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue