Refactor application window class name
This commit is contained in:
@@ -33,7 +33,6 @@
|
||||
#define CLR_EXCEPTION 0xE0434352
|
||||
#define VCPP_EXCEPTION 0xE06D7363
|
||||
|
||||
const Char* WindowsPlatform::ApplicationWindowClass = TEXT("FlaxWindow");
|
||||
void* WindowsPlatform::Instance = nullptr;
|
||||
|
||||
#if CRASH_LOG_ENABLE || TRACY_ENABLE
|
||||
@@ -527,7 +526,7 @@ void WindowsPlatform::PreInit(void* hInstance)
|
||||
windowsClass.hInstance = (HINSTANCE)Instance;
|
||||
windowsClass.hIcon = LoadIconW(GetModuleHandle(nullptr), MAKEINTRESOURCE(IDR_MAINFRAME));
|
||||
windowsClass.hCursor = LoadCursor(nullptr, IDC_ARROW);
|
||||
windowsClass.lpszClassName = ApplicationWindowClass;
|
||||
windowsClass.lpszClassName = ApplicationClassName;
|
||||
if (!RegisterClassW(&windowsClass))
|
||||
{
|
||||
Error(TEXT("Window class registration failed!"));
|
||||
@@ -741,7 +740,7 @@ void WindowsPlatform::Exit()
|
||||
#endif
|
||||
|
||||
// Unregister app class
|
||||
UnregisterClassW(ApplicationWindowClass, nullptr);
|
||||
UnregisterClassW(ApplicationClassName, nullptr);
|
||||
|
||||
Win32Platform::Exit();
|
||||
}
|
||||
|
||||
@@ -13,11 +13,6 @@ class FLAXENGINE_API WindowsPlatform : public Win32Platform
|
||||
{
|
||||
public:
|
||||
|
||||
/// <summary>
|
||||
/// Win32 application windows class name.
|
||||
/// </summary>
|
||||
static const Char* ApplicationWindowClass;
|
||||
|
||||
/// <summary>
|
||||
/// Handle to Win32 application instance.
|
||||
/// </summary>
|
||||
|
||||
@@ -120,7 +120,7 @@ WindowsWindow::WindowsWindow(const CreateWindowSettings& settings)
|
||||
// Creating the window
|
||||
_handle = CreateWindowExW(
|
||||
exStyle,
|
||||
Platform::ApplicationWindowClass,
|
||||
Platform::ApplicationClassName,
|
||||
settings.Title.GetText(),
|
||||
style,
|
||||
x,
|
||||
|
||||
Reference in New Issue
Block a user