static const int blit_cycle_diagram[][DIAGSIZE] =
{
- { 2, 0,0, 0,0 }, /* 0 */
- { 2, 0,0, 0,4 }, /* 1 */
- { 2, 0,3, 0,3 }, /* 2 */
- { 3, 0,3,0, 0,3,4 }, /* 3 */
- { 3, 0,2,0, 0,2,0 }, /* 4 */
- { 3, 0,2,0, 0,2,4 }, /* 5 */
- { 3, 0,2,3, 0,2,3 }, /* 6 */
- { 4, 0,2,3,0, 0,2,3,4 }, /* 7 */
- { 2, 1,0, 1,0 }, /* 8 */
- { 2, 1,0, 1,4 }, /* 9 */
- { 2, 1,3, 1,3 }, /* A */
- { 3, 1,3,0, 1,3,4, }, /* B */
- { 3, 1,2,0, 1,2,0 }, /* C */
- { 3, 1,2,0, 1,2,4 }, /* D */
- { 3, 1,2,3, 1,2,3 }, /* E */
- { 4, 1,2,3,0, 1,2,3,4 } /* F */
+ { 2, 0,0, 0,0 }, /* 0 -- */
+ { 2, 0,0, 0,4 }, /* 1 -D */
+ { 2, 0,3, 0,3 }, /* 2 -C */
+ { 3, 0,3,0, 0,3,4 }, /* 3 -CD */
+ { 3, 0,2,0, 0,2,0 }, /* 4 -B- */
+ { 3, 0,2,0, 0,2,4 }, /* 5 -BD */
+ { 3, 0,2,3, 0,2,3 }, /* 6 -BC */
+ { 4, 0,2,3,0, 0,2,3,4 }, /* 7 -BCD */
+ { 2, 1,0, 1,0 }, /* 8 A- */
+ { 2, 1,0, 1,4 }, /* 9 AD */
+ { 2, 1,3, 1,3 }, /* A AC */
+ { 3, 1,3,0, 1,3,4, }, /* B ACD */
+ { 3, 1,2,0, 1,2,0 }, /* C AB- */
+ { 3, 1,2,0, 1,2,4 }, /* D ABD */
+ { 3, 1,2,3, 1,2,3 }, /* E ABC */
+ { 4, 1,2,3,0, 1,2,3,4 } /* F ABCD */
};
/*
return sb->sb_errno ? 0 : sb->protoent;
}
-/* *------ syslog functions */
-/* Syslog(level, format, ap)(d0/a0/a1) */
-static uae_u32 REGPARAM2 bsdsocklib_vsyslog (TrapContext *context)
-{
- uae_char format_dst[256];
- TCHAR *s;
-
- uae_u32 level = m68k_dreg (regs, 0);
- uaecptr format = m68k_areg (regs, 0);
- uaecptr params = m68k_areg (regs, 1);
-
- strcpyah_safe (format_dst, format, sizeof format_dst);
-
- s = au (format_dst);
- write_log (_T("SYSLOG: %s\n"), s);
- xfree (s);
- return 0;
-}
-
/* *------ AmiTCP/IP 1.1 extensions */
/* Dup2Socket(fd1, fd2)(d0/d1) */
static uae_u32 REGPARAM2 bsdsocklib_Dup2Socket (TrapContext *context)
static const uae_u32 number_sys_error = sizeof (errortexts) / sizeof (*errortexts);
+/* *------ syslog functions */
+/* Syslog(level, format, ap)(d0/a0/a1) */
+static uae_u32 REGPARAM2 bsdsocklib_vsyslog (TrapContext *context)
+{
+#if 0
+ struct socketbase *sb = get_socketbase (context);
+ uae_char format_dst[512];
+ char out[256];
+ TCHAR *s;
+ uae_u8 paramtable[32 * 4];
+ int paramcnt, len;
+ uae_char *found = NULL;
+
+ uae_u32 level = m68k_dreg (regs, 0);
+ uaecptr format = m68k_areg (regs, 0);
+ uaecptr params = m68k_areg (regs, 1);
+
+ strcpyah_safe (format_dst, format, sizeof format_dst);
+
+ ((uae_u8**)paramtable)[0] = (uae_u8*)format_dst;
+ paramcnt = 4;
+ for (int i = 0; format_dst[i]; i++) {
+ if (format_dst[i] == '%') {
+ if (found)
+ found = NULL;
+ else
+ found = &format_dst[i];
+ len = 4;
+ } else if (found) {
+ char c = toupper (format_dst[i]);
+ if (c < 'A' || c > 'Z')
+ continue;
+ if (c == 'H') {
+ len = 2;
+ continue;
+ }
+ if (c == 'M') {
+ int err = sb->sb_errno;
+ if (sb->sb_errno < 0 || sb->sb_errno >= sizeof (errortexts) / sizeof (*errortexts))
+ err = sizeof (errortexts) / sizeof (*errortexts) - 1;
+ int errlen = _tcslen (errortexts[err]) - (&format_dst[i] - found);
+ memmove (&format_dst[i] + errlen, &format_dst[i] + 1, strlen (&format_dst[i] + 1) + 1);
+ ua_copy (found, sizeof format_dst, errortexts[err]);
+ i += errlen - 1;
+ continue;
+ }
+
+ if (c == 'P' || c == 'S' || c == 'N') {
+ uaecptr pt = get_long (params);
+ if (!valid_address (pt, 2))
+ goto end;
+ ((uae_u8**)(paramtable + paramcnt))[0] = get_real_address (pt);
+ params += 4;
+ paramcnt += sizeof (uae_u8*);
+ } else {
+ if (len == 2)
+ ((uae_u16*)(paramtable + paramcnt))[0] = get_word (params);
+ else
+ ((uae_u32*)(paramtable + paramcnt))[0] = get_long (params);
+ params += len;
+ paramcnt += len;
+ }
+ found = NULL;
+ }
+ }
+
+ va_list parms;
+ va_start (parms, paramtable);
+ _vsnprintf (out, sizeof out, format_dst, parms);
+ va_end (parms);
+
+ s = au (out);
+ write_log (_T("SYSLOG: %s\n"), s);
+ xfree (s);
+
+end:
+#endif
+ return 0;
+}
+
static const TCHAR *herrortexts[] =
{_T("No error"), _T("Unknown host"), _T("Host name lookup failure"), _T("Unknown server error"),
_T("No address associated with name")};
status = 1;
int clockadjust = 0;
-#if 0
- static uae_u32 prevtick;
- static int frametickcnt;
-
- uae_u32 tick = read_system_time (); // milliseconds
- uae_s32 tickdiff = tick - prevtick;
- uae_s32 framems = (frametickcnt * 1000) / (int)(vblank_hz + 0.5);
- if (abs (framems - tickdiff) >= 2000) {
- framems = 0;
- tickdiff = 0;
- prevtick = tick;
- frametickcnt = 0;
- write_log (_T("!\n"));
- } else {
- frametickcnt++;
- }
- int diff = (framems - tickdiff) / 1;
- if (diff < -5000)
- diff = -5000;
- else if (diff > 5000)
- diff = 5000;
- clockadjust = -vsynctimebase * diff / 1000;
- clockadjust *= 100;
- write_log (_T("%d:%d:%d\n"), framems - tickdiff, diff, clockadjust);
-#endif
+ int vstb = vsynctimebase;
if (currprefs.m68k_speed < 0) {
+#if 0
+ static uae_u32 prevtick;
+ static int frametickcnt;
+
+ uae_u32 tick = read_system_time (); // milliseconds
+ uae_s32 tickdiff = tick - prevtick;
+ uae_s32 framems = (frametickcnt * 1000) / (int)(vblank_hz + 0.5);
+ if (abs (framems - tickdiff) >= 2000) {
+ framems = 0;
+ tickdiff = 0;
+ prevtick = tick;
+ frametickcnt = 0;
+ write_log (_T("Clock sync reset!\n"));
+ } else {
+ frametickcnt++;
+ }
+ int diff = (framems - tickdiff) / 1;
+ if (diff < -100)
+ diff = -100;
+ else if (diff > 100)
+ diff = 100;
+ clockadjust = -vsynctimebase * diff / 10000;
+ //write_log (_T("%05d:%05d:%05d\n"), framems - tickdiff, diff, clockadjust);
+#endif
+
if (!frame_rendered && !picasso_on)
frame_rendered = render_screen (false);
int max;
int adjust = 0;
- if ((int)curr_time - (int)vsyncwaittime > 0 && (int)curr_time - (int)vsyncwaittime < vsynctimebase / 2)
+ if ((int)curr_time - (int)vsyncwaittime > 0 && (int)curr_time - (int)vsyncwaittime < vstb / 2)
adjust += curr_time - vsyncwaittime;
adjust += clockadjust;
- max = vsynctimebase * (1000 + currprefs.m68k_speed_throttle) / 1000 - adjust;
- vsyncwaittime = curr_time + vsynctimebase - adjust;
+ max = vstb * (1000 + currprefs.m68k_speed_throttle) / 1000 - adjust;
+ vsyncwaittime = curr_time + vstb - adjust;
vsyncmintime = curr_time;
if (max < 0) {
vsyncmaxtime = curr_time + max;
if (0)
- write_log (_T("%06d:%06d/%06d\n"), adjust, vsynctimeperline, vsynctimebase);
+ write_log (_T("%06d:%06d/%06d\n"), adjust, vsynctimeperline, vstb);
} else {
idletime += read_processor_time() - start;
curr_time = read_processor_time ();
vsyncmintime = curr_time;
- vsyncmaxtime = vsyncwaittime = curr_time + vsynctimebase;
+ vsyncmaxtime = vsyncwaittime = curr_time + vstb;
if (frame_rendered) {
show_screen ();
t += read_processor_time () - curr_time;
}
t += frameskipt_avg;
- vsynctimeperline = (vsynctimebase - t) / 3;
+ vsynctimeperline = (vstb - t) / 3;
if (vsynctimeperline < 0)
vsynctimeperline = 0;
- else if (vsynctimeperline > vsynctimebase / 3)
- vsynctimeperline = vsynctimebase / 3;
+ else if (vsynctimeperline > vstb / 3)
+ vsynctimeperline = vstb / 3;
frame_shown = true;
bool ciasyncs = !(bplcon0 & 2) || ((bplcon0 & 2) && currprefs.genlock);
CIA_hsync_posthandler (ciasyncs);
if (currprefs.cs_ciaatod > 0) {
+#if 0
+ static uae_s32 oldtick;
+ uae_s32 tick = read_system_time (); // milliseconds
+ int ms = 1000 / (currprefs.cs_ciaatod == 2 ? 60 : 50);
+ if (tick - oldtick > 2000 || tick - oldtick < -2000) {
+ oldtick = tick - ms;
+ write_log (_T("RESET\n"));
+ }
+ if (tick - oldtick >= ms) {
+ CIA_vsync_posthandler (1);
+ oldtick += ms;
+ }
+#else
static int cia_hsync;
cia_hsync -= 256;
if (cia_hsync <= 0) {
CIA_vsync_posthandler (1);
cia_hsync += ((MAXVPOS_PAL * MAXHPOS_PAL * 50 * 256) / (maxhpos * (currprefs.cs_ciaatod == 2 ? 60 : 50)));
}
+#endif
} else if (currprefs.cs_ciaatod == 0 && onvsync) {
CIA_vsync_posthandler (ciasyncs);
}
void init_row_map (void)
{
+ static uae_u8 *oldbufmem;
+ static int oldheight, oldpitch;
+
int i, j;
if (gfxvidinfo.drawbuffer.height_allocated > MAX_VIDHEIGHT) {
write_log (_T("Resolution too high, aborting\n"));
abort ();
}
+ if (oldbufmem && oldbufmem == gfxvidinfo.drawbuffer.bufmem &&
+ oldheight == gfxvidinfo.drawbuffer.height_allocated &&
+ oldpitch == gfxvidinfo.drawbuffer.rowbytes)
+ return;
+ oldbufmem = gfxvidinfo.drawbuffer.bufmem;
+ oldheight = gfxvidinfo.drawbuffer.height_allocated;
+ oldpitch = gfxvidinfo.drawbuffer.rowbytes;
j = 0;
for (i = gfxvidinfo.drawbuffer.height_allocated; i < MAX_VIDHEIGHT + 1; i++)
row_map[i] = row_tmp;
return my_strdup (newname);
}
+static const TCHAR *dostypes (uae_u32 dostype)
+{
+ static TCHAR dt[32];
+ int j;
+
+ j = 0;
+ for (int i = 0; i < 4; i++) {
+ uae_u8 c = dostype >> ((3 - i) * 8);
+ if (c >= ' ' && c <= 'z') {
+ dt[j++] = c;
+ } else {
+ dt[j++] = '\\';
+ _stprintf (&dt[j], _T("%d"), c);
+ j += _tcslen (&dt[j]);
+ }
+ }
+ dt[j] = 0;
+ return dt;
+}
+
static void dump_partinfo (struct hardfiledata *hfd, uae_u8 *pp)
{
TCHAR *s;
lowcyl = rl (pp + 36);
highcyl = rl (pp + 40);
- write_log (_T("RDB: '%s' dostype=%08X\n"), s, dostype);
+ write_log (_T("RDB: '%s' dostype=%08X (%s)\n"), s, dostype, dostypes (dostype));
write_log (_T("BlockSize: %d, Surfaces: %d, SectorsPerBlock %d\n"),
blocksize, surfaces, spb);
write_log (_T("SectorsPerTrack: %d, Reserved: %d, LowCyl %d, HighCyl %d, Size %dM\n"),
block = lowcyl * surfaces * spt;
if (hdf_read (hfd, buf, (uae_u64)blocksize * block, sizeof buf)) {
- write_log (_T("First block %d dostype: %08X\n"), block, rl (buf));
+ write_log (_T("First block %d dostype: %08X (%s)\n"), block, rl (buf), dostypes (rl (buf)));
} else {
write_log (_T("First block %d read failed!\n"), block);
}
uae_u32 dostype = rl (buf + 32);
int version = (buf[36] << 8) | buf[37];
int revision = (buf[38] << 8) | buf[39];
- write_log (_T("LSEG: %08x (%d.%d)\n"), dostype, version, revision);
+ write_log (_T("LSEG: %08x (%s) %d.%d\n"), dostype, dostypes (dostype), version, revision);
}
}
for (;;) {
if (fileblock == -1) {
if (!fsnode)
- write_log (_T("RDB: FS %08X not in FileSystem.resource or in RDB\n"), dostype);
+ write_log (_T("RDB: FS %08X (%s) not in FileSystem.resource or in RDB\n"), dostype, dostypes (dostype));
goto error;
}
if (!legalrdbblock (uip, fileblock)) {
newversion = (buf[36] << 8) | buf[37];
newrevision = (buf[38] << 8) | buf[39];
- write_log (_T("RDB: RDB filesystem %08X version %d.%d\n"), dostype, newversion, newrevision);
+ write_log (_T("RDB: RDB filesystem %08X (%s) version %d.%d\n"), dostype, dostypes (dostype), newversion, newrevision);
if (fsnode) {
- write_log (_T("RDB: %08X in FileSystem.resource version %d.%d\n"), dostype, oldversion, oldrevision);
+ write_log (_T("RDB: %08X (%s) in FileSystem.resource version %d.%d\n"), dostype, dostypes (dostype), oldversion, oldrevision);
}
if (newversion * 65536 + newrevision <= oldversion * 65536 + oldrevision && oldversion >= 0) {
write_log (_T("RDB: FS in FileSystem.resource is newer or same, ignoring RDB filesystem\n"));
_tcscpy (tmp + i, _T("FastFileSystem"));
}
if (tmp[0] == 0) {
- write_log (_T("RDB: no filesystem for dostype 0x%08X\n"), dostype);
+ write_log (_T("RDB: no filesystem for dostype 0x%08X (%s)\n"), dostype, dostypes (dostype));
if ((dostype & 0xffffff00) == 0x444f5300)
return FILESYS_HARDFILE;
write_log (_T("RDB: mounted without filesys\n"));
return FILESYS_HARDFILE;
}
- write_log (_T("RDB: fakefilesys, trying to load '%s', dostype 0x%08X\n"), tmp, dostype);
+ write_log (_T("RDB: fakefilesys, trying to load '%s', dostype 0x%08X (%s)\n"), tmp, dostype, dostypes (dostype));
zf = zfile_fopen (tmp, _T("rb"), ZFD_NORMAL);
if (!zf) {
write_log (_T("RDB: filesys not found\n"));
uip->rdb_filesyssize = size;
put_long (parmpacket + PP_FSSIZE, uip->rdb_filesyssize);
addfakefilesys (parmpacket, dostype);
- write_log (_T("HDF: faked RDB filesystem %08X loaded\n"), dostype);
+ write_log (_T("HDF: faked RDB filesystem %08X (%s) loaded\n"), dostype, dostypes (dostype));
return FILESYS_HARDFILE;
}
bool win32_middle_mouse;
bool win32_logfile;
bool win32_notaskbarbutton;
+ bool win32_nonotificationicon;
bool win32_alwaysontop;
bool win32_powersavedisabled;
bool win32_minimize_inactive;
int idx, slotoffset, flags, custompos, qual;
TCHAR *custom;
+ queue_input_event (-1, NULL, -1, 0, 0, 1);
+
if (!id)
return;
if (sub != 0)
return;
- queue_input_event (-1, NULL, -1, 0, 0, 1);
-
slotoffset = 0;
if (!checkqualifiers (id->eventid[offset][slotoffset], id->flags[offset][slotoffset], qualmask)) {
slotoffset = 4;
if (qualifiercheckonly)
continue;
+ if (!state) {
+ process_custom_event (na, j, state, qualmask, autofire, k);
+ }
+
// if evt == caps and scan == caps: sync with native caps led
if (evt == INPUTEVENT_KEY_CAPS_LOCK) {
int v;
return false;
return true;
}
+static bool needmman (void)
+{
+ if (canjit ())
+ return true;
+#ifdef _WIN32
+ if (currprefs.rtgmem_size)
+ return true;
+#endif
+ return false;
+}
static void nocanbang (void)
{
static void delete_shmmaps (uae_u32 start, uae_u32 size)
{
- if (!canjit ())
+ if (!needmman ())
return;
while (size) {
shmpiece *y;
uae_u8 *base = what->baseaddr;
- if (!canjit ())
+ if (!needmman ())
return;
if (!base)
return;
shmpiece *x;
static int recurse;
- if (!canjit ()) {
+ if (!needmman ()) {
nocanbang ();
return xcalloc (uae_u8, s + 4);
}
/* emulate 0.5M+0.5M with 1M Agnus chip ram aliasing */
if ((allocated_chipmem != currprefs.chipmem_size || allocated_bogomem != currprefs.bogomem_size) &&
currprefs.chipmem_size == 0x80000 && currprefs.bogomem_size >= 0x80000 &&
- (currprefs.chipset_mask & CSMASK_ECS_AGNUS) && !(currprefs.chipset_mask & CSMASK_AGA) && !canjit ()) {
+ (currprefs.chipset_mask & CSMASK_ECS_AGNUS) && !(currprefs.chipset_mask & CSMASK_AGA) && !needmman ()) {
int memsize1, memsize2;
if (chipmemory)
mapped_free (chipmemory);
} else if (type == RIM_TYPEHID) {
if (rdpdevice (buf1))
continue;
- if (rdi->hid.usUsage != 4 && rdi->hid.usUsage != 5) {
+ if (rdi->hid.usUsage != 4 && rdi->hid.usUsage != 5)
+ continue;
+ if (rdi->hid.usUsagePage >= 0xff00) // vendor specific
continue;
- }
for (i = 0; hidnorawinput[i].vid; i++) {
if (rdi->hid.dwProductId == hidnorawinput[i].pid && rdi->hid.dwVendorId == hidnorawinput[i].vid)
break;
#define IDS_FILTEROVERLAYTYPE_MASKS 379
#define IDS_FILTEROVERLAYTYPE_OVERLAYS 380
#define IDS_AUTOSCALE_INTEGER_AUTOSCALE 381
+#define IDS_WSTYLE_BORDERLESS 382
+#define IDS_WSTYLE_MINIMAL 383
+#define IDS_WSTYLE_STANDARD 384
+#define IDS_WSTYLE_EXTENDED 385
#define IDS_QS_MODELS 1000
#define IDS_QS_MODEL_A500 1001
#define IDS_QS_MODEL_A500P 1002
#define IDC_MIDILIST 1023
#define IDC_MIDIOUTLIST 1023
#define IDC_DA_MODE 1023
-#define IDC_SHOWGUI 1024
#define IDC_MIDIINLIST 1024
#define IDC_RESOLUTION2 1024
#define IDC_DISPLAYSELECT 1024
#define IDC_SCREENMODE_NATIVE 1026
#define IDC_PRINTERTYPELIST 1026
#define IDC_FASTMEM 1027
-#define IDC_SHOWLEDS 1027
#define IDC_PORT1_JOYS 1027
#define IDC_SCREENMODE_RTG 1027
#define IDC_DONGLELIST 1027
#define IDC_MBMEM1 1028
#define IDC_PORT_TABLET_CURSOR 1028
-#define IDC_SHOWLEDSRTG 1028
#define IDC_SAMPLERLIST 1028
#define IDC_DISPLAY_BUFFERCNT 1028
#define IDC_PORT0_JOYSMODE 1029
#define IDC_PARALLEL 1033
#define IDC_PORT0_AF 1033
#define IDC_PORT1_AF 1034
-#define IDC_JULIAN 1040
#define IDC_FOCUSMINIMIZE 1041
#define IDC_FASTTEXT 1043
#define IDC_FASTRAM 1044
#define IDC_FLUSHPRINTER 1510
#define IDC_MAPDRIVES_REMOVABLE 1510
#define IDC_PORT0_TEST 1510
-#define IDC_CACHETEXT2 1510
#define IDC_SCREENRESTEXT 1511
#define IDC_MAPDRIVES_AUTO 1511
#define IDC_PORT0_TEST2 1511
#define IDC_STATEREC_CAPTURE2 1533
#define IDC_ACTIVE_PAUSE 1534
#define IDC_ACTIVE_NOSOUND 1535
+#define IDC_STATECLEAR 1536
#define IDC_SER_SHARED 1553
#define IDC_SER_CTSRTS 1554
#define IDC_SER_DIRECT 1555
#define IDC_JITENABLE 1584
#define IDC_DISASSEMBLY 1585
#define IDC_MMUENABLE 1585
-#define IDC_CTRLF11 1586
-#define IDC_FASTCOPPER 1588
#define IDC_COLLISION0 1589
#define IDC_COLLISION1 1590
#define IDC_AUDIOSYNC 1590
#define IDC_INPUTTYPE 1607
#define IDC_INPUTSELECTTEXT 1608
#define IDC_NOUAEFSDB 1608
-#define IDC_NOTASKBARBUTTON 1608
-#define IDC_CLOCKSYNC 1609
#define IDC_INPUTDEVICE 1609
#define IDC_MAPROM 1609
#define IDC_NORECYCLEBIN 1609
#define IDC_AVIOUTPUT_FILE 1611
#define IDC_INPUTLIST 1611
#define IDC_CATWEASEL 1611
-#define IDC_CLIPBOARDSHARE 1611
#define IDC_INPUTAMIGA 1612
-#define IDC_BORDERLESS 1612
-#define IDC_POWERSAVE 1612
#define IDC_AVIOUTPUT_VIDEO 1613
#define IDC_INPUTAUTOFIRE 1613
#define IDC_PORT_MOUSETRICK 1613
-#define IDC_NATIVECODE 1613
#define IDC_AVIOUTPUT_AUDIO 1614
#define IDC_INPUTCOPYFROM 1614
#define IDC_SANA2 1614
#define IDC_CD_SELECT 1807
#define IDC_FASTMEMAUTOCONFIG 1808
#define IDC_RTG_DISPLAYSELECT 1809
+#define IDC_MISCLIST 1810
+#define IDC_STATENAME 1811
#define ID__FLOPPYDRIVES 40004
#define ID_FLOPPYDRIVES_DF0 40005
#define ID_ST_CONFIGURATION 40010
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NO_MFC 1
#define _APS_3D_CONTROLS 1
-#define _APS_NEXT_RESOURCE_VALUE 370
+#define _APS_NEXT_RESOURCE_VALUE 386
#define _APS_NEXT_COMMAND_VALUE 40050
-#define _APS_NEXT_CONTROL_VALUE 1810
+#define _APS_NEXT_CONTROL_VALUE 1812
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
CONTROL "Double",IDC_LM_DOUBLED,"Button",BS_AUTORADIOBUTTON | BS_LEFT | WS_TABSTOP,231,164,45,10\r
CONTROL "Scanlines",IDC_LM_SCANLINES,"Button",BS_AUTORADIOBUTTON | BS_LEFT | WS_TABSTOP,231,180,46,10\r
COMBOBOX IDC_DA_MODE,4,218,58,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
- CONTROL "",IDC_DA_SLIDER,"msctls_trackbar32",TBS_AUTOTICKS | TBS_TOP | WS_TABSTOP,67,214,101,20\r
+ CONTROL "",IDC_DA_SLIDER,"msctls_trackbar32",TBS_AUTOTICKS | TBS_TOP | WS_TABSTOP,67,214,96,20\r
LTEXT "FPS adj.:",IDC_REFRESH2TEXT,9,193,32,8\r
CONTROL "",IDC_FRAMERATE2,"msctls_trackbar32",TBS_AUTOTICKS | TBS_TOP | WS_TABSTOP,40,188,99,20\r
- EDITTEXT IDC_RATE2TEXT,143,192,41,12,ES_AUTOHSCROLL\r
+ EDITTEXT IDC_RATE2TEXT,143,192,46,12,ES_AUTOHSCROLL\r
COMBOBOX IDC_RESOLUTIONDEPTH,134,27,46,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
CONTROL "Filtered low resolution",IDC_LORES_SMOOTHED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,120,125,89,10\r
COMBOBOX IDC_SCREENMODE_NATIVE,39,85,63,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
STYLE DS_LOCALEDIT | DS_SETFONT | DS_3DLOOK | DS_CONTROL | WS_CHILD\r
FONT 8, "MS Sans Serif", 0, 0, 0x1\r
BEGIN\r
- GROUPBOX "Miscellaneous Options",IDC_STATIC,4,2,293,165\r
- CONTROL "Untrap = middle button",IDC_JULIAN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,19,110,10\r
- CONTROL "Show GUI on startup",IDC_SHOWGUI,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,43,109,10\r
- CONTROL "Native on-screen display",IDC_SHOWLEDS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,182,103,109,10\r
- CONTROL "Don't show taskbar button",IDC_NOTASKBARBUTTON,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,67,109,10\r
- CONTROL "Use CTRL-F11 to quit",IDC_CTRLF11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,55,110,10\r
+ GROUPBOX "Miscellaneous Options",IDC_STATIC,169,2,128,131\r
GROUPBOX "Keyboard LEDs",IDC_STATIC,3,207,294,29\r
COMBOBOX IDC_KBLED1,10,218,56,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
COMBOBOX IDC_KBLED2,78,218,56,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
COMBOBOX IDC_KBLED3,145,218,56,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
- GROUPBOX "Logging",IDC_STATIC,4,167,151,38\r
- CONTROL "Create log file",IDC_CREATELOGFILE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,41,176,72,10\r
- CONTROL "Illegal memory accesses",IDC_ILLEGAL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,41,188,95,10\r
- GROUPBOX "State Files",IDC_STATIC,162,167,135,38\r
- PUSHBUTTON "Load state...",IDC_DOLOADSTATE,175,182,49,14\r
- PUSHBUTTON "Save state...",IDC_DOSAVESTATE,235,182,49,14\r
- CONTROL "Always on top",IDC_ALWAYSONTOP,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,79,98,10\r
+ GROUPBOX "State Files",IDC_STATIC,3,168,293,38\r
+ PUSHBUTTON "Load state...",IDC_DOLOADSTATE,178,183,55,14\r
+ PUSHBUTTON "Save state...",IDC_DOSAVESTATE,237,183,55,14\r
CONTROL "USB mode",IDC_KBLED_USB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,217,219,64,10\r
- COMBOBOX IDC_SCSIMODE,213,26,80,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
- COMBOBOX IDC_LANGUAGE,153,144,122,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
- GROUPBOX "Language",IDC_STATIC,138,134,154,27\r
- CONTROL "Disable screensaver",IDC_POWERSAVE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,91,109,10\r
- COMBOBOX IDC_DD_SURFACETYPE,213,78,79,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
- RTEXT "DirectDraw display buffer:",IDC_STATIC,112,79,97,10,SS_CENTERIMAGE\r
- RTEXT "SCSI and CD/DVD access method:",IDC_STATIC,151,12,126,10,SS_CENTERIMAGE\r
- CONTROL "Synchronize clock",IDC_CLOCKSYNC,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,103,111,10\r
- CONTROL "Faster RTG [] Enables less accurate custom chipset emulation mode when Picasso96 is enabled.",IDC_FASTERRTG,\r
- "Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,19,115,111,10\r
- CONTROL "RTG on-screen display",IDC_SHOWLEDSRTG,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,182,114,109,10\r
- RTEXT "Graphics API:",IDC_STATIC,130,62,79,10,SS_CENTERIMAGE\r
- COMBOBOX IDC_DXMODE,213,60,79,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
- CONTROL "Minimize when focus is lost",IDC_FOCUSMINIMIZE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,31,110,10\r
- RTEXT "Windowed style:",IDC_STATIC,128,45,81,10,SS_CENTERIMAGE\r
- COMBOBOX IDC_WINDOWEDMODE,213,43,79,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
- CONTROL "Clipboard sharing",IDC_CLIPBOARDSHARE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,127,111,10\r
- CONTROL "Allow native code",IDC_NATIVECODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,19,139,111,10\r
+ COMBOBOX IDC_SCSIMODE,194,26,80,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
+ COMBOBOX IDC_LANGUAGE,197,146,77,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
+ GROUPBOX "Language",IDC_STATIC,169,133,127,33\r
+ COMBOBOX IDC_DD_SURFACETYPE,194,114,79,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
+ CTEXT "DirectDraw:",IDC_STATIC,175,101,117,10,SS_CENTERIMAGE\r
+ CTEXT "SCSI and CD/DVD access:",IDC_STATIC,175,12,117,10,SS_CENTERIMAGE\r
+ CTEXT "Graphics API:",IDC_STATIC,175,72,117,10,SS_CENTERIMAGE\r
+ COMBOBOX IDC_DXMODE,194,85,79,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
+ CTEXT "Windowed style:",IDC_STATIC,175,42,117,10,SS_CENTERIMAGE\r
+ COMBOBOX IDC_WINDOWEDMODE,194,56,79,150,CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP\r
+ CONTROL "",IDC_MISCLIST,"SysListView32",LVS_REPORT | LVS_ALIGNLEFT | LVS_NOCOLUMNHEADER | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,3,5,162,161\r
+ EDITTEXT IDC_STATENAME,8,183,144,13,ES_AUTOHSCROLL | ES_READONLY | NOT WS_TABSTOP\r
+ CONTROL "",IDC_STATECLEAR,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,158,185,9,10\r
END\r
\r
IDD_HARDFILE DIALOGEX 0, 0, 299, 249\r
STYLE DS_LOCALEDIT | DS_SETFONT | DS_SETFOREGROUND | DS_3DLOOK | DS_CONTROL | DS_CENTER | DS_CENTERMOUSE | WS_CHILD\r
FONT 8, "MS Sans Serif", 0, 0, 0x0\r
BEGIN\r
- CONTROL "",IDC_DISKLIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_ALIGNLEFT | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,4,6,292,196\r
+ CONTROL "",IDC_DISKLIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_ALIGNLEFT | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,4,4,292,198\r
PUSHBUTTON "Remove floppy disk image",IDC_DISKLISTREMOVE,156,223,101,15\r
COMBOBOX IDC_DISKTEXT,3,205,293,75,CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP\r
PUSHBUTTON "Insert floppy disk image",IDC_DISKLISTINSERT,41,223,101,15\r
IDS_FILTEROVERLAYTYPE_MASKS "Masks"\r
IDS_FILTEROVERLAYTYPE_OVERLAYS "Overlays"\r
IDS_AUTOSCALE_INTEGER_AUTOSCALE "Auto Integer scaling"\r
+ IDS_WSTYLE_BORDERLESS "Borderless"\r
+ IDS_WSTYLE_MINIMAL "Minimal"\r
END\r
\r
STRINGTABLE\r
IDS_AUTODETECT "Autodetect"\r
END\r
\r
+STRINGTABLE\r
+BEGIN\r
+ IDS_WSTYLE_STANDARD "Standard"\r
+ IDS_WSTYLE_EXTENDED "Extended"\r
+END\r
+\r
#endif // English resources\r
/////////////////////////////////////////////////////////////////////////////\r
\r
//p->win32_active_nocapture_priority = 1;
p->win32_inactive_priority = 2;
p->win32_iconified_priority = 3;
- p->win32_notaskbarbutton = 0;
- p->win32_alwaysontop = 0;
+ p->win32_notaskbarbutton = false;
+ p->win32_nonotificationicon = false;
+ p->win32_alwaysontop = false;
p->win32_guikey = -1;
p->win32_automount_removable = 0;
p->win32_automount_drives = 0;
cfgfile_target_dwrite (f, _T("cpu_idle"), _T("%d"), p->cpu_idle);
cfgfile_target_dwrite_bool (f, _T("notaskbarbutton"), p->win32_notaskbarbutton);
+ cfgfile_target_dwrite_bool (f, _T("nonotificationicon"), p->win32_nonotificationicon);
cfgfile_target_dwrite_bool (f, _T("always_on_top"), p->win32_alwaysontop);
cfgfile_target_dwrite_bool (f, _T("no_recyclebin"), p->win32_norecyclebin);
if (p->win32_guikey >= 0)
|| cfgfile_intval (option, value, _T("midiin_device"), &p->win32_midiindev, 1)
|| cfgfile_intval (option, value, _T("samplersoundcard"), &p->win32_samplersoundcard, 1)
|| cfgfile_yesno (option, value, _T("notaskbarbutton"), &p->win32_notaskbarbutton)
+ || cfgfile_yesno (option, value, _T("nonotificationicon"), &p->win32_nonotificationicon)
|| cfgfile_yesno (option, value, _T("always_on_top"), &p->win32_alwaysontop)
|| cfgfile_yesno (option, value, _T("powersavedisabled"), &p->win32_powersavedisabled)
|| cfgfile_string (option, value, _T("exec_before"), p->win32_commandpathstart, sizeof p->win32_commandpathstart / sizeof (TCHAR))
NOTIFYICONDATA nid;
BOOL v;
+ if (!remove && currprefs.win32_nonotificationicon)
+ return;
+
#ifdef RETROPLATFORM
if (rp_isactive ())
return;
#define LANG_DLL 1
//#define WINUAEBETA _T("")
-#define WINUAEBETA _T("3")
-#define WINUAEDATE MAKEBD(2012, 5, 25)
+#define WINUAEBETA _T("4")
+#define WINUAEDATE MAKEBD(2012, 6, 3)
#define WINUAEEXTRA _T("")
//#define WINUAEEXTRA _T("AmiKit Preview")
#define WINUAEREV _T("")
c |= currprefs.win32_alwaysontop != changed_prefs.win32_alwaysontop ? 32 : 0;
c |= currprefs.win32_notaskbarbutton != changed_prefs.win32_notaskbarbutton ? 32 : 0;
+ c |= currprefs.win32_nonotificationicon != changed_prefs.win32_nonotificationicon ? 32 : 0;
c |= currprefs.win32_borderless != changed_prefs.win32_borderless ? 32 : 0;
c |= currprefs.win32_statusbar != changed_prefs.win32_statusbar ? 32 : 0;
c |= currprefs.win32_rtgmatchdepth != changed_prefs.win32_rtgmatchdepth ? 2 : 0;
currprefs.gfx_apmode[1].gfx_backbuffers = changed_prefs.gfx_apmode[1].gfx_backbuffers;
currprefs.win32_alwaysontop = changed_prefs.win32_alwaysontop;
+ currprefs.win32_nonotificationicon = changed_prefs.win32_nonotificationicon;
currprefs.win32_notaskbarbutton = changed_prefs.win32_notaskbarbutton;
currprefs.win32_borderless = changed_prefs.win32_borderless;
currprefs.win32_statusbar = changed_prefs.win32_statusbar;
int graphics_init (void)
{
+ systray (hHiddenWnd, TRUE);
+ systray (hHiddenWnd, FALSE);
gfxmode_reset ();
return open_windows (1);
}
#define DISK_COLUMNS 3
#define MISC2_COLUMNS 2
#define INPUTMAP_COLUMNS 1
+#define MISC1_COLUMNS 1
#define MAX_COLUMN_HEADING_WIDTH 20
#define LV_LOADSAVE 1
#define LV_DISK 4
#define LV_MISC2 5
#define LV_INPUTMAP 6
-#define LV_MAX 7
+#define LV_MISC1 7
+#define LV_MAX 8
static int lv_oldidx[LV_MAX];
static int lv_old_type = -1;
static int listview_num_columns;
+struct miscentry
+{
+ int type;
+ int canactive;
+ TCHAR *name;
+ bool *b;
+ int *i;
+ int ival, imask;
+};
+
+static struct miscentry misclist[] = {
+ { 0, 1, _T("Untrap = middle button"), &workprefs.win32_middle_mouse },
+ { 0, 1, _T("Minimize when focus is lost"), &workprefs.win32_minimize_inactive },
+ { 0, 0, _T("Show GUI on startup"), &workprefs.start_gui },
+ { 0, 1, _T("Use CTRL-F11 to quit"), &workprefs.win32_ctrl_F11_is_quit },
+ { 0, 1, _T("Don't show taskbar button"), &workprefs.win32_notaskbarbutton },
+ { 0, 1, _T("Don't show notification icon"), &workprefs.win32_nonotificationicon },
+ { 0, 1, _T("Always on top"), &workprefs.win32_alwaysontop },
+ { 0, 1, _T("Disable screensaver"), &workprefs.win32_powersavedisabled },
+ { 0, 0, _T("Synchronize clock"), &workprefs.tod_hack },
+ { 0, 1, _T("Faster RTG"), &workprefs.picasso96_nocustom },
+ { 0, 0, _T("Clipboard sharing"), &workprefs.clipboard_sharing },
+ { 0, 1, _T("Allow native code"), &workprefs.native_code },
+ { 0, 1, _T("Native on-screen display"), NULL, &workprefs.leds_on_screen, STATUSLINE_CHIPSET, STATUSLINE_CHIPSET },
+ { 0, 1, _T("RTG on-screen display"), NULL, &workprefs.leds_on_screen, STATUSLINE_RTG, STATUSLINE_RTG },
+ { 0, 0, _T("Create winuaelog.txt log"), &workprefs.win32_logfile },
+ { 0, 0, _T("Log illegal memory accesses"), &workprefs.illegal_mem },
+ { 0, NULL }
+};
+
void InitializeListView (HWND hDlg)
{
int lv_type;
int items = 0, result = 0, i, j, entry = 0, temp = 0;
TCHAR tmp[10], tmp2[MAX_DPATH];
int listview_column_width[HARDDISK_COLUMNS];
+ DWORD extraflags = 0;
if (cachedlist) {
- if (lv_old_type >= 0)
+ if (lv_old_type >= 0) {
lv_oldidx[lv_old_type] = ListView_GetTopIndex (cachedlist);
lv_oldidx[lv_old_type] += ListView_GetCountPerPage (cachedlist) - 1;
+ }
cachedlist = NULL;
}
listview_num_columns = INPUTMAP_COLUMNS;
lv_type = LV_INPUTMAP;
- column_heading[0][0] = NULL;
+ column_heading[0][0] = 0;
list = GetDlgItem (hDlg, IDC_INPUTMAPLIST);
} else if (hDlg == pages[MISC2_ID]) {
_tcscpy (column_heading[1], _T(""));
list = GetDlgItem (hDlg, IDC_ASSOCIATELIST);
+ } else if (hDlg == pages[MISC1_ID]) {
+
+ listview_num_columns = MISC1_COLUMNS;
+ lv_type = LV_MISC1;
+ column_heading[0][0] = 0;
+ list = GetDlgItem (hDlg, IDC_MISCLIST);
+ extraflags = LVS_EX_CHECKBOXES;
+
} else {
listview_num_columns = DISK_COLUMNS;
}
- int flags = LVS_EX_ONECLICKACTIVATE | LVS_EX_UNDERLINEHOT | LVS_EX_DOUBLEBUFFER | LVS_EX_FULLROWSELECT;
+ int flags = LVS_EX_DOUBLEBUFFER | extraflags;
+ if (lv_type != LV_MISC1)
+ flags |= LVS_EX_ONECLICKACTIVATE | LVS_EX_UNDERLINEHOT | LVS_EX_FULLROWSELECT;
ListView_SetExtendedListViewStyleEx (list, flags , flags);
ListView_DeleteAllItems (list);
listview_column_width[0] = 400;
update_listview_inputmap (hDlg);
+ } else if (lv_type == LV_MISC1) {
+
+ listview_column_width[0] = 150;
+ for (i = 0; misclist[i].name; i++) {
+ struct miscentry *me = &misclist[i];
+ int type = me->type;
+ bool checked = false;
+
+ if (me->b) {
+ checked = *me->b;
+ } else if (me->i) {
+ checked = ((*me->i) & me->imask) != 0;
+ }
+
+ lvstruct.mask = LVIF_TEXT | LVIF_PARAM;
+ lvstruct.pszText = me->name;
+ lvstruct.lParam = 0;
+ lvstruct.iItem = i;
+ lvstruct.iSubItem = 0;
+ result = ListView_InsertItem (list, &lvstruct);
+ ListView_SetItemState (list, i, INDEXTOSTATEIMAGEMASK(type ? 0 : (checked ? 2 : 1)), LVIS_STATEIMAGEMASK);
+ width = ListView_GetStringWidth (list, lvstruct.pszText) + 30;
+ if (width > listview_column_width[0])
+ listview_column_width[0] = width;
+ entry++;
+ }
+
} else if (lv_type == LV_DISK) {
for (i = 0; i < MAX_SPARE_DRIVES; i++) {
#if !defined (CPUEMU_12)
ew (hDlg, IDC_CYCLEEXACT, FALSE);
#endif
- ew (hDlg, IDC_FASTCOPPER, enable);
ew (hDlg, IDC_GENLOCK, full_property_sheet);
ew (hDlg, IDC_BLITIMM, enable);
if (enable == FALSE) {
workprefs.immediate_blits = 0;
- CheckDlgButton (hDlg, IDC_FASTCOPPER, FALSE);
CheckDlgButton (hDlg, IDC_BLITIMM, FALSE);
}
ew (hDlg, IDC_CS_EXT, workprefs.cs_compatible ? TRUE : FALSE);
freq = storedrefreshrates[i].rate;
if (freq < 0) {
freq = -freq;
- _stprintf (hz, L"(%dHz)", freq);
+ _stprintf (hz, _T("(%dHz)"), freq);
} else {
- _stprintf (hz, L"%dHz", freq);
+ _stprintf (hz, _T("%dHz"), freq);
}
if (freq == 50 || freq == 100 || (freq * 2 == 50 && lace))
- _tcscat (hz, L" PAL");
+ _tcscat (hz, _T(" PAL"));
if (freq == 60 || freq == 120 || (freq * 2 == 60 && lace))
- _tcscat (hz, L" NTSC");
+ _tcscat (hz, _T(" NTSC"));
if (lace) {
TCHAR tmp[10];
- _stprintf (tmp, L" (%di)", freq * 2);
+ _stprintf (tmp, _T(" (%di)"), freq * 2);
_tcscat (hz, tmp);
}
if (storedrefreshrates[i].type & REFRESH_RATE_RAW)
- _tcscat (hz, L" (*)");
+ _tcscat (hz, _T(" (*)"));
if (abs (workprefs.gfx_apmode[0].gfx_refreshrate) == freq)
_tcscpy (hz2, hz);
SendDlgItemMessage (hDlg, IDC_REFRESHRATE, CB_ADDSTRING, 0, (LPARAM)hz);
ew (hDlg, IDC_RTG_SCALE_ASPECTRATIO, rtg2);
ew (hDlg, IDC_RTG_VBLANKRATE, rtg2);
ew (hDlg, IDC_RTG_BUFFERCNT, rtg2);
+ ew (hDlg, IDC_RTG_DISPLAYSELECT, rtg2);
}
static int manybits (int v, int mask)
{
int i, cnt;
TCHAR tmp[MAX_DPATH];
+ bool notset = true;
SendDlgItemMessage (hDlg, IDC_NETDEVICE, CB_RESETCONTENT, 0, 0);
WIN32GUI_LoadUIString (IDS_NETDISCONNECTED, tmp, sizeof tmp / sizeof (TCHAR));
ndd[i].mac[0], ndd[i].mac[1], ndd[i].mac[2], ndd[i].mac[3], ndd[i].mac[4], ndd[i].mac[5]);
_stprintf (tmp, _T("%s %s"), mac, ndd[i].desc);
SendDlgItemMessage (hDlg, IDC_NETDEVICE, CB_ADDSTRING, 0, (LPARAM)tmp);
- if (!_tcsicmp (workprefs.a2065name, mac) || !_tcsicmp (workprefs.a2065name, ndd[i].name))
+ if (!_tcsicmp (workprefs.a2065name, mac) || !_tcsicmp (workprefs.a2065name, ndd[i].name)) {
SendDlgItemMessage (hDlg, IDC_NETDEVICE, CB_SETCURSEL, cnt, 0);
+ notset = false;
+ }
cnt++;
}
}
+ if (notset)
+ SendDlgItemMessage (hDlg, IDC_NETDEVICE, CB_SETCURSEL, 0, 0);
}
static void enable_for_expansiondlg (HWND hDlg)
static void enable_for_miscdlg (HWND hDlg)
{
if (!full_property_sheet) {
- ew (hDlg, IDC_JULIAN, TRUE);
- ew (hDlg, IDC_CTRLF11, TRUE);
- ew (hDlg, IDC_SHOWGUI, FALSE);
ew (hDlg, IDC_NOSPEED, TRUE);
ew (hDlg, IDC_NOSPEEDPAUSE, TRUE);
ew (hDlg, IDC_NOSOUND, TRUE);
ew (hDlg, IDC_DOSAVESTATE, TRUE);
ew (hDlg, IDC_SCSIMODE, FALSE);
- ew (hDlg, IDC_CLOCKSYNC, FALSE);
- ew (hDlg, IDC_CLIPBOARDSHARE, FALSE);
- ew (hDlg, IDC_NATIVECODE, FALSE);
} else {
#if !defined (SCSIEMU)
EnableWindow (GetDlgItem(hDlg, IDC_SCSIMODE), TRUE);
{
int i, idx = 0, cnt = 0, lid;
WORD langid = -1;
+ TCHAR tmp[MAX_DPATH];
if (regqueryint (NULL, _T("Language"), &lid))
langid = (WORD)lid;
+ WIN32GUI_LoadUIString (IDS_AUTODETECT, tmp, sizeof tmp / sizeof (TCHAR));
SendDlgItemMessage (hDlg, IDC_LANGUAGE, CB_RESETCONTENT, 0, 0);
- SendDlgItemMessage (hDlg, IDC_LANGUAGE, CB_ADDSTRING, 0, (LPARAM)_T("Autodetect"));
+ SendDlgItemMessage (hDlg, IDC_LANGUAGE, CB_ADDSTRING, 0, (LPARAM)tmp);
SendDlgItemMessage (hDlg, IDC_LANGUAGE, CB_ADDSTRING, 0, (LPARAM)_T("English (built-in)"));
if (langid == 0)
idx = 1;
static void values_to_miscdlg (HWND hDlg)
{
- if (currentpage == MISC1_ID) {
+ TCHAR tmp[MAX_DPATH];
- CheckDlgButton (hDlg, IDC_FOCUSMINIMIZE, workprefs.win32_minimize_inactive);
- CheckDlgButton (hDlg, IDC_ILLEGAL, workprefs.illegal_mem);
- CheckDlgButton (hDlg, IDC_SHOWGUI, workprefs.start_gui);
- CheckDlgButton (hDlg, IDC_JULIAN, workprefs.win32_middle_mouse);
- CheckDlgButton (hDlg, IDC_CREATELOGFILE, workprefs.win32_logfile);
- CheckDlgButton (hDlg, IDC_CTRLF11, workprefs.win32_ctrl_F11_is_quit);
- CheckDlgButton (hDlg, IDC_SHOWLEDS, (workprefs.leds_on_screen & STATUSLINE_CHIPSET) ? 1 : 0);
- CheckDlgButton (hDlg, IDC_SHOWLEDSRTG, (workprefs.leds_on_screen & STATUSLINE_RTG) ? 1 : 0);
- CheckDlgButton (hDlg, IDC_NOTASKBARBUTTON, workprefs.win32_notaskbarbutton);
- CheckDlgButton (hDlg, IDC_ALWAYSONTOP, workprefs.win32_alwaysontop);
- CheckDlgButton (hDlg, IDC_CLOCKSYNC, workprefs.tod_hack);
- CheckDlgButton (hDlg, IDC_CLIPBOARDSHARE, workprefs.clipboard_sharing);
- CheckDlgButton (hDlg, IDC_NATIVECODE, workprefs.native_code);
- CheckDlgButton (hDlg, IDC_POWERSAVE, workprefs.win32_powersavedisabled);
- CheckDlgButton (hDlg, IDC_FASTERRTG, workprefs.picasso96_nocustom);
+ if (currentpage == MISC1_ID) {
misc_kbled (hDlg, IDC_KBLED1, workprefs.keyboard_leds[0]);
misc_kbled (hDlg, IDC_KBLED2, workprefs.keyboard_leds[1]);
SendDlgItemMessage (hDlg, IDC_DD_SURFACETYPE, CB_SETCURSEL, ddforceram, 0);
SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_RESETCONTENT, 0, 0);
- SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)_T("Borderless"));
- SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)_T("Minimal"));
- SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)_T("Standard"));
- SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)_T("Extended"));
+
+ WIN32GUI_LoadUIString (IDS_WSTYLE_BORDERLESS, tmp, sizeof tmp / sizeof (TCHAR));
+ SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)tmp);
+ WIN32GUI_LoadUIString (IDS_WSTYLE_MINIMAL, tmp, sizeof tmp / sizeof (TCHAR));
+ SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)tmp);
+ WIN32GUI_LoadUIString (IDS_WSTYLE_STANDARD, tmp, sizeof tmp / sizeof (TCHAR));
+ SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)tmp);
+ WIN32GUI_LoadUIString (IDS_WSTYLE_EXTENDED, tmp, sizeof tmp / sizeof (TCHAR));
+ SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_ADDSTRING, 0, (LPARAM)tmp);
SendDlgItemMessage (hDlg, IDC_WINDOWEDMODE, CB_SETCURSEL,
workprefs.win32_borderless ? 0 : (workprefs.win32_statusbar + 1),
0);
}
}
+static void setstatefilename (HWND hDlg)
+{
+ TCHAR *s = _tcsrchr (workprefs.statefile, '\\');
+ if (s) {
+ s++;
+ } else {
+ s = _tcsrchr (workprefs.statefile, '/');
+ if (s)
+ s++;
+ }
+ if (!s)
+ s = workprefs.statefile;
+ SetDlgItemText (hDlg, IDC_STATENAME, s);
+ ew (hDlg, IDC_STATECLEAR, workprefs.statefile[0] != 0);
+ setchecked (hDlg, IDC_STATECLEAR, workprefs.statefile[0] != 0);
+}
+
static INT_PTR MiscDlgProc (HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
int v, i;
switch (msg)
{
+ case WM_INITDIALOG:
+ pages[currentpage] = hDlg;
+ InitializeListView (hDlg);
+ values_to_miscdlg (hDlg);
+ enable_for_miscdlg (hDlg);
+ setstatefilename (hDlg);
+ recursive--;
+ return TRUE;
case WM_USER:
values_to_miscdlg (hDlg);
if (((LPNMHDR) lParam)->idFrom == IDC_ASSOCIATELIST) {
int entry, col;
HWND list;
- NM_LISTVIEW *nmlistview;
- nmlistview = (NM_LISTVIEW *) lParam;
+ NM_LISTVIEW *nmlistview = (NM_LISTVIEW *)lParam;
list = nmlistview->hdr.hwndFrom;
if (nmlistview->hdr.code == NM_DBLCLK) {
entry = listview_entry_from_click (list, &col);
associate_file_extensions ();
InitializeListView (hDlg);
}
+ } else if (((LPNMHDR) lParam)->idFrom == IDC_MISCLIST) {
+ NM_LISTVIEW *nmlistview = (NM_LISTVIEW *)lParam;
+ if (nmlistview->hdr.code == LVN_ITEMCHANGED) {
+ int item = nmlistview->iItem;
+ if (item >= 0) {
+ struct miscentry *me = &misclist[item];
+ bool checked = (nmlistview->uNewState & LVIS_STATEIMAGEMASK) == 0x2000;
+ if (me->b) {
+ *me->b = checked;
+ } else if (me->i) {
+ *me->i &= ~me->imask;
+ if (checked)
+ *me->i |= me->ival & me->imask;
+ }
+ }
+ }
}
break;
associate_file_extensions ();
InitializeListView (hDlg);
break;
+ case IDC_STATECLEAR:
+ savestate_initsave (NULL, 0, 0, false);
+ _tcscpy (workprefs.statefile, savestate_fname);
+ setstatefilename (hDlg);
+ break;
case IDC_DOSAVESTATE:
- if (DiskSelection(hDlg, wParam, 9, &workprefs, 0))
+ workprefs.statefile[0] = 0;
+ if (DiskSelection(hDlg, wParam, 9, &workprefs, 0)) {
save_state (savestate_fname, _T("Description!"));
+ _tcscpy (workprefs.statefile, savestate_fname);
+ }
+ setstatefilename (hDlg);
break;
case IDC_DOLOADSTATE:
if (DiskSelection(hDlg, wParam, 10, &workprefs, 0))
savestate_state = STATE_DORESTORE;
- break;
- case IDC_ILLEGAL:
- workprefs.illegal_mem = ischecked (hDlg, IDC_ILLEGAL);
- break;
- case IDC_JULIAN:
- workprefs.win32_middle_mouse = ischecked (hDlg, IDC_JULIAN);
- break;
- case IDC_FOCUSMINIMIZE:
- workprefs.win32_minimize_inactive = ischecked (hDlg, IDC_FOCUSMINIMIZE);
- break;
- case IDC_SHOWLEDS:
- workprefs.leds_on_screen &= ~STATUSLINE_CHIPSET;
- if (ischecked (hDlg, IDC_SHOWLEDS))
- workprefs.leds_on_screen |= STATUSLINE_CHIPSET;
- break;
- case IDC_SHOWLEDSRTG:
- workprefs.leds_on_screen &= ~STATUSLINE_RTG;
- if (ischecked (hDlg, IDC_SHOWLEDSRTG))
- workprefs.leds_on_screen |= STATUSLINE_RTG;
- break;
- case IDC_SHOWGUI:
- workprefs.start_gui = ischecked (hDlg, IDC_SHOWGUI);
- break;
- case IDC_CREATELOGFILE:
- workprefs.win32_logfile = ischecked (hDlg, IDC_CREATELOGFILE);
- enable_for_miscdlg(hDlg);
- break;
- case IDC_POWERSAVE:
- workprefs.win32_powersavedisabled = ischecked (hDlg, IDC_POWERSAVE);
+ _tcscpy (workprefs.statefile, savestate_fname);
+ setstatefilename (hDlg);
break;
case IDC_INACTIVE_NOSOUND:
if (!ischecked (hDlg, IDC_INACTIVE_NOSOUND))
workprefs.win32_iconified_nosound = ischecked (hDlg, IDC_MINIMIZED_NOSOUND);
enable_for_miscdlg (hDlg);
break;
- case IDC_CTRLF11:
- workprefs.win32_ctrl_F11_is_quit = ischecked (hDlg, IDC_CTRLF11);
- break;
- case IDC_CLOCKSYNC:
- workprefs.tod_hack = ischecked (hDlg, IDC_CLOCKSYNC);
- break;
- case IDC_CLIPBOARDSHARE:
- workprefs.clipboard_sharing = ischecked (hDlg, IDC_CLIPBOARDSHARE);
- break;
- case IDC_NATIVECODE:
- workprefs.native_code = ischecked (hDlg, IDC_NATIVECODE);
- break;
- case IDC_NOTASKBARBUTTON:
- workprefs.win32_notaskbarbutton = ischecked (hDlg, IDC_NOTASKBARBUTTON);
- break;
- case IDC_ALWAYSONTOP:
- workprefs.win32_alwaysontop = ischecked (hDlg, IDC_ALWAYSONTOP);
- break;
case IDC_KBLED_USB:
workprefs.win32_kbledmode = ischecked (hDlg, IDC_KBLED_USB) ? 1 : 0;
break;
- case IDC_FASTERRTG:
- workprefs.picasso96_nocustom = ischecked (hDlg, IDC_FASTERRTG);
- break;
}
recursive--;
return TRUE;
static INT_PTR CALLBACK MiscDlgProc1 (HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
currentpage = MISC1_ID;
- if (msg == WM_INITDIALOG) {
- pages[MISC1_ID] = hDlg;
- values_to_miscdlg (hDlg);
- enable_for_miscdlg (hDlg);
- return TRUE;
- }
return MiscDlgProc (hDlg, msg, wParam, lParam);
}
static INT_PTR CALLBACK MiscDlgProc2 (HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
currentpage = MISC2_ID;
- if (msg == WM_INITDIALOG) {
- pages[MISC2_ID] = hDlg;
- InitializeListView (hDlg);
- values_to_miscdlg (hDlg);
- enable_for_miscdlg (hDlg);
- return TRUE;
- }
return MiscDlgProc (hDlg, msg, wParam, lParam);
}
- hdd from command line
- no-buffer tearing updates
+Beta 4:
+
+- Custom input event autofire wasn't always canceled when shortcut included qualifier(s).
+- Do not crash if 7zip unpacking fails because out of memory or process address space.
+ (Big compressed CD images and 32-bit Windows)
+- Log also RDB dostype in text format.
+- Replaced misc panel checkboxes with scrolling checkbox list view. Now there is unlimited space
+ for all kinds of on/off options that I previously refused to add because of lack of GUI space.
+- Added disable notification icon option.
+- Loading statefile using GUI now remembers statefile filename, allowing to save configuration files with
+ statefile (running configuration file will automatically load the statefile). This required manual config
+ file editing previously. Statefile path and checkbox that "forgets" stored path added to GUI.
+- Ignore vendor specific USB usage pages (Do not list for example some Logitech USB mouse/keyboard receiver dongles)
+- Z2 RTG + 68EC020 fixed, RTG requires memory mapping. (Memory mapping was originally JIT only and 68EC020 is not JIT compatible)
+
Beta 3:
- FPS led was always yellow in most non low latency vsync modes.
inited = 1;
oldcycles = get_cycles ();
oldoffset = -1;
+ diffsample = 0;
safepos = -RECORDBUFFER / 10 * SAMPLESIZE;
hr = lpDSB2r->GetCurrentPosition (&t, &cap_pos);
cap_pos += safepos;
- if (cap_pos > 10 * RECORDBUFFER * SAMPLESIZE)
+ if (cap_pos >= 10 * RECORDBUFFER * SAMPLESIZE)
cap_pos += RECORDBUFFER * SAMPLESIZE;
if (cap_pos >= RECORDBUFFER * SAMPLESIZE)
cap_pos -= RECORDBUFFER * SAMPLESIZE;
sampler_free ();
return 0;
}
- clockspersample = sampler_evtime / samplerate + 41000;
+ clockspersample = sampler_evtime / samplerate;
}
if (clockspersample < 1)
return 0;
if (!inited)
return;
vsynccnt++;
+ if (vsynccnt > 1) {
+ oldcycles = get_cycles ();
+ }
if (vsynccnt > 50) {
sampler_free ();
return;
if (z->parent && z->useparent)
return 0;
if (z->data) {
- int off = z->seek + l1 * l2;
+ uae_s64 off = z->seek + l1 * l2;
if (z->allocsize == 0) {
write_log (_T("zfile_fwrite(data,%s) but allocsize=0!\n"), z->name);
return 0;
size_t outSizeProcessed;
struct SevenZContext *ctx;
+ z = zfile_fopen_empty (NULL, zn->fullname, zn->size);
+ if (!z)
+ return NULL;
ctx = (struct SevenZContext*)zv->handle;
res = SzArEx_Extract (&ctx->db, &ctx->lookStream.s, zn->offset,
&ctx->blockIndex, &ctx->outBuffer, &ctx->outBufferSize,
&offset, &outSizeProcessed,
&allocImp, &allocTempImp);
if (res == SZ_OK) {
- z = zfile_fopen_empty (NULL, zn->fullname, zn->size);
zfile_fwrite (ctx->outBuffer + offset, zn->size, 1, z);
} else {
write_log (_T("7Z: SzExtract %s returned %d\n"), zn->fullname, res);
+ zfile_fclose (z);
+ z = NULL;
}
return z;
}
struct zfile *z;
z = zfile_fopen_empty (zf, path, size);
+ if (!z)
+ return NULL;
zfile_fwrite (data, size, 1, z);
memset (&zai, 0, sizeof zai);
zai.name = my_strdup (path);