On Sat, Jul 23, 2016 at 8:01 AM, Corentin Rossignon corossig@gmail.com wrote:
Signed-off-by: Corentin Rossignon corossig@gmail.com
dlls/dinput/joystick_linux.c | 34 +++++++++++++++++++++++++++++++--- dlls/dinput/joystick_linuxinput.c | 27 +++++++++++++++++++++++++-- 2 files changed, 56 insertions(+), 5 deletions(-)
Formatting problem:
bruno@Note:~/programs/wine$ git apply dinput2 dinput2:31: trailing whitespace. /* dinput2:35: trailing whitespace. * Data4 seems to be a constant. dinput2:104: trailing whitespace. /* dinput2:108: trailing whitespace. * Data4 seems to be a constant. warning: 4 lines add whitespace errors.
diff --git a/dlls/dinput/joystick_linux.c b/dlls/dinput/joystick_linux.c index 90b7280..f8499ca 100644 --- a/dlls/dinput/joystick_linux.c +++ b/dlls/dinput/joystick_linux.c @@ -77,6 +77,7 @@ struct JoyDev { char device[MAX_PATH]; char name[MAX_PATH];
GUID guid_product;
BYTE axis_count; BYTE button_count;
@@ -122,6 +123,21 @@ static const GUID DInput_Wine_Joystick_GUID = { /* 9e573ed9-7734-11d2-8d4a-23903 {0x8d, 0x4a, 0x23, 0x90, 0x3f, 0xb6, 0xbd, 0xf7} };
+/*
- Construct the GUID in the same way of Windows doing this.
- Data1 is concatenation of productid and vendorid.
- Data2 and Data3 are NULL.
- Data4 seems to be a constant.
- */
+static const GUID DInput_Wine_Joystick_Constant_Part_GUID = {
- 0x000000000,
- 0x0000,
- 0x0000,
- {0x00, 0x00, 0x50, 0x49, 0x44, 0x56, 0x49, 0x44}
+};
Please remove all double blank lines in your changes in order to be more compatible with the surrounding code style.
Done, thanks for taking some times and helping me doing a proper patch.
On 07/24/2016 12:03 AM, Bruno Jesus wrote:
On Sat, Jul 23, 2016 at 8:01 AM, Corentin Rossignon corossig@gmail.com wrote:
Signed-off-by: Corentin Rossignon corossig@gmail.com
dlls/dinput/joystick_linux.c | 34 +++++++++++++++++++++++++++++++--- dlls/dinput/joystick_linuxinput.c | 27 +++++++++++++++++++++++++-- 2 files changed, 56 insertions(+), 5 deletions(-)
Formatting problem:
bruno@Note:~/programs/wine$ git apply dinput2 dinput2:31: trailing whitespace. /* dinput2:35: trailing whitespace.
- Data4 seems to be a constant.
dinput2:104: trailing whitespace. /* dinput2:108: trailing whitespace.
- Data4 seems to be a constant.
warning: 4 lines add whitespace errors.
diff --git a/dlls/dinput/joystick_linux.c b/dlls/dinput/joystick_linux.c index 90b7280..f8499ca 100644 --- a/dlls/dinput/joystick_linux.c +++ b/dlls/dinput/joystick_linux.c @@ -77,6 +77,7 @@ struct JoyDev { char device[MAX_PATH]; char name[MAX_PATH];
GUID guid_product;
BYTE axis_count; BYTE button_count;
@@ -122,6 +123,21 @@ static const GUID DInput_Wine_Joystick_GUID = { /* 9e573ed9-7734-11d2-8d4a-23903 {0x8d, 0x4a, 0x23, 0x90, 0x3f, 0xb6, 0xbd, 0xf7} };
+/*
- Construct the GUID in the same way of Windows doing this.
- Data1 is concatenation of productid and vendorid.
- Data2 and Data3 are NULL.
- Data4 seems to be a constant.
- */
+static const GUID DInput_Wine_Joystick_Constant_Part_GUID = {
- 0x000000000,
- 0x0000,
- 0x0000,
- {0x00, 0x00, 0x50, 0x49, 0x44, 0x56, 0x49, 0x44}
+};
Please remove all double blank lines in your changes in order to be more compatible with the surrounding code style.
I'm not really familiar with the intricacies of the guid generation ... but looking at the Mac dinput code ... should a similar patch be applied there?
Cheers, David
On Sun, Jul 24, 2016 at 3:15 AM, Corentin Rossignon corossig@gmail.com wrote:
Done, thanks for taking some times and helping me doing a proper patch.
On 07/24/2016 12:03 AM, Bruno Jesus wrote:
On Sat, Jul 23, 2016 at 8:01 AM, Corentin Rossignon corossig@gmail.com wrote:
Signed-off-by: Corentin Rossignon corossig@gmail.com
dlls/dinput/joystick_linux.c | 34 +++++++++++++++++++++++++++++++--- dlls/dinput/joystick_linuxinput.c | 27 +++++++++++++++++++++++++-- 2 files changed, 56 insertions(+), 5 deletions(-)
Formatting problem:
bruno@Note:~/programs/wine$ git apply dinput2 dinput2:31: trailing whitespace. /* dinput2:35: trailing whitespace.
- Data4 seems to be a constant.
dinput2:104: trailing whitespace. /* dinput2:108: trailing whitespace.
- Data4 seems to be a constant.
warning: 4 lines add whitespace errors.
diff --git a/dlls/dinput/joystick_linux.c b/dlls/dinput/joystick_linux.c
index 90b7280..f8499ca 100644 --- a/dlls/dinput/joystick_linux.c +++ b/dlls/dinput/joystick_linux.c @@ -77,6 +77,7 @@ struct JoyDev { char device[MAX_PATH]; char name[MAX_PATH];
GUID guid_product;
BYTE axis_count; BYTE button_count;
@@ -122,6 +123,21 @@ static const GUID DInput_Wine_Joystick_GUID = { /* 9e573ed9-7734-11d2-8d4a-23903 {0x8d, 0x4a, 0x23, 0x90, 0x3f, 0xb6, 0xbd, 0xf7} };
+/*
- Construct the GUID in the same way of Windows doing this.
- Data1 is concatenation of productid and vendorid.
- Data2 and Data3 are NULL.
- Data4 seems to be a constant.
- */
+static const GUID DInput_Wine_Joystick_Constant_Part_GUID = {
- 0x000000000,
- 0x0000,
- 0x0000,
- {0x00, 0x00, 0x50, 0x49, 0x44, 0x56, 0x49, 0x44}
+};
Please remove all double blank lines in your changes in order to be more compatible with the surrounding code style.
On Thu, Jul 28, 2016 at 6:08 AM, DavidL david.dljunk@gmail.com wrote:
I'm not really familiar with the intricacies of the guid generation ... but looking at the Mac dinput code ... should a similar patch be applied there?
Hi, IMO yes in order to sync the output of all drivers to be the same independent of host OS. You can test using the ditool.exe from: https://sourceforge.net/projects/x360ce/files/ditool.zip
Best wishes, Bruno
Thanks!
In that case, I will add it to my list of needed patches for the OS X dinput joysticks ... unless one of you gents would like to take a crack at it? :)
Cheers, David
On Thu, Jul 28, 2016 at 8:44 AM, Bruno Jesus 00cpxxx@gmail.com wrote:
On Thu, Jul 28, 2016 at 6:08 AM, DavidL david.dljunk@gmail.com wrote:
I'm not really familiar with the intricacies of the guid generation ...
but
looking at the Mac dinput code ... should a similar patch be applied
there?
Hi, IMO yes in order to sync the output of all drivers to be the same independent of host OS. You can test using the ditool.exe from: https://sourceforge.net/projects/x360ce/files/ditool.zip
Best wishes, Bruno