]> git.unchartedbackwaters.co.uk Git - francis/winuae.git/commitdiff
2500b17
authorToni Wilen <twilen@winuae.net>
Mon, 10 Sep 2012 16:08:51 +0000 (19:08 +0300)
committerToni Wilen <twilen@winuae.net>
Mon, 10 Sep 2012 16:08:51 +0000 (19:08 +0300)
cfgfile.cpp
filesys.cpp
main.cpp
od-win32/direct3d.cpp
od-win32/resources/winuae.rc
od-win32/win32.cpp
od-win32/win32.h
od-win32/win32gfx.cpp
od-win32/win32gui.cpp
od-win32/winuaechangelog.txt

index 3e2dcbd45854ad1091c50f3d6cdf63e859430fb5..ef171a91ab2a45a2e0e5f88a8a4ebedd274228f0 100644 (file)
@@ -5120,7 +5120,7 @@ void config_check_vsync (void)
 //             if (config_changed == 1)
 //                     write_log (_T("* configuration check trigger\n"));
                config_changed++;
-               if (config_changed > 10)
+               if (config_changed >= 3)
                        config_changed = 0;
        }
 }
index 6924c2b759fc879c4992ade890dce91bd673345a..77414b54a100a3cf73f4a9bdee90a5b886894527 100644 (file)
@@ -677,13 +677,12 @@ static void allocuci (struct uae_prefs *p, int nr, int idx)
 static void initialize_mountinfo (void)
 {
        int nr;
-       struct uaedev_config_info *uci;
        UnitInfo *uip = &mountinfo.ui[0];
 
        cd_unit_offset = MAX_FILESYSTEM_UNITS;
 
        for (nr = 0; nr < currprefs.mountitems; nr++) {
-               uci = &currprefs.mountconfig[nr];
+               struct uaedev_config_info *uci = &currprefs.mountconfig[nr];
                if (uci->controller == HD_CONTROLLER_UAE) {
                        int idx = set_filesys_unit_1 (-1, uci->devname, uci->ishdf ? NULL : uci->volname, uci->rootdir,
                                uci->readonly, uci->sectors, uci->surfaces, uci->reserved,
@@ -712,6 +711,7 @@ static void initialize_mountinfo (void)
 #endif
 
        for (nr = 0; nr < currprefs.mountitems; nr++) {
+               struct uaedev_config_info *uci = &currprefs.mountconfig[nr];
                if (uci->controller == HD_CONTROLLER_UAE)
                        continue;
                if (uci->controller <= HD_CONTROLLER_IDE3) {
index 9f4839c7122131b95d3d687ae065938a6c35154c..c4a8e4ee5bdb53e23b98044ffcadb39972692feb 100644 (file)
--- a/main.cpp
+++ b/main.cpp
@@ -570,7 +570,19 @@ static void parse_cmdline_2 (int argc, TCHAR **argv)
        }
 }
 
-static void parse_diskswapper (TCHAR *s)
+static int diskswapper_cb (struct zfile *f, void *vrsd)
+{
+       int *num = (int*)vrsd;
+       if (*num >= MAX_SPARE_DRIVES)
+               return 1;
+       if (zfile_gettype (f) ==  ZFILE_DISKIMAGE) {
+               _tcsncpy (currprefs.dfxlist[*num], zfile_getname (f), 255);
+               (*num)++;
+       }
+       return 0;
+}
+
+static void parse_diskswapper (const TCHAR *s)
 {
        TCHAR *tmp = my_strdup (s);
        TCHAR *delim = _T(",");
@@ -585,8 +597,10 @@ static void parse_diskswapper (TCHAR *s)
                p1 = NULL;
                if (num >= MAX_SPARE_DRIVES)
                        break;
-               _tcsncpy (currprefs.dfxlist[num], p2, 255);
-               num++;
+               if (!zfile_zopen (p2, diskswapper_cb, &num)) {
+                       _tcsncpy (currprefs.dfxlist[num], p2, 255);
+                       num++;
+               }
        }
        free (tmp);
 }
index 97b5ec969cabf273d527d4410fb22a403b51fc69..a1f484f912cd3d93dc113ddafc733d9c6ee3e290 100644 (file)
@@ -1625,7 +1625,7 @@ static void setupscenecoords (void)
        fakesize.w = 1;
        fakesize.z = 1;
 
-       MatrixOrthoOffCenterLH (&m_matProj, 0, w, 0, h, 0.0f, 1.0f);
+       MatrixOrthoOffCenterLH (&m_matProj, 0, w + 0.05f, 0, h + 0.05f, 0.0f, 1.0f);
 
        float tx, ty;
        float sw, sh;
@@ -1665,8 +1665,8 @@ static void setupscenecoords (void)
                sw = dw * tin_w / window_w;
                sh = dh * tin_h / window_h;
 
-               sw -= 0.5f;
-               sh += 0.5f;
+               //sw -= 0.5f;
+               //sh += 0.5f;
 
                tx += xshift;
                ty += yshift;
@@ -1675,7 +1675,7 @@ static void setupscenecoords (void)
 
        MatrixTranslation (&m_matView, tx, ty, 1.0f);
 
-       MatrixScaling (&m_matWorld, sw, sh, 1.0f);
+       MatrixScaling (&m_matWorld, sw + 0.5f / sw, sh + 0.5f / sh, 1.0f);
 
        cursor_offset_x = -zr.left;
        cursor_offset_y = -zr.top;
@@ -1686,8 +1686,8 @@ static void setupscenecoords (void)
        float sw2 = dw * tin_w / window_w;
        float sh2 = dh * tin_h / window_h;
 
-       sw2 -= 0.5f;
-       sh2 += 0.5f;
+       //sw2 -= 0.5f;
+       //sh2 += 0.5f;
 
        maskmult.x = sw2 * maskmult_x / w;
        maskmult.y = sh2 * maskmult_y / h;
index 483e9035e716f62794b36ec68dd6aca43ecaef9b..f0d8db9bdbedd40bede5a24d29b4a7cc3d03b37b 100644 (file)
@@ -599,45 +599,45 @@ BEGIN
     PUSHBUTTON      "Cancel",IDCANCEL,201,57,48,15\r
 END\r
 \r
-IDD_CHIPSET DIALOGEX 0, 0, 302, 172\r
+IDD_CHIPSET DIALOGEX 0, 0, 396, 169\r
 STYLE DS_LOCALEDIT | DS_SETFONT | DS_3DLOOK | DS_CONTROL | WS_CHILD\r
 FONT 8, "MS Sans Serif", 0, 0, 0x0\r
 BEGIN\r
-    GROUPBOX        "Chipset",IDC_STATIC,1,0,160,111\r
+    GROUPBOX        "Chipset",IDC_STATIC,1,0,212,111\r
     CONTROL         "OCS [] Original chipset. A1000 and most A500s.",IDC_OCS,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,9,15,73,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,14,15,88,10\r
     CONTROL         "ECS Agnus [] Enhanced chipset (ECS Agnus chip only). CDTV and later A500 and A2000 hardware revisions.",IDC_ECS_AGNUS,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,9,31,73,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,14,31,88,10\r
     CONTROL         "Full ECS [] Full ECS chipset (ECS Agnus and ECS Denise chips). A500+, A600 and A3000.",IDC_ECS,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,9,47,73,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,14,47,88,10\r
     CONTROL         "AGA [] Advanced Graphics Architecture chipset. A1200, A4000 and CD32.",IDC_AGA,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,86,15,72,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,114,15,86,10\r
     CONTROL         "ECS Denise [] Enhanced chipset (ECS Denise chip only). Normally paired with ECS Agnus.",IDC_ECS_DENISE,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,86,31,72,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,114,31,86,10\r
     CONTROL         "NTSC [] North American and Japanese display standard, 60Hz refresh rate. Other countries use PAL (50Hz. display refresh rate)",IDC_NTSC,\r
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,86,47,72,10\r
+                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,114,47,86,10\r
     CONTROL         "Cycle-exact [] The most compatible A500/A1200 emulation mode. Very fast PC recommended.",IDC_CYCLEEXACT,\r
-                    "Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,9,69,139,10\r
-    RTEXT           "Chipset Extra",IDC_STATIC,11,89,71,15,SS_CENTERIMAGE\r
-    COMBOBOX        IDC_CS_EXT,86,90,49,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
-    GROUPBOX        "Options",IDC_STATIC,167,0,133,111\r
+                    "Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,25,69,170,10\r
+    RTEXT           "Chipset Extra",IDC_STATIC,30,89,71,15,SS_CENTERIMAGE\r
+    COMBOBOX        IDC_CS_EXT,105,90,49,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
+    GROUPBOX        "Options",IDC_STATIC,221,0,173,111\r
     CONTROL         "Immediate Blitter [] Faster but less compatible blitter emulation.",IDC_BLITIMM,\r
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,180,16,116,10\r
+                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,234,16,150,10\r
     CONTROL         "Wait for Blitter [] Compatibility hack for programs that don't wait for the blitter correctly, causing graphics corruption if CPU is too fast.",IDC_BLITWAIT,\r
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,180,29,116,10\r
+                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,234,29,150,10\r
     CONTROL         "Genlock connected [] Allow boot sequence to detect genlock. Genlock is not emulated.",IDC_GENLOCK,\r
-                    "Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,180,42,116,10\r
-    CTEXT           "External display hardware:",IDC_STATIC,174,59,117,15,SS_CENTERIMAGE\r
-    COMBOBOX        IDC_MONITOREMU,184,78,98,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
-    GROUPBOX        "Collision Level",IDC_STATIC,1,116,299,48\r
+                    "Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,234,42,150,10\r
+    CTEXT           "External display hardware:",IDC_STATIC,228,59,117,15,SS_CENTERIMAGE\r
+    COMBOBOX        IDC_MONITOREMU,238,78,98,65,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP\r
+    GROUPBOX        "Collision Level",IDC_STATIC,1,116,393,48\r
     CONTROL         "None [] Collision hardware emulation disabled.",IDC_COLLISION0,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,9,132,101,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,47,132,101,10\r
     CONTROL         "Sprites only [] Emulate only sprite vs. sprite collisions.",IDC_COLLISION1,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,9,147,101,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,47,147,101,10\r
     CONTROL         "Sprites and Sprites vs. Playfield [] Recommended collision emulation level.",IDC_COLLISION2,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,115,132,181,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,182,132,181,10\r
     CONTROL         "Full [] 100% collision hardware emulation. Only very few games need this option. Slowest.",IDC_COLLISION3,\r
-                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,115,147,181,10\r
+                    "Button",BS_AUTORADIOBUTTON | WS_TABSTOP,182,147,181,10\r
 END\r
 \r
 IDD_CHIPSET2 DIALOGEX 0, 0, 396, 288\r
@@ -1312,7 +1312,6 @@ BEGIN
 \r
     IDD_CHIPSET, DIALOG\r
     BEGIN\r
-        BOTTOMMARGIN, 162\r
     END\r
 \r
     IDD_CHIPSET2, DIALOG\r
index f96a52a5897c5e48d456551e4d6f59dfe3500dad..13ee13d07238e71206620a80268c6bf122ab5e3c 100644 (file)
@@ -303,6 +303,7 @@ frame_time_t read_processor_time_rdtsc (void)
 }
 frame_time_t read_processor_time (void)
 {
+       frame_time_t t;
 #if 0
        static int cnt;
 
@@ -313,9 +314,10 @@ frame_time_t read_processor_time (void)
        }
 #endif
        if (userdtsc)
-               return read_processor_time_rdtsc ();
+               t = read_processor_time_rdtsc ();
        else
-               return read_processor_time_qpf ();
+               t = read_processor_time_qpf ();
+       return t;
 }
 
 uae_u32 read_system_time (void)
index e538a6e8dde4e071c4d86cf5025305188285f659..e43bfa7957d745b319a126d8ae319816ca1962d4 100644 (file)
 #define LANG_DLL 1
 
 //#define WINUAEBETA _T("")
-#define WINUAEBETA _T("16")
-#define WINUAEDATE MAKEBD(2012, 9, 8)
+#define WINUAEBETA _T("17")
+#define WINUAEDATE MAKEBD(2012, 9, 10)
 #define WINUAEEXTRA _T("")
 //#define WINUAEEXTRA _T("AmiKit Preview")
 #define WINUAEREV _T("")
 
 #define IHF_WINDOWHIDDEN 6
-#define NORMAL_WINDOW_STYLE (WS_BORDER | WS_CAPTION | WS_MINIMIZEBOX | WS_SYSMENU | WS_SIZEBOX)
-
 #define WINUAEAPPNAME _T("Arabuusimiehet.WinUAE")
 extern HMODULE hUIDLL;
 extern HWND hAmigaWnd, hMainWnd, hHiddenWnd, hGUIWnd;
index 09fc5f417825109ff033caa19f0bb95455d7e553..607031ee962ef4cb105dc0ee5159c5f27fab7ab3 100644 (file)
@@ -3379,14 +3379,13 @@ static int create_windows_2 (void)
        int dxfs = currentmode->flags & (DM_DX_FULLSCREEN);
        int d3dfs = currentmode->flags & (DM_D3D_FULLSCREEN);
        int fsw = currentmode->flags & (DM_W_FULLSCREEN);
-       DWORD exstyle = currprefs.win32_notaskbarbutton ? WS_EX_TOOLWINDOW : WS_EX_APPWINDOW;
+       DWORD exstyle = (currprefs.win32_notaskbarbutton ? WS_EX_TOOLWINDOW : WS_EX_APPWINDOW) | 0;
        DWORD flags = 0;
        int borderless = currprefs.win32_borderless;
-       DWORD style = NORMAL_WINDOW_STYLE | WS_CLIPCHILDREN | WS_CLIPSIBLINGS;
-       int cymenu = currprefs.win32_statusbar == 0 ? 0 : GetSystemMetrics (SM_CYMENU);
-       int cyborder = GetSystemMetrics (SM_CYBORDER);
-       int cxborder = GetSystemMetrics (SM_CXBORDER);
-       int gap = 3;
+       DWORD style = WS_OVERLAPPEDWINDOW | WS_CLIPCHILDREN | WS_CLIPSIBLINGS;
+       int sbheight = currprefs.win32_statusbar == 0 ? 0 : GetSystemMetrics (SM_CYMENU) + 3;
+       int cyborder = GetSystemMetrics (SM_CYFRAME);
+       int gap = 0;
        int x, y, w, h;
        struct MultiDisplay *md = getdisplay (&currprefs);
 
@@ -3441,8 +3440,8 @@ static int create_windows_2 (void)
                                y = r.top;
                                SetWindowPos (hMainWnd, HWND_TOP, x, y, w + window_extra_width, h + window_extra_height,
                                        SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSENDCHANGING | SWP_NOZORDER);
-                               x = gap - 1;
-                               y = gap - 2;
+                               x = gap;
+                               y = gap;
                        }
                        SetWindowPos (hAmigaWnd, HWND_TOP, x, y, w, h,
                                SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSENDCHANGING | SWP_NOZORDER);
