SELECTSAVED handling

By default, enable the SELECTSAVED option for everyone instead
of just for Windows or Qt.  And make Qt obey the 'selectsaved'
run-time option.

It can be disabled in config.h if necessary.
This commit is contained in:
PatR
2021-01-23 15:02:11 -08:00
parent a1eb06b462
commit ab74ed2c20
6 changed files with 57 additions and 29 deletions

View File

@@ -42,7 +42,7 @@ const
#endif
#endif
#if defined(UNIX) && defined(QT_GRAPHICS)
#if defined(UNIX) && defined(SELECTSAVED)
#include <sys/types.h>
#include <dirent.h>
#include <stdlib.h>
@@ -123,12 +123,6 @@ extern char *FDECL(translate_path_variables, (const char *, char *));
extern char *sounddir; /* defined in sounds.c */
#endif
#if defined(UNIX) && defined(QT_GRAPHICS)
#ifndef SELECTSAVED
#define SELECTSAVED
#endif
#endif
static NHFILE *NDECL(new_nhfile);
static void FDECL(free_nhfile, (NHFILE *));
#ifdef SELECTSAVED
@@ -1275,7 +1269,7 @@ get_saved_games()
}
#endif
#if defined(UNIX) && defined(QT_GRAPHICS)
#ifdef UNIX
/* posixly correct version */
int myuid = getuid();
DIR *dir;