File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7979#include < direct.h>
8080#include " cmdline/cmdline.h"
8181
82- #define SDL_MAIN_HANDLED
83- #include < SDL3/SDL_main.h>
84-
8582#define MAX_DOCKS 1000
8683
8784#define UNKNOWN_USER " Unknown"
@@ -267,7 +264,14 @@ bool fred_init(std::unique_ptr<os::GraphicsOperations>&& graphicsOps)
267264{
268265 int i;
269266
270- SDL_SetMainReady ();
267+ // Metadata must to be set as early as possible, before the first SDL_Init().
268+ // This is global info and cannot be changed later (i.e., it can't be set per mod)
269+ SDL_SetAppMetadata (" FRED2 Open" , FS_VERSION_FULL , " us.indiegames.scp.FRED2Open" );
270+
271+ SDL_SetAppMetadataProperty (SDL_PROP_APP_METADATA_TYPE_STRING , " application" );
272+ SDL_SetAppMetadataProperty (SDL_PROP_APP_METADATA_COPYRIGHT_STRING ,
273+ " Copyright 1999 Volition, Inc. & Copyright 2002-2026 The Source Code Project." );
274+
271275
272276 Random::seed (static_cast <unsigned int >(time (nullptr )));
273277 init_pending_messages ();
Original file line number Diff line number Diff line change 2323#include < csignal>
2424#include < project.h>
2525
26- #define SDL_MAIN_HANDLED
27- #include < SDL3/SDL_main.h>
28-
2926
3027
3128// Globals needed by the engine when built in 'FRED' mode.
@@ -79,6 +76,14 @@ void game_busy_callback(int /*count*/) {
7976int main (int argc, char * argv[]) {
8077 signal ( SIGSEGV , handler );
8178
79+ // Metadata must to be set as early as possible, before the first SDL_Init().
80+ // This is global info and cannot be changed later (i.e., it can't be set per mod)
81+ SDL_SetAppMetadata (" qtFRED" , FS_VERSION_FULL , " us.indiegames.scp.qtFRED" );
82+
83+ SDL_SetAppMetadataProperty (SDL_PROP_APP_METADATA_TYPE_STRING , " application" );
84+ SDL_SetAppMetadataProperty (SDL_PROP_APP_METADATA_COPYRIGHT_STRING ,
85+ " Copyright 1999 Volition, Inc. & Copyright 2002-2026 The Source Code Project." );
86+
8287 using namespace fso ::fred;
8388
8489#ifdef WIN32
@@ -91,8 +96,6 @@ int main(int argc, char* argv[]) {
9196
9297 qInstallMessageHandler (fsoMessageOutput);
9398
94- SDL_SetMainReady ();
95-
9699 QCoreApplication::setOrganizationName (" HardLightProductions" );
97100 QCoreApplication::setOrganizationDomain (" hard-light.net" );
98101 QCoreApplication::setApplicationName (" qtFRED" );
You can’t perform that action at this time.
0 commit comments