Skip to content

Commit

Permalink
Added always on top options
Browse files Browse the repository at this point in the history
  • Loading branch information
midwan committed Jan 13, 2021
1 parent f57ac88 commit 6bf4a64
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/include/options.h
Original file line number Diff line number Diff line change
Expand Up @@ -863,6 +863,8 @@ struct uae_prefs
int gfx_correct_aspect;
int scaling_method;

bool gui_alwaysontop;
bool main_alwaysontop;
bool minimize_inactive;
bool capture_always;
bool start_minimized;
Expand Down
10 changes: 8 additions & 2 deletions src/osdep/amiberry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1640,8 +1640,8 @@ void target_default_options(struct uae_prefs* p, int type)
p->minimized_priority = 3;
//p->notaskbarbutton = false;
//p->nonotificationicon = false;
//p->main_alwaysontop = false;
//p->gui_alwaysontop = false;
p->main_alwaysontop = false;
p->gui_alwaysontop = false;
//p->guikey = -1;
p->automount_removable = 0;
//p->automount_drives = 0;
Expand Down Expand Up @@ -1819,6 +1819,8 @@ void target_save_options(struct zfile* f, struct uae_prefs* p)
cfgfile_target_dwrite_str(f, _T("uaescsimode"), scsimode[p->uaescsimode]);

cfgfile_target_dwrite(f, _T("cpu_idle"), _T("%d"), p->cpu_idle);
cfgfile_target_dwrite_bool(f, _T("always_on_top"), p->main_alwaysontop);
cfgfile_target_dwrite_bool(f, _T("gui_always_on_top"), p->gui_alwaysontop);
cfgfile_target_dwrite_bool(f, _T("right_control_is_right_win"), p->right_control_is_right_win_key);

cfgfile_target_dwrite_bool(f, _T("gfx_auto_height"), p->gfx_auto_height);
Expand Down Expand Up @@ -1946,6 +1948,10 @@ int target_parse_option(struct uae_prefs* p, const char* option, const char* val
return 1;
if (cfgfile_yesno(option, value, _T("right_control_is_right_win"), &p->right_control_is_right_win_key))
return 1;
if (cfgfile_yesno(option, value, _T("always_on_top"), &p->main_alwaysontop))
return 1;
if (cfgfile_yesno(option, value, _T("gui_always_on_top"), &p->gui_alwaysontop))
return 1;
if (cfgfile_string(option, value, _T("serial_port"), &p->sername[0], 256)) {
if (p->sername[0])
p->use_serial = true;
Expand Down

0 comments on commit 6bf4a64

Please # to comment.