Merge branch 'master' of https://github.com/86Box/86Box into qt
This commit is contained in:
@@ -561,6 +561,7 @@ load_general(void)
|
|||||||
|
|
||||||
kbd_req_capture = config_get_int(cat, "kbd_req_capture", 0);
|
kbd_req_capture = config_get_int(cat, "kbd_req_capture", 0);
|
||||||
hide_status_bar = config_get_int(cat, "hide_status_bar", 0);
|
hide_status_bar = config_get_int(cat, "hide_status_bar", 0);
|
||||||
|
hide_tool_bar = config_get_int(cat, "hide_tool_bar", 0);
|
||||||
|
|
||||||
confirm_reset = config_get_int(cat, "confirm_reset", 1);
|
confirm_reset = config_get_int(cat, "confirm_reset", 1);
|
||||||
confirm_exit = config_get_int(cat, "confirm_exit", 1);
|
confirm_exit = config_get_int(cat, "confirm_exit", 1);
|
||||||
@@ -2036,6 +2037,7 @@ config_load(void)
|
|||||||
|
|
||||||
kbd_req_capture = 0;
|
kbd_req_capture = 0;
|
||||||
hide_status_bar = 0;
|
hide_status_bar = 0;
|
||||||
|
hide_tool_bar = 0;
|
||||||
scale = 1;
|
scale = 1;
|
||||||
machine = machine_get_machine_from_internal_name("ibmpc");
|
machine = machine_get_machine_from_internal_name("ibmpc");
|
||||||
dpi_scale = 1;
|
dpi_scale = 1;
|
||||||
@@ -2222,6 +2224,11 @@ save_general(void)
|
|||||||
else
|
else
|
||||||
config_delete_var(cat, "hide_status_bar");
|
config_delete_var(cat, "hide_status_bar");
|
||||||
|
|
||||||
|
if (hide_tool_bar != 0)
|
||||||
|
config_set_int(cat, "hide_tool_bar", hide_tool_bar);
|
||||||
|
else
|
||||||
|
config_delete_var(cat, "hide_tool_bar");
|
||||||
|
|
||||||
if (confirm_reset != 1)
|
if (confirm_reset != 1)
|
||||||
config_set_int(cat, "confirm_reset", confirm_reset);
|
config_set_int(cat, "confirm_reset", confirm_reset);
|
||||||
else
|
else
|
||||||
|
@@ -92,7 +92,7 @@ extern int update_icons;
|
|||||||
extern int unscaled_size_x, /* current unscaled size X */
|
extern int unscaled_size_x, /* current unscaled size X */
|
||||||
unscaled_size_y; /* current unscaled size Y */
|
unscaled_size_y; /* current unscaled size Y */
|
||||||
|
|
||||||
extern int kbd_req_capture, hide_status_bar;
|
extern int kbd_req_capture, hide_status_bar, hide_tool_bar;
|
||||||
|
|
||||||
/* System-related functions. */
|
/* System-related functions. */
|
||||||
extern char *fix_exe_path(char *str);
|
extern char *fix_exe_path(char *str);
|
||||||
|
@@ -40,6 +40,7 @@ int rctrl_is_lalt;
|
|||||||
int update_icons;
|
int update_icons;
|
||||||
int kbd_req_capture;
|
int kbd_req_capture;
|
||||||
int hide_status_bar;
|
int hide_status_bar;
|
||||||
|
int hide_tool_bar;
|
||||||
int fixed_size_x = 640;
|
int fixed_size_x = 640;
|
||||||
int fixed_size_y = 480;
|
int fixed_size_y = 480;
|
||||||
extern int title_set;
|
extern int title_set;
|
||||||
|
@@ -450,9 +450,6 @@ WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR lpszArg, int nCmdShow)
|
|||||||
{
|
{
|
||||||
char **argv = NULL;
|
char **argv = NULL;
|
||||||
int argc, i;
|
int argc, i;
|
||||||
wchar_t * AppID = L"86Box.86Box\0";
|
|
||||||
|
|
||||||
SetCurrentProcessExplicitAppUserModelID(AppID);
|
|
||||||
|
|
||||||
/* Initialize the COM library for the main thread. */
|
/* Initialize the COM library for the main thread. */
|
||||||
CoInitializeEx(NULL, COINIT_MULTITHREADED);
|
CoInitializeEx(NULL, COINIT_MULTITHREADED);
|
||||||
|
@@ -65,6 +65,7 @@ int user_resize = 0;
|
|||||||
int fixed_size_x = 0, fixed_size_y = 0;
|
int fixed_size_x = 0, fixed_size_y = 0;
|
||||||
int kbd_req_capture = 0;
|
int kbd_req_capture = 0;
|
||||||
int hide_status_bar = 0;
|
int hide_status_bar = 0;
|
||||||
|
int hide_tool_bar = 0;
|
||||||
int dpi = 96;
|
int dpi = 96;
|
||||||
|
|
||||||
extern char openfilestring[512];
|
extern char openfilestring[512];
|
||||||
@@ -92,6 +93,13 @@ static dllimp_t user32_imports[] = {
|
|||||||
{ NULL, NULL }
|
{ NULL, NULL }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/* Taskbar application ID API, Windows 7+ */
|
||||||
|
void* shell32_handle = NULL;
|
||||||
|
static HRESULT (WINAPI *pSetCurrentProcessExplicitAppUserModelID)(PCWSTR AppID);
|
||||||
|
static dllimp_t shell32_imports[]= {
|
||||||
|
{ "SetCurrentProcessExplicitAppUserModelID", &pSetCurrentProcessExplicitAppUserModelID }
|
||||||
|
};
|
||||||
|
|
||||||
int
|
int
|
||||||
win_get_dpi(HWND hwnd) {
|
win_get_dpi(HWND hwnd) {
|
||||||
if (user32_handle != NULL) {
|
if (user32_handle != NULL) {
|
||||||
@@ -1244,6 +1252,11 @@ ui_init(int nCmdShow)
|
|||||||
/* Load DPI related Windows 10 APIs */
|
/* Load DPI related Windows 10 APIs */
|
||||||
user32_handle = dynld_module("user32.dll", user32_imports);
|
user32_handle = dynld_module("user32.dll", user32_imports);
|
||||||
|
|
||||||
|
/* Set the application ID for the taskbar. */
|
||||||
|
shell32_handle = dynld_module("shell32.dll", shell32_imports);
|
||||||
|
if (shell32_handle)
|
||||||
|
pSetCurrentProcessExplicitAppUserModelID(L"86Box.86Box");
|
||||||
|
|
||||||
/* Set up TaskDialog configuration. */
|
/* Set up TaskDialog configuration. */
|
||||||
tdconfig.cbSize = sizeof(tdconfig);
|
tdconfig.cbSize = sizeof(tdconfig);
|
||||||
tdconfig.dwFlags = TDF_ENABLE_HYPERLINKS;
|
tdconfig.dwFlags = TDF_ENABLE_HYPERLINKS;
|
||||||
|
Reference in New Issue
Block a user