rodecomp/Source/Client/BrowserClose.cpp
2026-10-24 00:35:19 +00:00

38 lines
807 B
C++

#include "Client/BrowserClose.h"
#include "Client/Mouse.h"
// OFFSET: 0x00AB24D0
// FUNCTION: fn_45432
bool BrowserClose::Close() {
if (this->cursorState != 0) {
SetCursor(nullptr);
this->mouse.Reset();
ShowCursor(FALSE);
this->cursorState = 0;
}
if (this->attachment.site) {
this->attachment.Detach();
}
if (this->externalEvents) {
this->externalEvents->Release();
this->externalEvents = nullptr;
}
if (this->browser) {
this->browser->Stop();
SetWindowLongA(this->browserWindow, GWL_STYLE, WS_CHILD);
SetParent(this->browserWindow, this->applicationWindow);
this->browser->Quit();
this->browser->Release();
this->browser = nullptr;
}
if (this->host) {
DestroyWindow(this->host);
this->host = nullptr;
}
return true;
}