@@ -3471,13 +3470,13 @@ static int create_windows_2 (void)
        window_led_drives = 0;
        window_led_drives_end = 0;
        hMainWnd = NULL;
-       x = 2; y = 2;
+       x = 0; y = 0;
        if (borderless)
-               cymenu = cyborder = cxborder = 0;
+               sbheight = cyborder = 0;
 
        if (!dxfs && !d3dfs)  {
                RECT rc;
-               int stored_x = 1, stored_y = cymenu + cyborder;
+               int stored_x = 1, stored_y = sbheight + cyborder;
                int oldx, oldy;
                int first = 2;
 
@@ -3493,8 +3492,8 @@ static int create_windows_2 (void)
                        first--;
                        if (stored_x < GetSystemMetrics (SM_XVIRTUALSCREEN))
                                stored_x = GetSystemMetrics (SM_XVIRTUALSCREEN);
-                       if (stored_y < GetSystemMetrics (SM_YVIRTUALSCREEN) + cymenu + cyborder)
-                               stored_y = GetSystemMetrics (SM_YVIRTUALSCREEN) + cymenu + cyborder;
+                       if (stored_y < GetSystemMetrics (SM_YVIRTUALSCREEN) + sbheight + cyborder)
+                               stored_y = GetSystemMetrics (SM_YVIRTUALSCREEN) + sbheight + cyborder;
 
                        if (stored_x > GetSystemMetrics (SM_CXVIRTUALSCREEN))
                                rc.left = 1;
@@ -3506,8 +3505,8 @@ static int create_windows_2 (void)
                        else
                                rc.top = stored_y;
 
-                       rc.right = rc.left + gap + currentmode->current_width + gap - 2;
-                       rc.bottom = rc.top + gap + currentmode->current_height + gap + cymenu - 1 - 2;
+                       rc.right = rc.left + gap + currentmode->current_width + gap;
+                       rc.bottom = rc.top + gap + currentmode->current_height + gap + sbheight;
 
                        oldx = rc.left;
                        oldy = rc.top;
@@ -3538,7 +3537,7 @@ static int create_windows_2 (void)
                                _T("PCsuxRox"), _T("WinUAE"),
                                style,
                                rc.left, rc.top,
-                               rc.right - rc.left + 1, rc.bottom - rc.top + 1,
+                               rc.right - rc.left, rc.bottom - rc.top,
                                NULL, NULL, hInst, NULL);
                        if (!hMainWnd) {
                                write_log (_T("main window creation failed\n"));
@@ -3594,14 +3593,17 @@ static int create_windows_2 (void)
                close_hwnds ();
                return 0;
        }
