ReactOS.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
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
List overview
Download
Ros-diffs
May 2021
----- 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
ros-diffs@reactos.org
21 participants
183 discussions
Start a n
N
ew thread
[reactos] 02/02: [GITHUB] build.yml: Define CLANG_VERSION for clang only
by Serge Gautherie
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=5ce9e2ec8ec32071c1856…
commit 5ce9e2ec8ec32071c18565d715ff86f788f604b9 Author: Serge Gautherie <reactos-git_serge_171003(a)gautherie.fr> AuthorDate: Mon May 24 08:56:17 2021 +0200 Commit: Jérôme Gardou <zefklop(a)users.noreply.github.com> CommitDate: Mon May 31 16:04:49 2021 +0200 [GITHUB] build.yml: Define CLANG_VERSION for clang only Addendum to a66214c. --- .github/workflows/build.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a037c8e7140..27f7f3835f9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -37,6 +37,7 @@ jobs: wget
https://apt.llvm.org/llvm.sh
chmod +x llvm.sh sudo ./llvm.sh $LLVM_VERSION + echo "D_CLANG_VERSION=-DCLANG_VERSION=$LLVM_VERSION" >> $GITHUB_ENV - name: Source checkout uses: actions/checkout@v2 with: @@ -58,7 +59,7 @@ jobs: if: ${{ matrix.compiler == 'gcc' }} run: echo "CCACHE_COMPILERCHECK=string:${{steps.get_rosbe_spec.outputs.git-sha}}-${{hashfiles('./build_rosbe_ci.sh')}}" >> $GITHUB_ENV - name: Configure - run: echo 'cmake -S ${{github.workspace}}/src -B ${{github.workspace}}/build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-${{matrix.compiler}}.cmake -DARCH:STRING=${{matrix.arch}} -DENABLE_CCACHE=1 -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1 -DCLANG_VERSION=${{env.LLVM_VERSION}}' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}} + run: echo 'cmake -S ${{github.workspace}}/src -B ${{github.workspace}}/build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-${{matrix.compiler}}.cmake -DARCH:STRING=${{matrix.arch}} -DENABLE_CCACHE=1 -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1 ${{env.D_CLANG_VERSION}}' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}} - name: Build run: echo 'cmake --build ${{github.workspace}}/build -- -k0' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}} - name: Generate ISOs
3 years, 6 months
1
0
0
0
[reactos] 01/02: [GITHUB] build.yml: Properly define LLVM_VERSION
by Serge Gautherie
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=4d00a5653a5e2b56b7f9f…
commit 4d00a5653a5e2b56b7f9fa2615d5375d0579d94f Author: Serge Gautherie <reactos-git_serge_171003(a)gautherie.fr> AuthorDate: Mon May 24 08:56:17 2021 +0200 Commit: Jérôme Gardou <zefklop(a)users.noreply.github.com> CommitDate: Mon May 31 16:04:49 2021 +0200 [GITHUB] build.yml: Properly define LLVM_VERSION Addendum to a66214c. --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7b40db8ca25..a037c8e7140 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -33,7 +33,7 @@ jobs: - name: Install LLVM if: ${{ matrix.compiler == 'clang' }} run: | - echo "LLVM_VERSION=12" >> $GITHUB_ENV + export LLVM_VERSION=12 wget
https://apt.llvm.org/llvm.sh
chmod +x llvm.sh sudo ./llvm.sh $LLVM_VERSION
3 years, 6 months
1
0
0
0
[reactos] 01/01: [WIN32SS][NTUSER] Improve HSHELL_WINDOWCREATED condition (#3697)
by Katayama Hirofumi MZ
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=32b0cf6fc6b8f5fab33c1…
commit 32b0cf6fc6b8f5fab33c10c782f40d36feebbedb Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com> AuthorDate: Mon May 31 13:08:06 2021 +0900 Commit: GitHub <noreply(a)github.com> CommitDate: Mon May 31 13:08:06 2021 +0900 [WIN32SS][NTUSER] Improve HSHELL_WINDOWCREATED condition (#3697) Modify the condition of generating HSHELL_WINDOWCREATED, especially on WS_CHILD window style. CORE-15669 --- win32ss/user/ntuser/winpos.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/win32ss/user/ntuser/winpos.c b/win32ss/user/ntuser/winpos.c index bbe6ac5f904..71cf8a1cf8d 100644 --- a/win32ss/user/ntuser/winpos.c +++ b/win32ss/user/ntuser/winpos.c @@ -1904,7 +1904,16 @@ co_WinPosSetWindowPos( } else if (WinPos.flags & SWP_SHOWWINDOW) { - if ((Window->ExStyle & WS_EX_APPWINDOW) || + if (Window->style & WS_CHILD) + { + if ((Window->style & WS_POPUP) && (Window->ExStyle & WS_EX_APPWINDOW)) + { + co_IntShellHookNotify(HSHELL_WINDOWCREATED, (WPARAM)Window->head.h, 0); + if (!(WinPos.flags & SWP_NOACTIVATE)) + UpdateShellHook(Window); + } + } + else if ((Window->ExStyle & WS_EX_APPWINDOW) || (!(Window->ExStyle & WS_EX_TOOLWINDOW) && !Window->spwndOwner && (!Window->spwndParent || UserIsDesktopWindow(Window->spwndParent)))) {
3 years, 6 months
1
0
0
0
[reactos] 01/01: [NETCFGX] Create unique network connection names
by Eric Kohl
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=7b970c67a8fe271a755f7…
commit 7b970c67a8fe271a755f786d6c8130efb17685a6 Author: Eric Kohl <eric.kohl(a)reactos.org> AuthorDate: Sun May 30 21:12:58 2021 +0200 Commit: Eric Kohl <eric.kohl(a)reactos.org> CommitDate: Sun May 30 21:12:58 2021 +0200 [NETCFGX] Create unique network connection names --- dll/win32/netcfgx/installer.c | 83 ++++++++++++++++++++++++++++++++++++++----- 1 file changed, 74 insertions(+), 9 deletions(-) diff --git a/dll/win32/netcfgx/installer.c b/dll/win32/netcfgx/installer.c index a9eb0a710ba..067ff12320f 100644 --- a/dll/win32/netcfgx/installer.c +++ b/dll/win32/netcfgx/installer.c @@ -4,10 +4,11 @@ * FILE: dll/win32/netcfgx/installer.c * PURPOSE: Network devices installer * - * PROGRAMMERS: Herv� Poussineau (hpoussin(a)reactos.org) + * PROGRAMMERS: Hervé Poussineau (hpoussin(a)reactos.org) */ #include "precomp.h" +#include <strsafe.h> /* Append a REG_SZ to an existing REG_MULTI_SZ string in the registry. @@ -89,6 +90,59 @@ cleanup: return rc; } +static +DWORD +GetUniqueConnectionName( + _In_ HKEY hNetworkKey, + _Out_ PWSTR *ppszNameBuffer) +{ + int Length = 0; + PWSTR pszDefaultName = NULL; + PWSTR pszNameBuffer = NULL; + DWORD dwSubKeys = 0; + DWORD dwError; + + TRACE("GetNewConnectionName()\n"); + + Length = LoadStringW(netcfgx_hInstance, IDS_NET_CONNECT, (LPWSTR)&pszDefaultName, 0); + if (Length == 0) + { + pszDefaultName = L"Network Connection"; + Length = wcslen(pszDefaultName); + } + + TRACE("Length %d\n", Length); + + dwError = RegQueryInfoKeyW(hNetworkKey, + NULL, NULL, NULL, &dwSubKeys, + NULL, NULL, NULL, NULL, NULL, NULL, NULL); + if (dwError != ERROR_SUCCESS) + { + ERR("RegQueryInfoKeyW: Error %lu\n", dwError); + return dwError; + } + + TRACE("Adapter Count: %lu\n", dwSubKeys); + + pszNameBuffer = HeapAlloc(GetProcessHeap(), + HEAP_ZERO_MEMORY, + (Length + ((dwSubKeys != 0) ? 6 : 1)) * sizeof(WCHAR)); + if (pszNameBuffer == NULL) + { + return ERROR_OUTOFMEMORY; + } + + if (dwSubKeys != 0) + StringCchPrintfW(pszNameBuffer, Length + 6, L"%.*s %lu", Length, pszDefaultName, dwSubKeys + 1); + else + StringCchPrintfW(pszNameBuffer, Length + 1, L"%.*s", Length, pszDefaultName); + + TRACE("Adapter Name: %S\n", pszNameBuffer); + + *ppszNameBuffer = pszNameBuffer; + + return ERROR_SUCCESS; +} static DWORD @@ -110,7 +164,7 @@ InstallNetDevice( HKEY hLinkageKey = NULL; HKEY hConnectionKey = NULL; DWORD dwShowIcon, dwLength, dwValue; - WCHAR szBuffer[300]; + PWSTR pszNameBuffer = NULL; PWSTR ptr; DeviceInstallParams.cbSize = sizeof(DeviceInstallParams); @@ -336,13 +390,28 @@ InstallNetDevice( hKey = NULL; /* Write connection information in network subkey */ - rc = RegCreateKeyExW(HKEY_LOCAL_MACHINE, L"SYSTEM\\CurrentControlSet\\Control\\Network\\{4D36E972-E325-11CE-BFC1-08002BE10318}", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_CREATE_SUB_KEY, NULL, &hNetworkKey, NULL); + rc = RegCreateKeyExW(HKEY_LOCAL_MACHINE, + L"SYSTEM\\CurrentControlSet\\Control\\Network\\{4D36E972-E325-11CE-BFC1-08002BE10318}", + 0, + NULL, + REG_OPTION_NON_VOLATILE, + KEY_CREATE_SUB_KEY | KEY_QUERY_VALUE, + NULL, + &hNetworkKey, + NULL); if (rc != ERROR_SUCCESS) { ERR("RegCreateKeyExW() failed with error 0x%lx\n", rc); goto cleanup; } + rc = GetUniqueConnectionName(hNetworkKey, &pszNameBuffer); + if (rc != ERROR_SUCCESS) + { + ERR("GetUniqueConnectionName() failed with error 0x%lx\n", rc); + goto cleanup; + } + rc = RegCreateKeyExW(hNetworkKey, UuidString, 0, NULL, REG_OPTION_NON_VOLATILE, KEY_CREATE_SUB_KEY, NULL, &hKey, NULL); if (rc != ERROR_SUCCESS) { @@ -359,12 +428,7 @@ InstallNetDevice( goto cleanup; } - if (!LoadStringW(netcfgx_hInstance, IDS_NET_CONNECT, szBuffer, sizeof(szBuffer)/sizeof(WCHAR))) - { - wcscpy(szBuffer, L"Network Connection"); - } - - rc = RegSetValueExW(hConnectionKey, L"Name", 0, REG_SZ, (const BYTE*)szBuffer, (wcslen(szBuffer) + 1) * sizeof(WCHAR)); + rc = RegSetValueExW(hConnectionKey, L"Name", 0, REG_SZ, (const BYTE*)pszNameBuffer, (wcslen(pszNameBuffer) + 1) * sizeof(WCHAR)); if (rc != ERROR_SUCCESS) { ERR("RegSetValueExW() failed with error 0x%lx\n", rc); @@ -423,6 +487,7 @@ InstallNetDevice( rc = ERROR_SUCCESS; cleanup: + HeapFree(GetProcessHeap(), 0, pszNameBuffer); HeapFree(GetProcessHeap(), 0, InstanceId); HeapFree(GetProcessHeap(), 0, ComponentId); HeapFree(GetProcessHeap(), 0, DeviceName);
3 years, 6 months
1
0
0
0
[reactos] 01/01: [USER32_APITEST] Add ShowWindow testcase (#3689)
by Katayama Hirofumi MZ
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=a8ed286c86e643ca99022…
commit a8ed286c86e643ca99022ec608be1360132499bb Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com> AuthorDate: Sun May 30 09:37:38 2021 +0900 Commit: GitHub <noreply(a)github.com> CommitDate: Sun May 30 09:37:38 2021 +0900 [USER32_APITEST] Add ShowWindow testcase (#3689) Investigate the implementation of user32!ShowWindow. CORE-15669 --- modules/rostests/apitests/user32/CMakeLists.txt | 1 + modules/rostests/apitests/user32/ShowWindow.c | 183 ++++++++++++++++++++++++ modules/rostests/apitests/user32/testlist.c | 2 + 3 files changed, 186 insertions(+) diff --git a/modules/rostests/apitests/user32/CMakeLists.txt b/modules/rostests/apitests/user32/CMakeLists.txt index 896023291c8..f0dca068549 100644 --- a/modules/rostests/apitests/user32/CMakeLists.txt +++ b/modules/rostests/apitests/user32/CMakeLists.txt @@ -42,6 +42,7 @@ list(APPEND SOURCE SetProp.c SetScrollInfo.c SetScrollRange.c + ShowWindow.c SwitchToThisWindow.c SystemParametersInfo.c TrackMouseEvent.c diff --git a/modules/rostests/apitests/user32/ShowWindow.c b/modules/rostests/apitests/user32/ShowWindow.c new file mode 100644 index 00000000000..832688b938e --- /dev/null +++ b/modules/rostests/apitests/user32/ShowWindow.c @@ -0,0 +1,183 @@ +/* + * PROJECT: ReactOS API tests + * LICENSE: LGPL-2.1+ (
https://spdx.org/licenses/LGPL-2.1+
) + * PURPOSE: Tests for ShowWindow + * COPYRIGHT: Copyright 2021 Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com> + */ + +#include "precomp.h" + +typedef struct TEST_ENTRY +{ + INT lineno; + BOOL ret; + INT nCmdShow; + DWORD style0; + DWORD style1; +} TEST_ENTRY; + +static const CHAR s_name[] = "ShowWindow test window"; + +static void DoTestEntry(const TEST_ENTRY *pEntry) +{ + HWND hwnd; + DWORD style; + BOOL ret; + + hwnd = CreateWindowA(s_name, s_name, pEntry->style0, + CW_USEDEFAULT, CW_USEDEFAULT, 100, 100, + NULL, NULL, GetModuleHandleA(NULL), NULL); + ok(!!hwnd, "Line %d: CreateWindowA failed\n", pEntry->lineno); + + ret = !!ShowWindow(hwnd, pEntry->nCmdShow); + ok(ret == pEntry->ret, "Line %d: ShowWindow returned %s\n", pEntry->lineno, + (ret ? "non-zero" : "zero")); + + style = (LONG)GetWindowLongPtrA(hwnd, GWL_STYLE); + ok(style == pEntry->style1, "Line %d: style was 0x%lX\n", pEntry->lineno, style); + + DestroyWindow(hwnd); +} + +#define STYLE_0 WS_OVERLAPPEDWINDOW +#define STYLE_1 (WS_OVERLAPPEDWINDOW | WS_MAXIMIZE) +#define STYLE_2 (WS_OVERLAPPEDWINDOW | WS_MINIMIZE) +#define STYLE_3 (WS_OVERLAPPEDWINDOW | WS_VISIBLE) +#define STYLE_4 (WS_OVERLAPPEDWINDOW | WS_VISIBLE | WS_MAXIMIZE) +#define STYLE_5 (WS_OVERLAPPEDWINDOW | WS_VISIBLE | WS_MINIMIZE) + +#define SW_0 -1 +#define SW_1 SW_HIDE +#define SW_2 SW_MAXIMIZE +#define SW_3 SW_MINIMIZE +#define SW_4 SW_RESTORE +#define SW_5 SW_SHOW +#define SW_6 SW_SHOWDEFAULT +#define SW_7 SW_SHOWMAXIMIZED +#define SW_8 SW_SHOWMINIMIZED +#define SW_9 SW_SHOWMINNOACTIVE +#define SW_10 SW_SHOWNA +#define SW_11 SW_SHOWNOACTIVATE +#define SW_12 SW_SHOWNORMAL + +static const TEST_ENTRY s_entries[] = +{ + // STYLE_0 + { __LINE__, FALSE, SW_0, STYLE_0, STYLE_0 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_1, STYLE_0, STYLE_0 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_2, STYLE_0, STYLE_0 | WS_VISIBLE | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_3, STYLE_0, STYLE_0 | WS_VISIBLE | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_4, STYLE_0, STYLE_0 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_5, STYLE_0, STYLE_0 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_6, STYLE_0, STYLE_0 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_7, STYLE_0, STYLE_0 | WS_VISIBLE | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_8, STYLE_0, STYLE_0 | WS_VISIBLE | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_9, STYLE_0, STYLE_0 | WS_VISIBLE | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_10, STYLE_0, STYLE_0 | WS_VISIBLE| WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_11, STYLE_0, STYLE_0 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_12, STYLE_0, STYLE_0 | WS_VISIBLE | WS_CLIPSIBLINGS }, + // STYLE_1 + { __LINE__, FALSE, SW_0, STYLE_1, STYLE_1 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_1, STYLE_1, STYLE_1 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_2, STYLE_1, STYLE_1 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_3, STYLE_1, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_4, STYLE_1, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_5, STYLE_1, STYLE_1 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_6, STYLE_1, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_7, STYLE_1, STYLE_1 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_8, STYLE_1, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_9, STYLE_1, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_10, STYLE_1, STYLE_1 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_11, STYLE_1, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_12, STYLE_1, STYLE_3 | WS_CLIPSIBLINGS }, + // STYLE_2 + { __LINE__, FALSE, SW_0, STYLE_2, STYLE_2 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_1, STYLE_2, STYLE_2 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_2, STYLE_2, STYLE_3 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_3, STYLE_2, STYLE_2 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_4, STYLE_2, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_5, STYLE_2, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_6, STYLE_2, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_7, STYLE_2, STYLE_3 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_8, STYLE_2, STYLE_2 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_9, STYLE_2, STYLE_2 | WS_VISIBLE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_10, STYLE_2, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_11, STYLE_2, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, FALSE, SW_12, STYLE_2, STYLE_3 | WS_CLIPSIBLINGS }, + // STYLE_3 + { __LINE__, FALSE, SW_0, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_1, STYLE_3, WS_OVERLAPPEDWINDOW | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_2, STYLE_3, STYLE_3 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_3, STYLE_3, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_4, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_5, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_6, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_7, STYLE_3, STYLE_3 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_8, STYLE_3, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_9, STYLE_3, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_10, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_11, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_12, STYLE_3, STYLE_3 | WS_CLIPSIBLINGS }, + // STYLE_4 + { __LINE__, FALSE, SW_0, STYLE_4, STYLE_4 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_1, STYLE_4, WS_OVERLAPPEDWINDOW | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_2, STYLE_4, STYLE_4 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_3, STYLE_4, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_4, STYLE_4, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_5, STYLE_4, STYLE_4 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_6, STYLE_4, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_7, STYLE_4, STYLE_4 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_8, STYLE_4, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_9, STYLE_4, STYLE_3 | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_10, STYLE_4, STYLE_4 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_11, STYLE_4, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_12, STYLE_4, STYLE_3 | WS_CLIPSIBLINGS }, + // STYLE_5 + { __LINE__, FALSE, SW_0, STYLE_5, STYLE_5 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_1, STYLE_5, WS_OVERLAPPEDWINDOW | WS_MINIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_2, STYLE_5, STYLE_3 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_3, STYLE_5, STYLE_5 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_4, STYLE_5, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_5, STYLE_5, STYLE_5 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_6, STYLE_5, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_7, STYLE_5, STYLE_3 | WS_MAXIMIZE | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_8, STYLE_5, STYLE_5 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_9, STYLE_5, STYLE_5 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_10, STYLE_5, STYLE_5 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_11, STYLE_5, STYLE_3 | WS_CLIPSIBLINGS }, + { __LINE__, TRUE, SW_12, STYLE_5, STYLE_3 | WS_CLIPSIBLINGS }, +}; + +static LRESULT CALLBACK +WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + switch (uMsg) + { + case WM_CREATE: + return 0; + case WM_DESTROY: + PostQuitMessage(0); + break; + default: + return DefWindowProcA(hwnd, uMsg, wParam, lParam); + } + return 0; +} + +START_TEST(ShowWindow) +{ + WNDCLASSA wc; + UINT iTest; + + ZeroMemory(&wc, sizeof(wc)); + wc.lpfnWndProc = WindowProc; + wc.hInstance = GetModuleHandleA(NULL); + wc.hbrBackground = (HBRUSH)(COLOR_3DFACE + 1); + wc.lpszClassName = s_name; + ok_int(1, !!RegisterClassA(&wc)); + + for (iTest = 0; iTest < _countof(s_entries); ++iTest) + { + DoTestEntry(&s_entries[iTest]); + } +} diff --git a/modules/rostests/apitests/user32/testlist.c b/modules/rostests/apitests/user32/testlist.c index d3b1dda9960..b4ef3e04e4c 100644 --- a/modules/rostests/apitests/user32/testlist.c +++ b/modules/rostests/apitests/user32/testlist.c @@ -44,6 +44,7 @@ extern void func_SetParent(void); extern void func_SetProp(void); extern void func_SetScrollInfo(void); extern void func_SetScrollRange(void); +extern void func_ShowWindow(void); extern void func_SwitchToThisWindow(void); extern void func_SystemParametersInfo(void); extern void func_TrackMouseEvent(void); @@ -93,6 +94,7 @@ const struct test winetest_testlist[] = { "SetProp", func_SetProp }, { "SetScrollInfo", func_SetScrollInfo }, { "SetScrollRange", func_SetScrollRange }, + { "ShowWindow", func_ShowWindow }, { "SwitchToThisWindow", func_SwitchToThisWindow }, { "SystemParametersInfo", func_SystemParametersInfo }, { "TrackMouseEvent", func_TrackMouseEvent },
3 years, 6 months
1
0
0
0
[reactos] 03/03: [RTL/x64] Implement RtlRestoreContext
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=0c3812eb7e58b1a7ced66…
commit 0c3812eb7e58b1a7ced66a68999794c9a34eb564 Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Sat Mar 3 00:13:37 2018 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat May 29 21:20:48 2021 +0200 [RTL/x64] Implement RtlRestoreContext --- sdk/include/asm/asm.inc | 4 ++ sdk/lib/rtl/amd64/except_asm.S | 130 +++++++++++++++++++++++++++++++++++++++++ sdk/lib/rtl/amd64/stubs.c | 9 --- 3 files changed, 134 insertions(+), 9 deletions(-) diff --git a/sdk/include/asm/asm.inc b/sdk/include/asm/asm.inc index d879b44ca7f..de46fb5c963 100644 --- a/sdk/include/asm/asm.inc +++ b/sdk/include/asm/asm.inc @@ -313,6 +313,10 @@ ENDM jmp far ptr \segment:\offset .endm +.macro retf + lret +.endm + /* MASM compatible EXTERN */ .macro EXTERN name .endm diff --git a/sdk/lib/rtl/amd64/except_asm.S b/sdk/lib/rtl/amd64/except_asm.S index ea2eb7f88c8..e3fd67b852f 100644 --- a/sdk/lib/rtl/amd64/except_asm.S +++ b/sdk/lib/rtl/amd64/except_asm.S @@ -106,6 +106,136 @@ PUBLIC RtlCaptureContext ret .ENDP +/* + * VOID NTAPI + * RtlRestoreContext( + * _In_ PCONTEXT ContextRecord@<rcx>, + * PEXCEPTION_RECORD *ExceptionRecord@<rdx>); + */ +PUBLIC RtlRestoreContext +.PROC RtlRestoreContext + + /* Allocate space */ + sub rsp, HEX(8) + .ALLOCSTACK 8 + .ENDPROLOG + + // TODO: Handle ExceptionRecord + + /* Restore legacy floating point registers (It's slow, so do it first) */ + ldmxcsr [rcx + CxMxCsr] + fxrstor [rcx + CxFltSave] + + /* Load the target stack pointer into rdx */ + mov rdx, [rcx + CxRsp] + + /* Load EFlags into rax (zero extended) */ + mov eax, [rcx + CxEFlags] + + /* Load the return address into r8 */ + mov r8, [rcx + CxRip] + + /* Load rdx restore value into r9 */ + mov r9, [rcx + CxRdx] + + /* Restore xmm registers */ + movaps xmm0, [rcx + CxXmm0] + movaps xmm1, [rcx + CxXmm1] + movaps xmm2, [rcx + CxXmm2] + movaps xmm3, [rcx + CxXmm3] + movaps xmm4, [rcx + CxXmm4] + movaps xmm5, [rcx + CxXmm5] + movaps xmm6, [rcx + CxXmm6] + movaps xmm7, [rcx + CxXmm7] + movaps xmm8, [rcx + CxXmm8] + movaps xmm9, [rcx + CxXmm9] + movaps xmm10, [rcx + CxXmm10] + movaps xmm11, [rcx + CxXmm11] + movaps xmm12, [rcx + CxXmm12] + movaps xmm13, [rcx + CxXmm13] + movaps xmm14, [rcx + CxXmm14] + movaps xmm15, [rcx + CxXmm15] + + /* Copy Return address (now in r8) to the target stack */ + mov [rdx - 2 * 8], r8 + + /* Copy Eflags (now in rax) to the target stack */ + mov [rdx - 3 * 8], rax + + /* Copy the value for rdx (now in r9) to the target stack */ + mov [rdx - 4 * 8], r9 + + /* Restore the integer registers */ + mov rbx, [rcx + CxRbx] + mov rsi, [rcx + CxRsi] + mov rdi, [rcx + CxRdi] + mov rbp, [rcx + CxRbp] + mov r10, [rcx + CxR10] + mov r11, [rcx + CxR11] + mov r12, [rcx + CxR12] + mov r13, [rcx + CxR13] + mov r14, [rcx + CxR14] + mov r15, [rcx + CxR15] + + /* Restore segment selectors */ + mov ds, [rcx + CxSegDs] // FIXME: WOW64 context? + mov es, [rcx + CxSegEs] + mov fs, [rcx + CxSegFs] + //mov gs, [rcx + CxSegGs] + //mov ss, [rcx + CxSegSs] + + /* Restore the registers we used */ + mov r8, [rcx + CxR8] + mov r9, [rcx + CxR9] + + /* Check if we go to a different cs */ + mov ax, cs + cmp [rcx + CxSegCs], ax + jne ReturnFar + + /* Restore rax and rcx */ + mov rax, [rcx + CxRax] + mov rcx, [rcx + CxRcx] + + /* Switch to the target stack */ + lea rsp, [rdx - 4 * 8] + + /* Pop rdx from the stack */ + pop rdx + + /* Pop Eflags from the stack */ + popfq + + /* Return and fix up the stack */ + ret 8 + +ReturnFar: + + /* Put cs on the stack for the far return */ + mov ax, [rcx + CxSegCs] + mov [rdx - 1 * 8], ax + + /* Load ss */ + mov ss, [rcx + CxSegSs] + + /* Restore rax and rcx */ + mov rax, [rcx + CxRax] + mov rcx, [rcx + CxRcx] + + /* Switch to the target stack */ + lea rsp, [rdx - 4 * 8] + + /* Pop rdx from the stack */ + pop rdx + + /* Pop Eflags from the stack */ + popfq + + /* Return far */ + retf + +.ENDP + END diff --git a/sdk/lib/rtl/amd64/stubs.c b/sdk/lib/rtl/amd64/stubs.c index 52288c44f84..7eb61416c36 100644 --- a/sdk/lib/rtl/amd64/stubs.c +++ b/sdk/lib/rtl/amd64/stubs.c @@ -97,15 +97,6 @@ RtlDispatchException(IN PEXCEPTION_RECORD ExceptionRecord, return FALSE; } -NTSYSAPI -VOID -RtlRestoreContext( - PCONTEXT ContextRecord, - PEXCEPTION_RECORD ExceptionRecord) -{ - UNIMPLEMENTED; -} - NTSTATUS NTAPI RtlQueueApcWow64Thread(
3 years, 6 months
1
0
0
0
[reactos] 02/03: [RTL/x64] Improve RtlCaptureContext
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=abb338b13d1fce57c045f…
commit abb338b13d1fce57c045f38ca759ede1da3fa2dc Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Fri Mar 2 08:02:13 2018 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat May 29 21:20:48 2021 +0200 [RTL/x64] Improve RtlCaptureContext Use movaps instead of movdqa, it does the same thing, but is one byte shorter. Shuffle instructions around a bit to maximize parallel execution. --- sdk/lib/rtl/amd64/except_asm.S | 118 ++++++++++++++++++++++------------------- 1 file changed, 63 insertions(+), 55 deletions(-) diff --git a/sdk/lib/rtl/amd64/except_asm.S b/sdk/lib/rtl/amd64/except_asm.S index b56cc48f51c..ea2eb7f88c8 100644 --- a/sdk/lib/rtl/amd64/except_asm.S +++ b/sdk/lib/rtl/amd64/except_asm.S @@ -16,9 +16,9 @@ .code64 /* - * VOID NTAPI + * VOID * RtlCaptureContext( - * PCONTEXT ContextRecord); <rcx> + * _Out_ PCONTEXT ContextRecord@<rcx>); */ PUBLIC RtlCaptureContext .PROC RtlCaptureContext @@ -28,70 +28,78 @@ PUBLIC RtlCaptureContext .ALLOCSTACK 8 .ENDPROLOG - /* Save the basic register context */ - mov [rcx + CONTEXT_Rax], rax - mov [rcx + CONTEXT_Rcx], rcx - mov [rcx + CONTEXT_Rdx], rdx + /* Save rax first, we use it later to copy some data */ + mov [rcx + CxRax], rax - /* Load rflags into rax */ - mov rax, [rsp] + /* Set ContextFlags */ + mov dword ptr [rcx + CxContextFlags], (CONTEXT_FULL or CONTEXT_SEGMENTS) - mov [rcx + CONTEXT_Rbx], rbx - mov [rcx + CONTEXT_Rsi], rsi - mov [rcx + CONTEXT_Rdi], rdi + /* Store the basic register context */ + mov [rcx + CxRcx], rcx + mov [rcx + CxRdx], rdx + mov [rcx + CxRbx], rbx + mov [rcx + CxRsi], rsi - /* Store rflags */ - mov [rcx + CONTEXT_EFlags], rax + /* Load return address in rax */ + mov rax, [rsp + 8] + + mov [rcx + CxRdi], rdi + mov [rcx + CxRbp], rbp + mov [rcx + CxR8], r8 + mov [rcx + CxR9], r9 + mov [rcx + CxR10], r10 + + /* Store the return address */ + mov [rcx + CxRip], rax - mov [rcx + CONTEXT_Rbp], rbp - mov [rcx + CONTEXT_R8], r8 - mov [rcx + CONTEXT_R9], r9 + mov [rcx + CxR11], r11 + mov [rcx + CxR12], r12 + mov [rcx + CxR13], r13 + mov [rcx + CxR14], r14 + mov [rcx + CxR15], r15 /* Load former stack pointer in rax */ lea rax, [rsp + 16] - mov [rcx + CONTEXT_R10], r10 - mov [rcx + CONTEXT_R11], r11 - mov [rcx + CONTEXT_R12], r12 + /* Store segment selectors */ + mov [rcx + CxSegCs], cs + mov [rcx + CxSegDs], ds + mov [rcx + CxSegEs], es + mov [rcx + CxSegFs], fs + mov [rcx + CxSegGs], gs + mov [rcx + CxSegSs], ss /* Store stack pointer */ - mov [rcx + CONTEXT_Rsp], rax + mov [rcx + CxRsp], rax + + /* Store xmm registers */ + movaps [rcx + CxXmm0], xmm0 + movaps [rcx + CxXmm1], xmm1 + movaps [rcx + CxXmm2], xmm2 + movaps [rcx + CxXmm3], xmm3 + movaps [rcx + CxXmm4], xmm4 + movaps [rcx + CxXmm5], xmm5 + movaps [rcx + CxXmm6], xmm6 + movaps [rcx + CxXmm7], xmm7 + + /* Load rflags into eax */ + mov eax, [rsp] + + movaps [rcx + CxXmm8], xmm8 + movaps [rcx + CxXmm9], xmm9 + movaps [rcx + CxXmm10], xmm10 + movaps [rcx + CxXmm11], xmm11 + movaps [rcx + CxXmm12], xmm12 + movaps [rcx + CxXmm13], xmm13 + movaps [rcx + CxXmm14], xmm14 + movaps [rcx + CxXmm15], xmm15 + + /* Store legacy floating point registers */ + fxsave [rcx + CxFltSave] + stmxcsr [rcx + CxMxCsr] - mov [rcx + CONTEXT_R13], r13 - mov [rcx + CONTEXT_R14], r14 - mov [rcx + CONTEXT_R15], r15 - - /* Load return address in rax */ - mov rax, [rsp + 8] - - /* Safe segment selectors */ - mov [rcx + CONTEXT_SegCs], cs - mov [rcx + CONTEXT_SegDs], ds - mov [rcx + CONTEXT_SegEs], es - mov [rcx + CONTEXT_SegFs], fs - mov [rcx + CONTEXT_SegGs], gs - mov [rcx + CONTEXT_SegSs], ss - - /* Store return address */ - mov [rcx + CONTEXT_Rip], rax - - /* Safe xmm registers */ - movdqa [rcx + CONTEXT_Xmm0], xmm0 - movdqa [rcx + CONTEXT_Xmm1], xmm1 - movdqa [rcx + CONTEXT_Xmm2], xmm2 - movdqa [rcx + CONTEXT_Xmm3], xmm3 - movdqa [rcx + CONTEXT_Xmm4], xmm4 - movdqa [rcx + CONTEXT_Xmm5], xmm5 - movdqa [rcx + CONTEXT_Xmm6], xmm6 - movdqa [rcx + CONTEXT_Xmm7], xmm7 - movdqa [rcx + CONTEXT_Xmm8], xmm8 - movdqa [rcx + CONTEXT_Xmm9], xmm9 - movdqa [rcx + CONTEXT_Xmm10], xmm10 - movdqa [rcx + CONTEXT_Xmm11], xmm11 - movdqa [rcx + CONTEXT_Xmm12], xmm12 - movdqa [rcx + CONTEXT_Xmm13], xmm13 - movdqa [rcx + CONTEXT_Xmm14], xmm14 - movdqa [rcx + CONTEXT_Xmm15], xmm15 + /* Store rflags */ + mov [rcx + CxEFlags], eax /* Cleanup stack and return */ add rsp, 8
3 years, 6 months
1
0
0
0
[reactos] 01/03: [RTL/x64] Improve RtlInitializeContext
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=3831c0ca314b5a69e7fc7…
commit 3831c0ca314b5a69e7fc762800bc56ecb1b6c0fe Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Mon Jan 6 10:46:01 2020 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat May 29 21:20:48 2021 +0200 [RTL/x64] Improve RtlInitializeContext --- sdk/lib/rtl/amd64/stubs.c | 47 ++++++++++++++++++++--------------------------- 1 file changed, 20 insertions(+), 27 deletions(-) diff --git a/sdk/lib/rtl/amd64/stubs.c b/sdk/lib/rtl/amd64/stubs.c index 8a3bc4749d6..52288c44f84 100644 --- a/sdk/lib/rtl/amd64/stubs.c +++ b/sdk/lib/rtl/amd64/stubs.c @@ -20,25 +20,29 @@ */ VOID NTAPI -RtlInitializeContext(IN HANDLE ProcessHandle, - OUT PCONTEXT ThreadContext, - IN PVOID ThreadStartParam OPTIONAL, - IN PTHREAD_START_ROUTINE ThreadStartAddress, - IN PINITIAL_TEB StackBase) +RtlInitializeContext( + _Reserved_ HANDLE ProcessHandle, + _Out_ PCONTEXT ThreadContext, + _In_ PVOID ThreadStartParam OPTIONAL, + _In_ PTHREAD_START_ROUTINE ThreadStartAddress, + _In_ PINITIAL_TEB StackBase) { + /* Initialize everything to 0 */ + RtlZeroMemory(ThreadContext, sizeof(*ThreadContext)); - ThreadContext->Rax = 0; - ThreadContext->Rbx = 0; + /* Initialize StartAddress and Stack */ + ThreadContext->Rip = (ULONG64)ThreadStartAddress; + ThreadContext->Rsp = (ULONG64)StackBase - 6 * sizeof(PVOID); + + /* Align stack by 16 and substract 8 (unaligned on function entry) */ + ThreadContext->Rsp &= ~15; + ThreadContext->Rsp -= 8; + + /* Enable Interrupts */ + ThreadContext->EFlags = EFLAGS_INTERRUPT_MASK; + + /* Set start parameter */ ThreadContext->Rcx = (ULONG64)ThreadStartParam; - ThreadContext->Rdx = 0; - ThreadContext->Rsi = 0; - ThreadContext->Rdi = 0; - ThreadContext->Rbp = 0; - ThreadContext->R8 = 0; - ThreadContext->R9 = 0; - ThreadContext->R10 = 0; - ThreadContext->R11 = 0; - ThreadContext->R12 = 0; /* Set the Selectors */ if ((LONG64)ThreadStartAddress < 0) @@ -62,17 +66,6 @@ RtlInitializeContext(IN HANDLE ProcessHandle, ThreadContext->SegSs = KGDT64_R3_DATA | RPL_MASK; } - /* Enable Interrupts */ - ThreadContext->EFlags = EFLAGS_INTERRUPT_MASK; - - /* Settings passed */ - ThreadContext->Rip = (ULONG64)ThreadStartAddress; - ThreadContext->Rsp = (ULONG64)StackBase - 6 * sizeof(PVOID); - - /* Align stack by 16 and substract 8 (unaligned on function entry) */ - ThreadContext->Rsp &= ~15; - ThreadContext->Rsp -= 8; - /* Only the basic Context is initialized */ ThreadContext->ContextFlags = CONTEXT_CONTROL | CONTEXT_INTEGER |
3 years, 6 months
1
0
0
0
[reactos] 01/01: [NTOS:SE] Do some cleanup on ICIF flags in token information classes
by George Bișoc
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=3140dac3fea0a6622a3fb…
commit 3140dac3fea0a6622a3fb6ee3e7f6eefc5bc764f Author: George Bișoc <george.bisoc(a)reactos.org> AuthorDate: Sat May 22 19:47:19 2021 +0200 Commit: George Bișoc <george.bisoc(a)reactos.org> CommitDate: Sat May 29 12:44:03 2021 +0200 [NTOS:SE] Do some cleanup on ICIF flags in token information classes A few of these classes have fixed size lengths, the rest are arbitrary. Also the TokenAuditPolicy class hasn't a size length type specified in the table, which is wrong (and move the corresponding TOKEN_AUDIT_POLICY_INFORMATION structure into the private header). --- ntoskrnl/include/internal/se.h | 10 ++++++++++ ntoskrnl/se/token.c | 36 +++++++++++++----------------------- 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/ntoskrnl/include/internal/se.h b/ntoskrnl/include/internal/se.h index 698d7067bae..03639470c72 100644 --- a/ntoskrnl/include/internal/se.h +++ b/ntoskrnl/include/internal/se.h @@ -24,6 +24,16 @@ typedef struct _KNOWN_COMPOUND_ACE ULONG SidStart; } KNOWN_COMPOUND_ACE, *PKNOWN_COMPOUND_ACE; +typedef struct _TOKEN_AUDIT_POLICY_INFORMATION +{ + ULONG PolicyCount; + struct + { + ULONG Category; + UCHAR Value; + } Policies[1]; +} TOKEN_AUDIT_POLICY_INFORMATION, *PTOKEN_AUDIT_POLICY_INFORMATION; + FORCEINLINE PSID SepGetGroupFromDescriptor(PVOID _Descriptor) diff --git a/ntoskrnl/se/token.c b/ntoskrnl/se/token.c index 5e3e82d9ecd..eb67cda7486 100644 --- a/ntoskrnl/se/token.c +++ b/ntoskrnl/se/token.c @@ -14,16 +14,6 @@ #include <ntlsa.h> -typedef struct _TOKEN_AUDIT_POLICY_INFORMATION -{ - ULONG PolicyCount; - struct - { - ULONG Category; - UCHAR Value; - } Policies[1]; -} TOKEN_AUDIT_POLICY_INFORMATION, *PTOKEN_AUDIT_POLICY_INFORMATION; - /* GLOBALS ********************************************************************/ POBJECT_TYPE SeTokenObjectType = NULL; @@ -45,25 +35,25 @@ static const INFORMATION_CLASS_INFO SeTokenInformationClass[] = { IQS_SAME(0, 0, 0), /* TokenUser */ - IQS_SAME(TOKEN_USER, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_USER, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenGroups */ - IQS_SAME(TOKEN_GROUPS, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_GROUPS, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenPrivileges */ - IQS_SAME(TOKEN_PRIVILEGES, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_PRIVILEGES, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenOwner */ - IQS_SAME(TOKEN_OWNER, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_OWNER, ULONG, ICIF_QUERY | ICIF_SET | ICIF_SIZE_VARIABLE), /* TokenPrimaryGroup */ - IQS_SAME(TOKEN_PRIMARY_GROUP, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_PRIMARY_GROUP, ULONG, ICIF_QUERY | ICIF_SET | ICIF_SIZE_VARIABLE), /* TokenDefaultDacl */ - IQS_SAME(TOKEN_DEFAULT_DACL, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_DEFAULT_DACL, ULONG, ICIF_QUERY | ICIF_SET | ICIF_SIZE_VARIABLE), /* TokenSource */ - IQS_SAME(TOKEN_SOURCE, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_SOURCE, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenType */ IQS_SAME(TOKEN_TYPE, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenImpersonationLevel */ - IQS_SAME(SECURITY_IMPERSONATION_LEVEL, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), + IQS_SAME(SECURITY_IMPERSONATION_LEVEL, ULONG, ICIF_QUERY), /* TokenStatistics */ - IQS_SAME(TOKEN_STATISTICS, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE | ICIF_SET_SIZE_VARIABLE), + IQS_SAME(TOKEN_STATISTICS, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenRestrictedSids */ IQS_SAME(TOKEN_GROUPS, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenSessionId */ @@ -71,13 +61,13 @@ static const INFORMATION_CLASS_INFO SeTokenInformationClass[] = { /* TokenGroupsAndPrivileges */ IQS_SAME(TOKEN_GROUPS_AND_PRIVILEGES, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), /* TokenSessionReference */ - IQS_SAME(ULONG, ULONG, ICIF_SET | ICIF_QUERY_SIZE_VARIABLE), + IQS_SAME(ULONG, ULONG, ICIF_SET), /* TokenSandBoxInert */ - IQS_SAME(ULONG, ULONG, ICIF_QUERY | ICIF_QUERY_SIZE_VARIABLE), + IQS_SAME(ULONG, ULONG, ICIF_QUERY), /* TokenAuditPolicy */ - IQS_SAME(/* FIXME */0, ULONG, ICIF_QUERY | ICIF_SET | ICIF_QUERY_SIZE_VARIABLE), + IQS_SAME(TOKEN_AUDIT_POLICY_INFORMATION, ULONG, ICIF_SET | ICIF_SET_SIZE_VARIABLE), /* TokenOrigin */ - IQS_SAME(TOKEN_ORIGIN, ULONG, ICIF_QUERY | ICIF_SET | ICIF_QUERY_SIZE_VARIABLE), + IQS_SAME(TOKEN_ORIGIN, ULONG, ICIF_QUERY | ICIF_SET), }; /* FUNCTIONS *****************************************************************/
3 years, 6 months
1
0
0
0
[reactos] 01/01: [SHELL32_APITEST] Strengthen and improve ShellHook testcase (#3687)
by Katayama Hirofumi MZ
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=d21adc9b311ed43bcc8c4…
commit d21adc9b311ed43bcc8c45c0d8f538df2d4afd9a Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com> AuthorDate: Sat May 29 09:33:46 2021 +0900 Commit: GitHub <noreply(a)github.com> CommitDate: Sat May 29 09:33:46 2021 +0900 [SHELL32_APITEST] Strengthen and improve ShellHook testcase (#3687) - Add tests to find the missing parameters against HSHELL_WINDOWCREATED conditions. - Improve code readability. CORE-15669 --- modules/rostests/apitests/shell32/ShellHook.cpp | 524 ++++++++++-------------- 1 file changed, 225 insertions(+), 299 deletions(-) diff --git a/modules/rostests/apitests/shell32/ShellHook.cpp b/modules/rostests/apitests/shell32/ShellHook.cpp index ee4e8d9babf..c1ab2eaa5df 100644 --- a/modules/rostests/apitests/shell32/ShellHook.cpp +++ b/modules/rostests/apitests/shell32/ShellHook.cpp @@ -2,7 +2,7 @@ * PROJECT: ReactOS api tests * LICENSE: LGPL-2.0-or-later (
https://spdx.org/licenses/LGPL-2.0-or-later
) * PURPOSE: Test for Shell Hook - * COPYRIGHT: Copyright 2020 Katayama Hirofumi MZ (katayama.hirofumi.mz(a)gmail.com) + * COPYRIGHT: Copyright 2020-2021 Katayama Hirofumi MZ (katayama.hirofumi.mz(a)gmail.com) */ #include "shelltest.h" #include "undocshell.h" @@ -11,7 +11,7 @@ static UINT s_uShellHookMsg = 0; static HWND s_hwndHookViewer = NULL; static HWND s_hwndParent = NULL; static HWND s_hwndTarget = NULL; -static DWORD s_dwFlags = 0; +static UINT s_nWindowCreatedCount = 0; static WCHAR s_szName[] = L"ReactOS ShellHook testcase"; static HWND @@ -25,7 +25,7 @@ DoCreateWindow(HWND hwndParent, DWORD style, DWORD exstyle) struct TEST_ENTRY { INT lineno; - DWORD dwFlags; + UINT nCount; BOOL bIsChild; BOOL bHasOwner; DWORD style; @@ -36,6 +36,7 @@ struct TEST_ENTRY #define STYLE_0 WS_POPUP #define STYLE_1 (WS_POPUP | WS_VISIBLE) +#define STYLE_2 (WS_OVERLAPPED | WS_VISIBLE) #define EXSTYLE_0 0 #define EXSTYLE_1 WS_EX_APPWINDOW @@ -48,269 +49,215 @@ struct TEST_ENTRY static const TEST_ENTRY s_entries[] = { - // STYLE_0, EXSTYLE_0 + // TYPE_0 { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_0, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_0, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_0, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_0, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_0, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_0, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_0, STYLE_2, EXSTYLE_3 }, - // STYLE_1, EXSTYLE_0 - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, + // TYPE_1 { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 3, TYPE_0, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, - - // STYLE_0, EXSTYLE_1 - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, - - // STYLE_1, EXSTYLE_1 - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0xB, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0xB, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x1B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0x1B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x4B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0x4B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x5B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x5B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x2B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0x2B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x3B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0x3B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x6B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0x6B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0xB, TYPE_0, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x7B, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x7B, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, - - // STYLE_0, EXSTYLE_2 - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_2, STYLE_1, EXSTYLE_3 }, - - // STYLE_1, EXSTYLE_2 - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_3 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_1 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_1 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0, TYPE_0, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_1, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_1 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_1, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_3 }, + + // TYPE_2 + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_0, STYLE_2, EXSTYLE_3 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_1 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_1, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_1, EXSTYLE_3 }, - - // STYLE_0, EXSTYLE_3 - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0, TYPE_0, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0, TYPE_1, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0, TYPE_2, STYLE_0, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, - - // STYLE_1, EXSTYLE_3 - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0xF, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, - { __LINE__, 0xF, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x1F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, - { __LINE__, 0x1F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x4F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_1 }, - { __LINE__, 0x4F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_1 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x5F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_1 }, - { __LINE__, 0x5F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_1 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x2F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, - { __LINE__, 0x2F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x3F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, - { __LINE__, 0x3F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x6F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, - { __LINE__, 0x6F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, - - { __LINE__, 0xF, TYPE_0, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x7F, TYPE_1, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, - { __LINE__, 0x7F, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_1, EXSTYLE_2, STYLE_2, EXSTYLE_3 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_1 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_1 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_0 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_1 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_2 }, + { __LINE__, 1, TYPE_2, STYLE_1, EXSTYLE_3, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_0, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_1, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_2, STYLE_2, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_0, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_1, EXSTYLE_3 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_0 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_1 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_2 }, + { __LINE__, 0, TYPE_2, STYLE_2, EXSTYLE_3, STYLE_2, EXSTYLE_3 }, }; static const size_t s_num_entries = sizeof(s_entries) / sizeof(s_entries[0]); @@ -333,14 +280,15 @@ static void DoTestEntryPart1(const TEST_ENTRY *pEntry) else style &= ~WS_CHILD; - s_dwFlags = 0; + s_nWindowCreatedCount = 0; s_hwndTarget = DoCreateWindow(s_hwndParent, style, exstyle); } static void DoTestEntryPart2(const TEST_ENTRY *pEntry) { - ok(s_dwFlags == pEntry->dwFlags, "Line %d: s_dwFlags expected 0x%lX but was 0x%lX\n", - pEntry->lineno, pEntry->dwFlags, s_dwFlags); + ok(s_nWindowCreatedCount == pEntry->nCount, + "Line %d: s_nWindowCreatedCount expected %u but was %u\n", + pEntry->lineno, pEntry->nCount, s_nWindowCreatedCount); PostMessageW(s_hwndTarget, WM_CLOSE, 0, 0); s_hwndTarget = NULL; @@ -357,65 +305,43 @@ WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { if (uMsg == s_uShellHookMsg && uMsg != 0) { - DWORD style, exstyle, owner_style, owner_exstyle; - HWND hwndOwner; - DWORD dwFlags; switch (wParam) { case HSHELL_WINDOWCREATED: if ((HWND)lParam != s_hwndTarget) break; - style = (LONG)GetWindowLongPtrW(s_hwndTarget, GWL_STYLE); - exstyle = (LONG)GetWindowLongPtrW(s_hwndTarget, GWL_EXSTYLE); - if (style & WS_CHILD) - hwndOwner = GetParent(s_hwndTarget); - else - hwndOwner = GetWindow(s_hwndTarget, GW_OWNER); - owner_style = (LONG)GetWindowLongPtrW(hwndOwner, GWL_STYLE); - owner_exstyle = (LONG)GetWindowLongPtrW(hwndOwner, GWL_EXSTYLE); - dwFlags = (1 << 0); - if (style & WS_VISIBLE) - dwFlags |= (1 << 1); - if (exstyle & WS_EX_TOOLWINDOW) - dwFlags |= (1 << 2); - if (exstyle & WS_EX_APPWINDOW) - dwFlags |= (1 << 3); - if (owner_style & WS_VISIBLE) - dwFlags |= (1 << 4); - if (owner_exstyle & WS_EX_TOOLWINDOW) - dwFlags |= (1 << 5); - if (owner_exstyle & WS_EX_APPWINDOW) - dwFlags |= (1 << 6); - s_dwFlags = dwFlags; + ++s_nWindowCreatedCount; break; } } +#define ID_IGNITION 1000 +#define ID_BURNING 2000 switch (uMsg) { case WM_CREATE: - PostMessageW(hwnd, WM_COMMAND, 1000, 0); + PostMessageW(hwnd, WM_COMMAND, ID_IGNITION, 0); return DefWindowProcW(hwnd, uMsg, wParam, lParam); case WM_COMMAND: - if (hwnd == s_hwndHookViewer) + if (hwnd != s_hwndHookViewer) + break; + + if (ID_IGNITION <= wParam && wParam < ID_BURNING) { - if (1000 <= wParam && wParam < 2000) - { - INT i = (INT)wParam - 1000; - DoTestEntryPart1(&s_entries[i]); - PostMessageW(hwnd, WM_COMMAND, 2000 + i, 0); - } - else if (2000 <= wParam && wParam < 3000) + INT i = (INT)wParam - ID_IGNITION; + DoTestEntryPart1(&s_entries[i]); + PostMessageW(hwnd, WM_COMMAND, ID_BURNING + i, 0); + } + else if (ID_BURNING <= wParam) + { + INT i = (INT)wParam - ID_BURNING; + DoTestEntryPart2(&s_entries[i]); + ++i; + if (i == s_num_entries) { - INT i = (INT)wParam - 2000; - DoTestEntryPart2(&s_entries[i]); - ++i; - if (i == s_num_entries) - { - PostQuitMessage(0); - break; - } - PostMessageW(hwnd, WM_COMMAND, 1000 + i, 0); + PostQuitMessage(0); + break; } + PostMessageW(hwnd, WM_COMMAND, ID_IGNITION + i, 0); } break; default:
3 years, 7 months
1
0
0
0
← Newer
1
2
3
4
...
19
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Results per page:
10
25
50
100
200