mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 15:22:15 +00:00
Hopefully I'm using OF_Fixed correctly
This commit is contained in:
parent
35ec14f465
commit
890166a732
1 changed files with 6 additions and 0 deletions
|
@ -16,6 +16,7 @@ bool E_RegisterHandler(DStaticEventHandler* handler)
|
|||
if (handler->next)
|
||||
handler->next->prev = handler;
|
||||
E_FirstEventHandler = handler;
|
||||
if (handler->IsStatic()) handler->ObjectFlags |= OF_Fixed;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -32,6 +33,11 @@ bool E_UnregisterHandler(DStaticEventHandler* handler)
|
|||
handler->next->prev = handler->prev;
|
||||
if (handler == E_FirstEventHandler)
|
||||
E_FirstEventHandler = handler->next;
|
||||
if (handler->IsStatic())
|
||||
{
|
||||
handler->ObjectFlags |= OF_YesReallyDelete;
|
||||
delete handler;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue