winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
June 2018
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
1 participants
629 discussions
Start a n
N
ew thread
Józef Kucia : ninput: Add ProcessInertiaInteractionContext() stub.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 116ad14952633346a7d37952cc5dd3a46ad69e6e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=116ad14952633346a7d37952…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Thu Jun 21 16:19:43 2018 +0200 ninput: Add ProcessInertiaInteractionContext() stub. Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ninput/main.c | 6 ++++++ dlls/ninput/ninput.spec | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/dlls/ninput/main.c b/dlls/ninput/main.c index 1aa3c46..932d159 100644 --- a/dlls/ninput/main.c +++ b/dlls/ninput/main.c @@ -72,6 +72,12 @@ HRESULT WINAPI DestroyInteractionContext(HINTERACTIONCONTEXT handle) return S_OK; } +HRESULT WINAPI ProcessInertiaInteractionContext(HINTERACTIONCONTEXT context) +{ + FIXME("context %p: stub!\n", context); + return E_NOTIMPL; +} + BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, void *reserved) { TRACE("(%p, %d, %p)\n", inst, reason, reserved); diff --git a/dlls/ninput/ninput.spec b/dlls/ninput/ninput.spec index 0717cb1..fe7c6b3 100644 --- a/dlls/ninput/ninput.spec +++ b/dlls/ninput/ninput.spec @@ -10,7 +10,7 @@ @ stub GetPropertyInteractionContext @ stub GetStateInteractionContext @ stub ProcessBufferedPacketsInteractionContext -@ stub ProcessInertiaInteractionContext +@ stdcall ProcessInertiaInteractionContext(ptr) @ stub ProcessPointerFramesInteractionContext @ stub RegisterOutputCallbackInteractionContext @ stub RemovePointerInteractionContext
1
0
0
0
Józef Kucia : ninput: Implement CreateInteractionContext().
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 99d68bc0de781f965f95e36ee73a3f35ae79c120 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=99d68bc0de781f965f95e36e…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Thu Jun 21 16:19:42 2018 +0200 ninput: Implement CreateInteractionContext(). Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- configure | 1 + configure.ac | 1 + dlls/ninput/Makefile.in | 1 + dlls/ninput/main.c | 53 ++++++++++++++++++++++++++++++++++++++++--- dlls/ninput/ninput.spec | 4 ++-- dlls/ninput/tests/Makefile.in | 4 ++++ dlls/ninput/tests/ninput.c | 41 +++++++++++++++++++++++++++++++++ 7 files changed, 100 insertions(+), 5 deletions(-) diff --git a/configure b/configure index ddd6db1..5f27f18 100755 --- a/configure +++ b/configure @@ -19023,6 +19023,7 @@ wine_fn_config_makefile dlls/netprofm enable_netprofm wine_fn_config_makefile dlls/netprofm/tests enable_tests wine_fn_config_makefile dlls/newdev enable_newdev wine_fn_config_makefile dlls/ninput enable_ninput +wine_fn_config_makefile dlls/ninput/tests enable_tests wine_fn_config_makefile dlls/normaliz enable_normaliz wine_fn_config_makefile dlls/npmshtml enable_npmshtml wine_fn_config_makefile dlls/npptools enable_npptools diff --git a/configure.ac b/configure.ac index 68f7f14..9c38cfb 100644 --- a/configure.ac +++ b/configure.ac @@ -3522,6 +3522,7 @@ WINE_CONFIG_MAKEFILE(dlls/netprofm) WINE_CONFIG_MAKEFILE(dlls/netprofm/tests) WINE_CONFIG_MAKEFILE(dlls/newdev) WINE_CONFIG_MAKEFILE(dlls/ninput) +WINE_CONFIG_MAKEFILE(dlls/ninput/tests) WINE_CONFIG_MAKEFILE(dlls/normaliz) WINE_CONFIG_MAKEFILE(dlls/npmshtml) WINE_CONFIG_MAKEFILE(dlls/npptools) diff --git a/dlls/ninput/Makefile.in b/dlls/ninput/Makefile.in index 3d3cc7f..8f1039b 100644 --- a/dlls/ninput/Makefile.in +++ b/dlls/ninput/Makefile.in @@ -1,4 +1,5 @@ MODULE = ninput.dll +IMPORTLIB = ninput C_SRCS = \ main.c diff --git a/dlls/ninput/main.c b/dlls/ninput/main.c index 0f23128..1aa3c46 100644 --- a/dlls/ninput/main.c +++ b/dlls/ninput/main.c @@ -22,19 +22,66 @@ #include "windef.h" #include "winbase.h" #include "wine/debug.h" +#include "wine/heap.h" + +#include "interactioncontext.h" WINE_DEFAULT_DEBUG_CHANNEL(ninput); -BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD reason, LPVOID lpv) +struct interaction_context +{ + BOOL filter_pointers; +}; + +static struct interaction_context *context_from_handle(HINTERACTIONCONTEXT handle) +{ + return (struct interaction_context *)handle; +} + +HRESULT WINAPI CreateInteractionContext(HINTERACTIONCONTEXT *handle) +{ + struct interaction_context *context; + + TRACE("handle %p.\n", handle); + + if (!handle) + return E_POINTER; + + if (!(context = heap_alloc(sizeof(*context)))) + return E_OUTOFMEMORY; + + context->filter_pointers = TRUE; + + TRACE("Created context %p.\n", context); + + *handle = (HINTERACTIONCONTEXT)context; + + return S_OK; +} + +HRESULT WINAPI DestroyInteractionContext(HINTERACTIONCONTEXT handle) +{ + struct interaction_context *context = context_from_handle(handle); + + TRACE("context %p.\n", context); + + if (!context) + return E_HANDLE; + + heap_free(context); + return S_OK; +} + +BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, void *reserved) { - TRACE("(%p, %d, %p)\n", hInstDLL, reason, lpv); + TRACE("(%p, %d, %p)\n", inst, reason, reserved); switch (reason) { case DLL_WINE_PREATTACH: return FALSE; /* prefer native version */ case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls(hInstDLL); + DisableThreadLibraryCalls(inst); break; } return TRUE; diff --git a/dlls/ninput/ninput.spec b/dlls/ninput/ninput.spec index 372beb2..0717cb1 100644 --- a/dlls/ninput/ninput.spec +++ b/dlls/ninput/ninput.spec @@ -1,8 +1,8 @@ @ stub DefaultInputHandler @ stub AddPointerInteractionContext @ stub BufferPointerPacketsInteractionContext -@ stub CreateInteractionContext -@ stub DestroyInteractionContext +@ stdcall CreateInteractionContext(ptr) +@ stdcall DestroyInteractionContext(ptr) @ stub GetCrossSlideParameterInteractionContext @ stub GetInertiaParameterInteractionContext @ stub GetInteractionConfigurationInteractionContext diff --git a/dlls/ninput/tests/Makefile.in b/dlls/ninput/tests/Makefile.in new file mode 100644 index 0000000..9c0b44f --- /dev/null +++ b/dlls/ninput/tests/Makefile.in @@ -0,0 +1,4 @@ +TESTDLL = ninput.dll +IMPORTS = ninput + +C_SRCS = ninput.c diff --git a/dlls/ninput/tests/ninput.c b/dlls/ninput/tests/ninput.c new file mode 100644 index 0000000..d894ab8 --- /dev/null +++ b/dlls/ninput/tests/ninput.c @@ -0,0 +1,41 @@ +/* + * Copyright 2018 Józef Kucia + * + * 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 + */ + +#include "interactioncontext.h" +#include "wine/test.h" + +static void test_context(void) +{ + HINTERACTIONCONTEXT context; + HRESULT hr; + + hr = CreateInteractionContext(&context); + ok(hr == S_OK, "Failed to create context, hr %#x.\n", hr); + hr = DestroyInteractionContext(context); + ok(hr == S_OK, "Failed to destroy context, hr %#x.\n", hr); + + hr = CreateInteractionContext(NULL); + ok(hr == E_POINTER, "Got hr %#x.\n", hr); + hr = DestroyInteractionContext(NULL); + ok(hr == E_HANDLE, "Got hr %#x.\n", hr); +} + +START_TEST(ninput) +{ + test_context(); +}
1
0
0
0
Józef Kucia : include: Add interactioncontext.h.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 6acc2309d5469cc0ed4e4586e52ae76756f788cd URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6acc2309d5469cc0ed4e4586…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Thu Jun 21 16:19:41 2018 +0200 include: Add interactioncontext.h. Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/Makefile.in | 1 + include/interactioncontext.h | 195 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 196 insertions(+) diff --git a/include/Makefile.in b/include/Makefile.in index 78ab095..72a7010 100644 --- a/include/Makefile.in +++ b/include/Makefile.in @@ -314,6 +314,7 @@ SOURCES = \ inputscope.idl \ inseng.idl \ inspectable.idl \ + interactioncontext.h \ intshcut.h \ ipexport.h \ iphlpapi.h \ diff --git a/include/interactioncontext.h b/include/interactioncontext.h new file mode 100644 index 0000000..a643b62 --- /dev/null +++ b/include/interactioncontext.h @@ -0,0 +1,195 @@ +/* + * Copyright 2018 Józef Kucia + * + * 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 + */ + +#ifndef INTERACTION_CONTEXT_H +#define INTERACTION_CONTEXT_H + +#include <windows.h> + +#ifdef __cplusplus +extern "C" { +#endif /* defined(__cplusplus) */ + +DECLARE_HANDLE(HINTERACTIONCONTEXT); + +typedef enum INTERACTION_CONTEXT_PROPERTY +{ + INTERACTION_CONTEXT_PROPERTY_MEASUREMENT_UNITS = 1, + INTERACTION_CONTEXT_PROPERTY_INTERACTION_UI_FEEDBACK = 2, + INTERACTION_CONTEXT_PROPERTY_FILTER_POINTERS = 3, + INTERACTION_CONTEXT_PROPERTY_MAX = 0xffffffff, +} INTERACTION_CONTEXT_PROPERTY; + +typedef enum INTERACTION_ID +{ + INTERACTION_ID_NONE = 0, + INTERACTION_ID_MANIPULATION = 1, + INTERACTION_ID_TAP = 2, + INTERACTION_ID_SECONDARY_TAP = 3, + INTERACTION_ID_HOLD = 4, + INTERACTION_ID_DRAG = 5, + INTERACTION_ID_CROSS_SLIDE = 6, + INTERACTION_ID_MAX = 0xffffffff, +} INTERACTION_ID; + +typedef enum INTERACTION_FLAGS +{ + INTERACTION_FLAG_NONE = 0x00000000, + INTERACTION_FLAG_BEGIN = 0x00000001, + INTERACTION_FLAG_END = 0x00000002, + INTERACTION_FLAG_CANCEL = 0x00000004, + INTERACTION_FLAG_INERTIA = 0x00000008, + INTERACTION_FLAG_MAX = 0xffffffff, +} INTERACTION_FLAGS; + +typedef enum INTERACTION_CONFIGURATION_FLAGS +{ + INTERACTION_CONFIGURATION_FLAG_NONE = 0x00000000, + + INTERACTION_CONFIGURATION_FLAG_MANIPULATION = 0x00000001, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_TRANSLATION_X = 0x00000002, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_TRANSLATION_Y = 0x00000004, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_ROTATION = 0x00000008, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_SCALING = 0x00000010, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_TRANSLATION_INERTIA = 0x00000020, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_ROTATION_INERTIA = 0x00000040, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_SCALING_INERTIA = 0x00000080, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_RAILS_X = 0x00000100, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_RAILS_Y = 0x00000200, + INTERACTION_CONFIGURATION_FLAG_MANIPULATION_EXACT = 0x00000400, + + INTERACTION_CONFIGURATION_FLAG_TAP = 0x00000001, + INTERACTION_CONFIGURATION_FLAG_TAP_DOUBLE = 0x00000002, + + INTERACTION_CONFIGURATION_FLAG_SECONDARY_TAP = 0x00000001, + + INTERACTION_CONFIGURATION_FLAG_HOLD = 0x00000001, + INTERACTION_CONFIGURATION_FLAG_HOLD_MOUSE = 0x00000002, + + INTERACTION_CONFIGURATION_FLAG_DRAG = 0x00000001, + + INTERACTION_CONFIGURATION_FLAG_CROSS_SLIDE = 0x00000001, + INTERACTION_CONFIGURATION_FLAG_CROSS_SLIDE_HORIZONTAL = 0x00000002, + INTERACTION_CONFIGURATION_FLAG_CROSS_SLIDE_SELECT = 0x00000004, + INTERACTION_CONFIGURATION_FLAG_CROSS_SLIDE_SPEED_BUMP = 0x00000008, + INTERACTION_CONFIGURATION_FLAG_CROSS_SLIDE_REARRANGE = 0x00000010, + INTERACTION_CONFIGURATION_FLAG_CROSS_SLIDE_EXACT = 0x00000020, + + INTERACTION_CONFIGURATION_FLAG_MAX = 0xffffffff, +} INTERACTION_CONFIGURATION_FLAGS; + +typedef struct INTERACTION_CONTEXT_CONFIGURATION +{ + INTERACTION_ID interactionId; + INTERACTION_CONFIGURATION_FLAGS enable; + +} INTERACTION_CONTEXT_CONFIGURATION; + +typedef struct MANIPULATION_TRANSFORM +{ + float translationX; + float translationY; + float scale; + float expansion; + float rotation; +} MANIPULATION_TRANSFORM; + +typedef struct MANIPULATION_VELOCITY +{ + float velocityX; + float velocityY; + float velocityExapnsion; + float velocityAngular; +} MANIPULATION_VELOCITY; + +typedef enum MANIPULATION_RAILS_STATE +{ + MANIPULATION_RAILS_STATE_UNDECIDED = 0, + MANIPULATION_RAILS_STATE_FREE = 1, + MANIPULATION_RAILS_STATE_RAILED = 2, + MANIPULATION_RAILS_STATE_MAX = 0xffffffff, +} MANIPULATION_RAILS_STATE; + +typedef struct INTERACTION_ARGUMENTS_MANIPULATION +{ + MANIPULATION_TRANSFORM delta; + MANIPULATION_TRANSFORM cumulative; + MANIPULATION_VELOCITY veolcity; + MANIPULATION_RAILS_STATE railsState; +} INTERACTION_ARGUMENTS_MANIPULATION; + +typedef struct INTERACTION_ARGUMENTS_TAP +{ + UINT32 count; +} INTERACTION_ARGUMENTS_TAP; + +typedef enum CROSS_SLIDE_FLAGS +{ + CROSS_SLIDE_FLAGS_NONE = 0x00000000, + CROSS_SLIDE_FLAGS_SELECT = 0x00000001, + CROSS_SLIDE_FLAGS_SPEED_BUMP = 0x00000002, + CROSS_SLIDE_FLAGS_REARRANGE = 0x00000004, + CROSS_SLIDE_FLAGS_MAX = 0xffffffff, +} CROSS_SLIDE_FLAGS; + +typedef struct INTERACTION_ARGUMENTS_CROSS_SLIDE +{ + CROSS_SLIDE_FLAGS flags; +} INTERACTION_ARGUMENTS_CROSS_SLIDE; + +typedef struct INTERACTION_CONTEXT_OUTPUT +{ + INTERACTION_ID interactionId; + INTERACTION_FLAGS interactionFlags; + POINTER_INPUT_TYPE inputType; + float x; + float y; + union + { + INTERACTION_ARGUMENTS_MANIPULATION manipulation; + INTERACTION_ARGUMENTS_TAP tap; + INTERACTION_ARGUMENTS_CROSS_SLIDE crossSlide; + } arguments; +} INTERACTION_CONTEXT_OUTPUT; + +typedef void (CALLBACK *INTERACTION_CONTEXT_OUTPUT_CALLBACK)(void *data, + const INTERACTION_CONTEXT_OUTPUT *output); + +HRESULT WINAPI CreateInteractionContext(HINTERACTIONCONTEXT *context); +HRESULT WINAPI DestroyInteractionContext(HINTERACTIONCONTEXT context); + +HRESULT WINAPI ProcessInertiaInteractionContext(HINTERACTIONCONTEXT context); + +HRESULT WINAPI RegisterOutputCallbackInteractionContext(HINTERACTIONCONTEXT context, + INTERACTION_CONTEXT_OUTPUT_CALLBACK callback, void *data); + +HRESULT WINAPI GetInteractionConfigurationInteractionContext(HINTERACTIONCONTEXT context, + UINT32 count, INTERACTION_CONTEXT_CONFIGURATION *configuration); +HRESULT WINAPI SetInteractionConfigurationInteractionContext(HINTERACTIONCONTEXT context, + UINT32 count, const INTERACTION_CONTEXT_CONFIGURATION *configuration); + +HRESULT WINAPI GetPropertyInteractionContext(HINTERACTIONCONTEXT context, + INTERACTION_CONTEXT_PROPERTY proerty, UINT32 *value); +HRESULT WINAPI SetPropertyInteractionContext(HINTERACTIONCONTEXT context, + INTERACTION_CONTEXT_PROPERTY property, UINT32 value); + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* defined(__cplusplus) */ + +#endif
1
0
0
0
Józef Kucia : include: Add POINTER_INPUT_TYPE.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 40e6ba4e6960d95c5932d3a63cf059b60aaada32 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=40e6ba4e6960d95c5932d3a6…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Thu Jun 21 16:19:40 2018 +0200 include: Add POINTER_INPUT_TYPE. Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/winuser.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/winuser.h b/include/winuser.h index f546a4a..24ca055 100644 --- a/include/winuser.h +++ b/include/winuser.h @@ -3377,6 +3377,16 @@ typedef struct tagPOINTER_DEVICE_INFO { WCHAR productString[POINTER_DEVICE_PRODUCT_STRING_MAX]; } POINTER_DEVICE_INFO; +enum tagPOINTER_INPUT_TYPE +{ + PT_POINTER = 1, + PT_TOUCH, + PT_PEN, + PT_MOUSE, + PT_TOUCHPAD, +}; +typedef DWORD POINTER_INPUT_TYPE; + #if defined(_WINGDI_) && !defined(NOGDI) WINUSERAPI LONG WINAPI ChangeDisplaySettingsA(LPDEVMODEA,DWORD); WINUSERAPI LONG WINAPI ChangeDisplaySettingsW(LPDEVMODEW,DWORD);
1
0
0
0
Piotr Caban : appwiz.cpl: Support installing minor updates when installing addons.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: e6de503b1f76c328d326700a4334a3b88fd5da6e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=e6de503b1f76c328d326700a…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Thu Jun 21 22:58:29 2018 +0200 appwiz.cpl: Support installing minor updates when installing addons. Signed-off-by: Piotr Caban <piotr(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/appwiz.cpl/addons.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dlls/appwiz.cpl/addons.c b/dlls/appwiz.cpl/addons.c index 67bf037..aede3d0 100644 --- a/dlls/appwiz.cpl/addons.c +++ b/dlls/appwiz.cpl/addons.c @@ -183,9 +183,14 @@ enum install_res { static enum install_res install_file(const WCHAR *file_name) { + static const WCHAR update_cmd[] = { + 'R','E','I','N','S','T','A','L','L','=','A','L','L',' ', + 'R','E','I','N','S','T','A','L','L','M','O','D','E','=','v','o','m','u','s',0}; ULONG res; res = MsiInstallProductW(file_name, NULL); + if(res == ERROR_PRODUCT_VERSION) + res = MsiInstallProductW(file_name, update_cmd); if(res != ERROR_SUCCESS) { ERR("MsiInstallProduct failed: %u\n", res); return INSTALL_FAILED;
1
0
0
0
Roderick Colenbrander : ntdll: GetLogicalProcessorInformation report LPT_PC_SMT for SMT cores.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 837cb92e0ca0f03a0b4d538c0a6563e47c8665ac URL:
https://source.winehq.org/git/wine.git/?a=commit;h=837cb92e0ca0f03a0b4d538c…
Author: Roderick Colenbrander <thunderbird2k(a)gmail.com> Date: Wed Jun 20 22:29:46 2018 -0700 ntdll: GetLogicalProcessorInformation report LPT_PC_SMT for SMT cores. Signed-off-by: Roderick Colenbrander <thunderbird2k(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/nt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index 5712e4c..2ca9cd5 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -1352,7 +1352,8 @@ static inline BOOL logical_proc_info_add_by_id(SYSTEM_LOGICAL_PROCESSOR_INFORMAT (*pdata)[i].Relationship = rel; (*pdata)[i].ProcessorMask = mask; - /* TODO: set processor core flags */ + if (rel == RelationProcessorCore) + (*pdata)[i].u.ProcessorCore.Flags = count_bits(mask) > 1 ? LTP_PC_SMT : 0; (*pdata)[i].u.Reserved[0] = 0; (*pdata)[i].u.Reserved[1] = id; *len = i+1;
1
0
0
0
Roderick Colenbrander : ntdll: GetLogicalProcessorInformationEx report LTP_PC_SMT for SMT cores.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 13bd1b9f752560083ef16bd9ddd56823bc88309c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=13bd1b9f752560083ef16bd9…
Author: Roderick Colenbrander <thunderbird2k(a)gmail.com> Date: Wed Jun 20 22:29:45 2018 -0700 ntdll: GetLogicalProcessorInformationEx report LTP_PC_SMT for SMT cores. Signed-off-by: Roderick Colenbrander <thunderbird2k(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/nt.c | 5 ++++- include/winnt.h | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index 82f1b02..5712e4c 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -1388,7 +1388,10 @@ static inline BOOL logical_proc_info_add_by_id(SYSTEM_LOGICAL_PROCESSOR_INFORMAT dataex->Relationship = rel; dataex->Size = log_proc_ex_size_plus(sizeof(PROCESSOR_RELATIONSHIP)); - dataex->u.Processor.Flags = 0; /* TODO */ + if (rel == RelationProcessorCore) + dataex->u.Processor.Flags = count_bits(mask) > 1 ? LTP_PC_SMT : 0; + else + dataex->u.Processor.Flags = 0; dataex->u.Processor.EfficiencyClass = 0; dataex->u.Processor.GroupCount = 1; dataex->u.Processor.GroupMask[0].Mask = mask; diff --git a/include/winnt.h b/include/winnt.h index 4492f86..80a2fc3 100644 --- a/include/winnt.h +++ b/include/winnt.h @@ -6050,6 +6050,8 @@ typedef enum _LOGICAL_PROCESSOR_RELATIONSHIP RelationAll = 0xffff } LOGICAL_PROCESSOR_RELATIONSHIP; +#define LTP_PC_SMT 0x1 + typedef enum _PROCESSOR_CACHE_TYPE { CacheUnified,
1
0
0
0
Roderick Colenbrander : ntdll: Report physical cores once with proper thread mask.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 1312c6642851d4a0c5de9a71c824800935f96691 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=1312c6642851d4a0c5de9a71…
Author: Roderick Colenbrander <thunderbird2k(a)gmail.com> Date: Wed Jun 20 22:29:44 2018 -0700 ntdll: Report physical cores once with proper thread mask. Signed-off-by: Roderick Colenbrander <thunderbird2k(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/nt.c | 48 +++++++++++++++++++++++++++++++++++++----------- 1 file changed, 37 insertions(+), 11 deletions(-) diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index e4fec63..82f1b02 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -1333,17 +1333,16 @@ static inline BOOL logical_proc_info_add_by_id(SYSTEM_LOGICAL_PROCESSOR_INFORMAT if (pdata) { DWORD i; - if(rel == RelationProcessorPackage){ - for(i=0; i<*len; i++) + for (i=0; i<*len; i++) + { + if (rel == RelationProcessorPackage && (*pdata)[i].Relationship == rel && (*pdata)[i].u.Reserved[1] == id) { - if ((*pdata)[i].Relationship!=rel || (*pdata)[i].u.Reserved[1]!=id) - continue; - (*pdata)[i].ProcessorMask |= mask; return TRUE; } - }else - i = *len; + else if (rel == RelationProcessorCore && (*pdata)[i].Relationship == rel && (*pdata)[i].u.Reserved[1] == id) + return TRUE; + } while(*len == *pmax_len) { @@ -1369,6 +1368,10 @@ static inline BOOL logical_proc_info_add_by_id(SYSTEM_LOGICAL_PROCESSOR_INFORMAT dataex->u.Processor.GroupMask[0].Mask |= mask; return TRUE; } + else if (rel == RelationProcessorCore && dataex->Relationship == rel && dataex->u.Processor.Reserved[1] == id) + { + return TRUE; + } ofs += dataex->Size; } @@ -1554,6 +1557,9 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION ** for(i=beg; i<=end; i++) { + DWORD phys_core = 0; + ULONG_PTR thread_mask = 0; + if(i > 8*sizeof(ULONG_PTR)) { FIXME("skipping logical processor %d\n", i); @@ -1574,15 +1580,35 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION ** return STATUS_NO_MEMORY; } - sprintf(name, core_info, i, "core_id"); + /* Sysfs enumerates logical cores (and not physical cores), but Windows enumerates + * by physical core. Upon enumerating a logical core in sysfs, we register a physical + * core and all its logical cores. In order to not report physical cores multiple + * times, we pass a unique physical core ID to logical_proc_info_add_by_id and let + * that call figure out any duplication. + * Obtain a unique physical core ID from the first element of thread_siblings_list. + * This list provides logical cores sharing the same physical core. The IDs are based + * on kernel cpu core numbering as opposed to a hardware core ID like provided through + * 'core_id', so are suitable as a unique ID. + */ + sprintf(name, core_info, i, "thread_siblings_list"); f = fopen(name, "r"); if(f) { - fscanf(f, "%u", &r); + fscanf(f, "%d%c", &phys_core, &op); + fclose(f); + } + else phys_core = i; + + /* Mask of logical threads sharing same physical core in kernel core numbering. */ + sprintf(name, core_info, i, "thread_siblings"); + f = fopen(name, "r"); + if(f) + { + fscanf(f, "%lx", &thread_mask); fclose(f); } - else r = i; - if(!logical_proc_info_add_by_id(data, dataex, &len, max_len, RelationProcessorCore, r, (ULONG_PTR)1 << i)) + else thread_mask = 1<<i; + if(!logical_proc_info_add_by_id(data, dataex, &len, max_len, RelationProcessorCore, phys_core, thread_mask)) { fclose(fcpu_list); return STATUS_NO_MEMORY;
1
0
0
0
Roderick Colenbrander : ntdll: Store core information by core on macOS.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: c6a71b91c5095e01eba08a6d02def259a0a46478 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c6a71b91c5095e01eba08a6d…
Author: Roderick Colenbrander <thunderbird2k(a)gmail.com> Date: Wed Jun 20 22:29:43 2018 -0700 ntdll: Store core information by core on macOS. The id parameter can be used for core / package lookup. On Linux we pass package or core values. On Mac, we use package for both. Use a core identifier on Mac as well. Signed-off-by: Roderick Colenbrander <thunderbird2k(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/nt.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index 985f58c..e4fec63 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -1811,6 +1811,7 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION ** for(p = 0; p < pkgs_no; ++p){ for(j = 0; j < cores_per_package && p * cores_per_package + j < cores_no; ++j){ ULONG_PTR mask = 0; + DWORD phys_core; for(k = 0; k < lcpu_per_core; ++k) mask |= (ULONG_PTR)1 << (j * lcpu_per_core + k); @@ -1822,7 +1823,8 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION ** return STATUS_NO_MEMORY; /* add new core */ - if(!logical_proc_info_add_by_id(data, dataex, &len, max_len, RelationProcessorCore, p, mask)) + phys_core = p * cores_per_package + j; + if(!logical_proc_info_add_by_id(data, dataex, &len, max_len, RelationProcessorCore, phys_core, mask)) return STATUS_NO_MEMORY; for(i = 1; i < 5; ++i){
1
0
0
0
Roderick Colenbrander : ntdll: Derive number of logical CPU cores from core mask.
by Alexandre Julliard
22 Jun '18
22 Jun '18
Module: wine Branch: master Commit: 0fd6556ed25282d3d95f1ab2d48de99cfff5bad4 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=0fd6556ed25282d3d95f1ab2…
Author: Roderick Colenbrander <thunderbird2k(a)gmail.com> Date: Wed Jun 20 22:29:42 2018 -0700 ntdll: Derive number of logical CPU cores from core mask. Signed-off-by: Roderick Colenbrander <thunderbird2k(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/nt.c | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index dc0ce04..985f58c 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -1309,6 +1309,23 @@ static DWORD log_proc_ex_size_plus(DWORD size) return sizeof(LOGICAL_PROCESSOR_RELATIONSHIP) + sizeof(DWORD) + size; } +static DWORD count_bits(ULONG_PTR mask) +{ + DWORD count = 0; + while (mask > 0) + { + mask >>= 1; + count++; + } + return count; +} + +/* Store package and core information for a logical processor. Parsing of processor + * data may happen in multiple passes; the 'id' parameter is then used to locate + * previously stored data. The type of data stored in 'id' depends on 'rel': + * - RelationProcessorPackage: package id ('CPU socket'). + * - RelationProcessorCore: physical core number. + */ static inline BOOL logical_proc_info_add_by_id(SYSTEM_LOGICAL_PROCESSOR_INFORMATION **pdata, SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX **pdataex, DWORD *len, DWORD *pmax_len, LOGICAL_PROCESSOR_RELATIONSHIP rel, DWORD id, ULONG_PTR mask) @@ -1643,7 +1660,6 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION ** for(i=0; i<len; i++){ if((*data)[i].Relationship == RelationProcessorCore){ all_cpus_mask |= (*data)[i].ProcessorMask; - ++num_cpus; } } }else{ @@ -1651,11 +1667,11 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION ** SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX *infoex = (SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX *)(((char *)*dataex) + i); if(infoex->Relationship == RelationProcessorCore){ all_cpus_mask |= infoex->u.Processor.GroupMask[0].Mask; - ++num_cpus; } i += infoex->Size; } } + num_cpus = count_bits(all_cpus_mask); fnuma_list = fopen("/sys/devices/system/node/online", "r"); if(!fnuma_list)
1
0
0
0
← Newer
1
...
20
21
22
23
24
25
26
...
63
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
Results per page:
10
25
50
100
200