-       if (hMainWnd == NULL)
+       if (hMainWnd == NULL) {
                hMainWnd = hAmigaWnd;
+       }
+
        GetWindowRect (hAmigaWnd, &amigawin_rect);
        GetWindowRect (hMainWnd, &mainwin_rect);
        if (dxfs || d3dfs)
                SetCursorPos (x + w / 2, y + h / 2);
        addnotifications (hAmigaWnd, FALSE, FALSE);
        createblankwindows ();
+
        if (hMainWnd != hAmigaWnd) {
                if (!currprefs.headless && !rp_isactive ())
                        ShowWindow (hMainWnd, firstwindow ? (currprefs.win32_start_minimized ? SW_SHOWMINIMIZED : SW_SHOWDEFAULT) : SW_SHOWNORMAL);
index 5344cd6e310a6e899f1c511708f970e976aa4db9..181e42c4558eb20e374bffd55a6fab0321f2d94f 100644 (file)
@@ -4805,8 +4805,7 @@ static void savelog (int all)
                copylog (_T("winuaebootlog"), bootlogpath, f);
                copylog (_T("winuaelog"), logpath, f);
                fputws (_T("\n"), f);
-               fputws (_T("configuration:"), f);
-               fputws (_T(":\n"), f);
+               fputws (_T("configuration:\n"), f);
                fputws (_T("\n"), f);
                saveconfig (f);
                fclose (f);
@@ -6383,7 +6382,7 @@ static INT_PTR CALLBACK DisplayDlgProc (HWND hDlg, UINT msg, WPARAM wParam, LPAR
                if (LOWORD (wParam) == IDC_DA_RESET) {
                        int *p;
                        da_mode_selected = SendDlgItemMessage (hDlg, IDC_DA_MODE, CB_GETCURSEL, 0, 0);
-                       p = getp_da();
+                       p = getp_da ();
                        if (p)
                                *p = 0;
                        init_da (hDlg);
index 9ed441e83be333319fd7d139b528644daa08678c..0b0262073924b3cde444a6f7c1956151ba182d98 100644 (file)
@@ -1,8 +1,18 @@
-- Use dos.library to detect between 1.x and 2.x (CDTV KS 1.3 + 2.x extended = exec is v37!)
-- Removable disk support was disabled.
+
+- Use dos.library version to detect between 1.x and 2.x+ . CDTV KS 1.3 + 2.x extended ROM = v37 exec.
+- Enabled removable media support.
+- Merged new offical SVN updates.
 
 - restore only single input target to default.
 
+Beta 17:
+
+- Enabled windowed mode window maximize button.
+- Removed windowed mode window inner edge.
+- -diskswapper command line looks inside all supported archive files.
+- Any non-UAE controller harddrive didn't work. (b16)
+- Beta 16 D3D alignment fix updated, previous broke 1:1 pixel mapping in some situations.
+
 Beta 16:
 
 - Added easy to use log options to Paths panel. Open = open selected log or current config to text editor.