mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-01-28 22:04:43 -08:00
Added patch to add winecfg Staging tab.
This commit is contained in:
parent
2971d1f90b
commit
0f0f8d3d6f
3
debian/changelog
vendored
3
debian/changelog
vendored
@ -1,4 +1,6 @@
|
||||
wine-compholio (1.7.33) UNRELEASED; urgency=low
|
||||
* Various improvements of patchupdate.py.
|
||||
* Added patches for wined3d CSMT (command stream) support.
|
||||
* Added additional tests for VerifyVersionInfoA.
|
||||
* Added patch to fix condition handling in RtlVerifyVersionInfo.
|
||||
* Added patch to set last error when GetRawInputDeviceList fails.
|
||||
@ -14,6 +16,7 @@ wine-compholio (1.7.33) UNRELEASED; urgency=low
|
||||
* Added patch to provide named entry point shell32.SHILCreateFromPath for vista apps.
|
||||
* Added patch to reallocate buffer when adding records to AVI files.
|
||||
* Added patch to implement support for loader dll redirections.
|
||||
* Added patch to add winecfg Staging tab.
|
||||
* Removed patch to fix copy and paste errors in ws2_32 tests (accepted upstream).
|
||||
* Removed patch to fix ordering of IP addresses by metric if two addresses have the same metric (accepted upstream).
|
||||
* Removed patch to reset data->pWintrustData->u.pFile->hFile after closing handle (accepted upstream).
|
||||
|
@ -119,6 +119,7 @@ PATCHLIST := \
|
||||
wine.inf-ProductId.ok \
|
||||
wineboot-HKEY_DYN_DATA.ok \
|
||||
winebuild-LinkerVersion.ok \
|
||||
winecfg-Staging.ok \
|
||||
wined3d-CSMT_Helper.ok \
|
||||
wined3d-CSMT_Main.ok \
|
||||
wined3d-DXTn.ok \
|
||||
@ -1842,6 +1843,19 @@ winebuild-LinkerVersion.ok:
|
||||
echo '+ { "Michael Müller", "winebuild: Set a valid major and minor linker version.", 1 },'; \
|
||||
) > winebuild-LinkerVersion.ok
|
||||
|
||||
# Patchset winecfg-Staging
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * programs/winecfg/Makefile.in, programs/winecfg/main.c, programs/winecfg/resource.h, programs/winecfg/staging.c,
|
||||
# | programs/winecfg/winecfg.h, programs/winecfg/winecfg.rc
|
||||
# |
|
||||
.INTERMEDIATE: winecfg-Staging.ok
|
||||
winecfg-Staging.ok: ntdll-DllRedirects.ok wined3d-CSMT_Main.ok
|
||||
$(call APPLY_FILE,winecfg-Staging/0001-winecfg-Add-staging-tab-for-CSMT.patch)
|
||||
@( \
|
||||
echo '+ { "Michael Müller", "winecfg: Add staging tab for CSMT.", 1 },'; \
|
||||
) > winecfg-Staging.ok
|
||||
|
||||
# Patchset wined3d-CSMT_Helper
|
||||
# |
|
||||
# | Modified files:
|
||||
|
@ -0,0 +1,234 @@
|
||||
From 54437590d58e0181cbeac3a55cac81b32f1485de Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sun, 14 Dec 2014 20:42:45 +0100
|
||||
Subject: winecfg: Add staging tab for CSMT.
|
||||
|
||||
---
|
||||
programs/winecfg/Makefile.in | 1 +
|
||||
programs/winecfg/main.c | 12 +++++-
|
||||
programs/winecfg/resource.h | 5 +++
|
||||
programs/winecfg/staging.c | 98 ++++++++++++++++++++++++++++++++++++++++++++
|
||||
programs/winecfg/winecfg.h | 1 +
|
||||
programs/winecfg/winecfg.rc | 10 +++++
|
||||
6 files changed, 126 insertions(+), 1 deletion(-)
|
||||
create mode 100644 programs/winecfg/staging.c
|
||||
|
||||
diff --git a/programs/winecfg/Makefile.in b/programs/winecfg/Makefile.in
|
||||
index 4e66e04..1cf7031 100644
|
||||
--- a/programs/winecfg/Makefile.in
|
||||
+++ b/programs/winecfg/Makefile.in
|
||||
@@ -11,6 +11,7 @@ C_SRCS = \
|
||||
driveui.c \
|
||||
libraries.c \
|
||||
main.c \
|
||||
+ staging.c \
|
||||
theme.c \
|
||||
winecfg.c \
|
||||
x11drvdlg.c
|
||||
diff --git a/programs/winecfg/main.c b/programs/winecfg/main.c
|
||||
index 6ac5f89..17909dc 100644
|
||||
--- a/programs/winecfg/main.c
|
||||
+++ b/programs/winecfg/main.c
|
||||
@@ -60,7 +60,7 @@ PropSheetCallback (HWND hWnd, UINT uMsg, LPARAM lParam)
|
||||
return 0;
|
||||
}
|
||||
|
||||
-#define NUM_PROPERTY_PAGES 7
|
||||
+#define NUM_PROPERTY_PAGES 8
|
||||
|
||||
static INT_PTR
|
||||
doPropertySheet (HINSTANCE hInstance, HWND hOwner)
|
||||
@@ -141,6 +141,16 @@ doPropertySheet (HINSTANCE hInstance, HWND hOwner)
|
||||
psp[pg].lParam = 0;
|
||||
pg++;
|
||||
|
||||
+ psp[pg].dwSize = sizeof (PROPSHEETPAGEW);
|
||||
+ psp[pg].dwFlags = PSP_USETITLE;
|
||||
+ psp[pg].hInstance = hInstance;
|
||||
+ psp[pg].u.pszTemplate = MAKEINTRESOURCEW (IDD_STAGING);
|
||||
+ psp[pg].u2.pszIcon = NULL;
|
||||
+ psp[pg].pfnDlgProc = StagingDlgProc;
|
||||
+ psp[pg].pszTitle = load_string (IDS_TAB_STAGING);
|
||||
+ psp[pg].lParam = 0;
|
||||
+ pg++;
|
||||
+
|
||||
/*
|
||||
* Fill out the (General) PROPSHEETPAGE data structure
|
||||
* for the property sheet
|
||||
diff --git a/programs/winecfg/resource.h b/programs/winecfg/resource.h
|
||||
index fffc4da..7fb90f4 100644
|
||||
--- a/programs/winecfg/resource.h
|
||||
+++ b/programs/winecfg/resource.h
|
||||
@@ -45,6 +45,7 @@
|
||||
#define IDS_SHELL_FOLDER 16
|
||||
#define IDS_LINKS_TO 17
|
||||
#define IDS_WINECFG_TITLE_APP 18 /* App specific title */
|
||||
+#define IDS_TAB_STAGING 19
|
||||
#define IDI_WINECFG 100
|
||||
#define IDI_LOGO 102
|
||||
#define IDD_ABOUTCFG 107
|
||||
@@ -54,6 +55,7 @@
|
||||
#define IDD_DLLCFG 111
|
||||
#define IDD_DRIVECFG 112
|
||||
#define IDD_DESKTOP_INTEGRATION 115
|
||||
+#define IDD_STAGING 116
|
||||
#define IDC_WINVER 1012
|
||||
#define IDC_DESKTOP_WIDTH 1023
|
||||
#define IDC_DESKTOP_HEIGHT 1024
|
||||
@@ -202,6 +204,9 @@
|
||||
#define IDC_SYSPARAMS_MENU_HILIGHT 8430
|
||||
#define IDC_SYSPARAMS_MENUBAR 8431
|
||||
|
||||
+/* graphics */
|
||||
+#define IDC_ENABLE_CSMT 9001
|
||||
+
|
||||
/* About tab */
|
||||
#define IDC_ABT_OWNER 8432
|
||||
#define IDC_ABT_ORG 8433
|
||||
diff --git a/programs/winecfg/staging.c b/programs/winecfg/staging.c
|
||||
new file mode 100644
|
||||
index 0000000..1d6cef9
|
||||
--- /dev/null
|
||||
+++ b/programs/winecfg/staging.c
|
||||
@@ -0,0 +1,98 @@
|
||||
+/*
|
||||
+ * WineCfg Staging panel
|
||||
+ *
|
||||
+ * Copyright 2014 Michael Müller
|
||||
+ *
|
||||
+ * This library is free software; you can redistribute it and/or
|
||||
+ * modify it under the terms of the GNU Lesser General Public
|
||||
+ * License as published by the Free Software Foundation; either
|
||||
+ * version 2.1 of the License, or (at your option) any later version.
|
||||
+ *
|
||||
+ * This library is distributed in the hope that it will be useful,
|
||||
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
+ * Lesser General Public License for more details.
|
||||
+ *
|
||||
+ * You should have received a copy of the GNU Lesser General Public
|
||||
+ * License along with this library; if not, write to the Free Software
|
||||
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
+ *
|
||||
+ */
|
||||
+
|
||||
+#define COBJMACROS
|
||||
+
|
||||
+#include "config.h"
|
||||
+
|
||||
+#include <windows.h>
|
||||
+#include <wine/unicode.h>
|
||||
+#include <wine/debug.h>
|
||||
+
|
||||
+#include "resource.h"
|
||||
+#include "winecfg.h"
|
||||
+
|
||||
+WINE_DEFAULT_DEBUG_CHANNEL(winecfg);
|
||||
+
|
||||
+static WCHAR redirects_keyW[] = {'S','o','f','t','w','a','r','e','\\','W','i','n','e','\\',
|
||||
+ 'D','l','l','R','e','d','i','r','e','c','t','s',0};
|
||||
+static WCHAR wined3dW[] = {'w','i','n','e','d','3','d',0};
|
||||
+static WCHAR wined3d_csmtW[] = {'w','i','n','e','d','3','d','-','c','s','m','t','.','d','l','l',0};
|
||||
+
|
||||
+static BOOL csmt_get(void)
|
||||
+{
|
||||
+ BOOL ret = FALSE;
|
||||
+ WCHAR *redirect = get_reg_keyW(HKEY_CURRENT_USER, redirects_keyW, wined3dW, NULL);
|
||||
+ if (!redirect) return FALSE;
|
||||
+
|
||||
+ if (strcmpW(redirect, wined3d_csmtW) == 0)
|
||||
+ ret = TRUE;
|
||||
+
|
||||
+ HeapFree(GetProcessHeap(), 0, redirect);
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+static void csmt_set(BOOL status)
|
||||
+{
|
||||
+ if (csmt_get() == status)
|
||||
+ return;
|
||||
+
|
||||
+ set_reg_keyW(HKEY_CURRENT_USER, redirects_keyW, wined3dW, status ? wined3d_csmtW : NULL);
|
||||
+}
|
||||
+
|
||||
+static void csmt_clicked(HWND dialog)
|
||||
+{
|
||||
+ csmt_set(IsDlgButtonChecked(dialog, IDC_ENABLE_CSMT) == BST_CHECKED);
|
||||
+}
|
||||
+
|
||||
+static void initStagingDlg(HWND dialog)
|
||||
+{
|
||||
+ CheckDlgButton(dialog, IDC_ENABLE_CSMT, csmt_get() ? BST_CHECKED : BST_UNCHECKED);
|
||||
+}
|
||||
+
|
||||
+INT_PTR CALLBACK StagingDlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
+{
|
||||
+ switch (uMsg)
|
||||
+ {
|
||||
+ case WM_NOTIFY:
|
||||
+ break;
|
||||
+
|
||||
+ case WM_INITDIALOG:
|
||||
+ initStagingDlg(hDlg);
|
||||
+ return TRUE;
|
||||
+
|
||||
+ case WM_SHOWWINDOW:
|
||||
+ set_window_title(hDlg);
|
||||
+ break;
|
||||
+
|
||||
+ case WM_DESTROY:
|
||||
+ break;
|
||||
+
|
||||
+ case WM_COMMAND:
|
||||
+ if (LOWORD(wParam) == IDC_ENABLE_CSMT && HIWORD(wParam) == BN_CLICKED)
|
||||
+ {
|
||||
+ csmt_clicked(hDlg);
|
||||
+ SendMessageW(GetParent(hDlg), PSM_CHANGED, 0, 0);
|
||||
+ }
|
||||
+ break;
|
||||
+ }
|
||||
+ return FALSE;
|
||||
+}
|
||||
diff --git a/programs/winecfg/winecfg.h b/programs/winecfg/winecfg.h
|
||||
index 110856a..a949474 100644
|
||||
--- a/programs/winecfg/winecfg.h
|
||||
+++ b/programs/winecfg/winecfg.h
|
||||
@@ -87,6 +87,7 @@ INT_PTR CALLBACK AppDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
INT_PTR CALLBACK LibrariesDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||
INT_PTR CALLBACK AudioDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||
INT_PTR CALLBACK ThemeDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||
+INT_PTR CALLBACK StagingDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||
INT_PTR CALLBACK AboutDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||
|
||||
/* Drive management */
|
||||
diff --git a/programs/winecfg/winecfg.rc b/programs/winecfg/winecfg.rc
|
||||
index 9f763a7..ad3e842 100644
|
||||
--- a/programs/winecfg/winecfg.rc
|
||||
+++ b/programs/winecfg/winecfg.rc
|
||||
@@ -39,6 +39,7 @@ BEGIN
|
||||
IDS_TAB_GRAPHICS "Graphics"
|
||||
IDS_TAB_DESKTOP_INTEGRATION "Desktop Integration"
|
||||
IDS_TAB_AUDIO "Audio"
|
||||
+ IDS_TAB_STAGING "Staging"
|
||||
IDS_TAB_ABOUT "About"
|
||||
IDS_WINECFG_TITLE "Wine configuration"
|
||||
IDS_WINECFG_TITLE_APP "Wine configuration for %s"
|
||||
@@ -297,6 +298,15 @@ BEGIN
|
||||
PUSHBUTTON "B&rowse...",IDC_BROWSE_SFPATH,195,195,50,13,WS_DISABLED
|
||||
END
|
||||
|
||||
+IDD_STAGING DIALOG 0, 0, 260, 220
|
||||
+STYLE WS_CHILD | WS_DISABLED
|
||||
+FONT 8, "MS Shell Dlg"
|
||||
+BEGIN
|
||||
+ GROUPBOX "Staging settings",IDC_STATIC,8,4,244,210
|
||||
+ LTEXT "The following settings are experimental and may break stuff!\nMake sure to reset them again in case of a problem.",IDC_STATIC,16,16,230,16
|
||||
+ CONTROL "Enable &CSMT for better graphic performance",IDC_ENABLE_CSMT,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,40,230,8
|
||||
+END
|
||||
+
|
||||
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
||||
|
||||
/* @makedep: winecfg.ico */
|
||||
--
|
||||
2.1.3
|
||||
|
2
patches/winecfg-Staging/definition
Normal file
2
patches/winecfg-Staging/definition
Normal file
@ -0,0 +1,2 @@
|
||||
Depends: wined3d-CSMT_Main
|
||||
Depends: ntdll-DllRedirects
|
Loading…
x
Reference in New Issue
Block a user