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
July 2016
----- 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
18 participants
358 discussions
Start a n
N
ew thread
[hbelusca] 71836: [EVENTVWR]: Improve the user interface of the Event Log Viewer: - Use a tree to list the available system logs (and in the future, the manually opened logs within the viewer). - A...
by hbelusca@svn.reactos.org
Author: hbelusca Date: Wed Jul 6 23:14:56 2016 New Revision: 71836 URL:
http://svn.reactos.org/svn/reactos?rev=71836&view=rev
Log: [EVENTVWR]: Improve the user interface of the Event Log Viewer: - Use a tree to list the available system logs (and in the future, the manually opened logs within the viewer). - Allow the user to resize the treeview/listview. - Use the standard shell about-box dialog to display the "About..." notice + copyright. - Improve the Event Log Viewer icon, and add new ones (folders + eventlog file). Added: trunk/reactos/base/applications/mscutils/eventvwr/res/eventlog.ico (with props) Modified: trunk/reactos/base/applications/mscutils/eventvwr/CMakeLists.txt trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.c trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc trunk/reactos/base/applications/mscutils/eventvwr/res/eventvwr.ico trunk/reactos/base/applications/mscutils/eventvwr/res/folder.ico trunk/reactos/base/applications/mscutils/eventvwr/res/folderopen.ico trunk/reactos/base/applications/mscutils/eventvwr/resource.h Modified: trunk/reactos/base/applications/mscutils/eventvwr/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/CMakeLists.txt [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/CMakeLists.txt [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -3,7 +3,7 @@ add_rc_deps(eventvwr.rc ${eventvwr_rc_deps}) add_executable(eventvwr eventvwr.c eventvwr.rc) set_module_type(eventvwr win32gui UNICODE) -add_importlibs(eventvwr user32 gdi32 comctl32 comdlg32 advapi32 msvcrt kernel32 ntdll) +add_importlibs(eventvwr user32 gdi32 comctl32 comdlg32 advapi32 shell32 msvcrt kernel32 ntdll) if(MSVC) add_importlibs(eventvwr ntdll) Modified: trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.c [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.c [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -25,15 +25,20 @@ #include <stdio.h> #include <stdlib.h> + #include <windef.h> #include <winbase.h> #include <winuser.h> #include <wingdi.h> #include <winnls.h> #include <winreg.h> +#include <shellapi.h> + +#include <windowsx.h> #include <commctrl.h> #include <richedit.h> #include <commdlg.h> + #include <strsafe.h> /* Missing RichEdit flags in our richedit.h */ @@ -65,16 +70,23 @@ #define MAX_LOADSTRING 255 #define ENTRY_SIZE 2056 +#define SPLIT_WIDTH 4 + /* Globals */ HINSTANCE hInst; /* current instance */ WCHAR szTitle[MAX_LOADSTRING]; /* The title bar text */ WCHAR szTitleTemplate[MAX_LOADSTRING]; /* The logged-on title bar text */ WCHAR szSaveFilter[MAX_LOADSTRING]; /* Filter Mask for the save Dialog */ +INT nSplitPos; /* Splitter position */ HWND hwndMainWindow; /* Main window */ +HWND hwndTreeView; /* TreeView control */ HWND hwndListView; /* ListView control */ HWND hwndStatus; /* Status bar */ HMENU hMainMenu; /* The application's main menu */ WCHAR szStatusBarTemplate[MAX_LOADSTRING]; /* The status bar text */ + +HTREEITEM htiSystemLogs = NULL, htiUserLogs = NULL; + PEVENTLOGRECORD *g_RecordPtrs = NULL; DWORD g_TotalRecords = 0; OPENFILENAMEW sfn; @@ -89,16 +101,15 @@ ATOM MyRegisterClass(HINSTANCE hInstance); BOOL InitInstance(HINSTANCE, int); LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM); -INT_PTR CALLBACK About(HWND, UINT, WPARAM, LPARAM); INT_PTR CALLBACK EventDetails(HWND, UINT, WPARAM, LPARAM); static INT_PTR CALLBACK StatusMessageWindowProc (HWND, UINT, WPARAM, LPARAM); int APIENTRY wWinMain(HINSTANCE hInstance, - HINSTANCE hPrevInstance, - LPWSTR lpCmdLine, - int nCmdShow) + HINSTANCE hPrevInstance, + LPWSTR lpCmdLine, + int nCmdShow) { MSG msg; HACCEL hAccelTable; @@ -700,7 +711,7 @@ break; case EVENTLOG_AUDIT_FAILURE: - lviEventItem.iImage = 2; + lviEventItem.iImage = 2; // FIXME! break; case EVENTLOG_WARNING_TYPE: @@ -712,7 +723,7 @@ break; case EVENTLOG_AUDIT_SUCCESS: - lviEventItem.iImage = 0; + lviEventItem.iImage = 0; // FIXME! break; case EVENTLOG_SUCCESS: @@ -882,7 +893,7 @@ wcex.hInstance = hInstance; wcex.hIcon = LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_EVENTVWR)); wcex.hCursor = LoadCursorW(NULL, MAKEINTRESOURCEW(IDC_ARROW)); - wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW + 1); + wcex.hbrBackground = (HBRUSH)(COLOR_BTNFACE + 1); // COLOR_WINDOW + 1 wcex.lpszMenuName = MAKEINTRESOURCEW(IDM_EVENTVWR); wcex.lpszClassName = szWindowClass; wcex.hIconSm = (HICON)LoadImageW(hInstance, @@ -968,6 +979,28 @@ return dwMessageID; } + + + + +HTREEITEM +TreeViewAddItem(HWND hTreeView, HTREEITEM hParent, LPWSTR lpText, INT Image, INT SelectedImage, LPARAM lParam) +{ + TV_INSERTSTRUCTW Insert; + + ZeroMemory(&Insert, sizeof(Insert)); + + Insert.item.mask = TVIF_TEXT | TVIF_PARAM | TVIF_IMAGE | TVIF_SELECTEDIMAGE; + Insert.hInsertAfter = TVI_LAST; + Insert.hParent = hParent; + Insert.item.pszText = lpText; + Insert.item.iImage = Image; + Insert.item.iSelectedImage = SelectedImage; + Insert.item.lParam = lParam; + + return TreeView_InsertItem(hTreeView, &Insert); +} + VOID @@ -982,6 +1015,7 @@ DWORD dwMessageID; LPWSTR lpDisplayName; HMODULE hLibrary = NULL; + HTREEITEM hItem = NULL, hItemDefault = NULL; /* Open the EventLog key */ if (RegOpenKeyExW(HKEY_LOCAL_MACHINE, EVENTLOG_BASE_KEY, 0, KEY_READ, &hKey) != ERROR_SUCCESS) @@ -1065,13 +1099,14 @@ } } - if (lpDisplayName) - { - InsertMenuW(hMainMenu, IDM_SAVE_EVENTLOG, MF_BYCOMMAND | MF_STRING, ID_FIRST_LOG + dwIndex, lpDisplayName); - } - else - { - InsertMenuW(hMainMenu, IDM_SAVE_EVENTLOG, MF_BYCOMMAND | MF_STRING, ID_FIRST_LOG + dwIndex, LogNames[dwIndex]); + hItem = TreeViewAddItem(hwndTreeView, htiSystemLogs, + (lpDisplayName ? lpDisplayName : LogNames[dwIndex]), + 2, 3, dwIndex); + + /* Try to get the default event log: "Application" */ + if ((hItemDefault == NULL) && (wcsicmp(LogNames[dwIndex], L"Application") == 0)) + { + hItemDefault = hItem; } /* Free the buffer allocated by FormatMessage */ @@ -1079,11 +1114,15 @@ LocalFree(lpDisplayName); } - InsertMenuW(hMainMenu, IDM_SAVE_EVENTLOG, MF_BYCOMMAND | MF_SEPARATOR, ID_FIRST_LOG + dwIndex + 1, NULL); - HeapFree(GetProcessHeap(), 0, LogName); RegCloseKey(hKey); + /* Select the default event log */ + TreeView_Expand(hwndTreeView, htiSystemLogs, TVE_EXPAND); + TreeView_SelectItem(hwndTreeView, hItemDefault); + TreeView_EnsureVisible(hwndTreeView, hItemDefault); + SetFocus(hwndTreeView); + return; } @@ -1104,11 +1143,7 @@ { HeapFree(GetProcessHeap(), 0, LogNames[dwIndex]); } - - DeleteMenu(hMainMenu, ID_FIRST_LOG + dwIndex, MF_BYCOMMAND); - } - - DeleteMenu(hMainMenu, ID_FIRST_LOG + dwIndex + 1, MF_BYCOMMAND); + } HeapFree(GetProcessHeap(), 0, LogNames); LogNames = NULL; @@ -1125,6 +1160,8 @@ InitInstance(HINSTANCE hInstance, int nCmdShow) { + RECT rcClient, rs; + LONG StatusHeight; HIMAGELIST hSmall; LVCOLUMNW lvc = {0}; WCHAR szTemp[256]; @@ -1154,24 +1191,67 @@ hInstance, // instance NULL); // window data + nSplitPos = 250; + + GetClientRect(hwndMainWindow, &rcClient); + GetWindowRect(hwndStatus, &rs); + StatusHeight = rs.bottom - rs.top - 3 /* hack */; + + hwndTreeView = CreateWindowExW(WS_EX_CLIENTEDGE, + WC_TREEVIEWW, + L"", + // WS_CHILD | WS_VISIBLE | TVS_HASLINES | TVS_SHOWSELALWAYS, + WS_CHILD | WS_VISIBLE | /* WS_TABSTOP | */ TVS_HASLINES | TVS_HASBUTTONS | TVS_LINESATROOT | TVS_EDITLABELS | TVS_SHOWSELALWAYS, + 0, + 0, + nSplitPos - SPLIT_WIDTH/2, + (rcClient.bottom - rcClient.top) - StatusHeight, + hwndMainWindow, + NULL, + hInstance, + NULL); + + /* Create the ImageList */ + hSmall = ImageList_Create(GetSystemMetrics(SM_CXSMICON), + GetSystemMetrics(SM_CYSMICON), + ILC_COLOR32 | ILC_MASK, // ILC_COLOR24 + 1, 1); + + /* Add event type icons to the ImageList: closed/opened folder, event log (normal/viewed) */ + ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_CLOSED_CATEGORY))); + ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_OPENED_CATEGORY))); + ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_EVENTLOG))); + ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_EVENTVWR))); + + /* Assign the ImageList to the Tree View */ + TreeView_SetImageList(hwndTreeView, hSmall, TVSIL_NORMAL); + + /* Add the event logs nodes */ + // "System Logs" + LoadStringW(hInstance, IDS_EVENTLOG_SYSTEM, szTemp, ARRAYSIZE(szTemp)); + htiSystemLogs = TreeViewAddItem(hwndTreeView, NULL, szTemp, 0, 1, (LPARAM)-1); + // "User Logs" + LoadStringW(hInstance, IDS_EVENTLOG_USER, szTemp, ARRAYSIZE(szTemp)); + htiUserLogs = TreeViewAddItem(hwndTreeView, NULL, szTemp, 0, 1, (LPARAM)-1); + // Create our listview child window. Note that I use WS_EX_CLIENTEDGE // and WS_BORDER to create the normal "sunken" look. Also note that // LVS_EX_ styles cannot be set in CreateWindowEx(). hwndListView = CreateWindowExW(WS_EX_CLIENTEDGE, WC_LISTVIEWW, L"", - LVS_SHOWSELALWAYS | WS_CHILD | WS_VISIBLE | LVS_REPORT, + WS_CHILD | WS_VISIBLE | LVS_SHOWSELALWAYS | LVS_REPORT, + nSplitPos + SPLIT_WIDTH/2, 0, - 0, - 243, - 200, + (rcClient.right - rcClient.left) - nSplitPos - SPLIT_WIDTH/2, + (rcClient.bottom - rcClient.top) - StatusHeight, hwndMainWindow, NULL, hInstance, NULL); /* After the ListView is created, we can add extended list view styles */ - (void)ListView_SetExtendedListViewStyle (hwndListView, LVS_EX_FULLROWSELECT); + (void)ListView_SetExtendedListViewStyle(hwndListView, LVS_EX_FULLROWSELECT); /* Create the ImageList */ hSmall = ImageList_Create(GetSystemMetrics(SM_CXSMICON), @@ -1179,12 +1259,12 @@ ILC_COLOR32 | ILC_MASK, // ILC_COLOR24 1, 1); - /* Add event type icons to ImageList */ + /* Add event type icons to the ImageList */ ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_INFORMATIONICON))); ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_WARNINGICON))); ImageList_AddIcon(hSmall, LoadIconW(hInstance, MAKEINTRESOURCEW(IDI_ERRORICON))); - /* Assign ImageList to List View */ + /* Assign the ImageList to the List View */ (void)ListView_SetImageList(hwndListView, hSmall, LVSIL_SMALL); /* Now set up the listview with its columns */ @@ -1275,20 +1355,50 @@ // At the moment we only support the user local computer. lpComputerName = NULL; BuildLogList(); - - QueryEventMessages(lpComputerName, LogNames[0]); - - CheckMenuRadioItem(GetMenu(hwndMainWindow), ID_FIRST_LOG, ID_FIRST_LOG + dwNumLogs, ID_FIRST_LOG, MF_BYCOMMAND); + // QueryEventMessages(lpComputerName, LogNames[0]); return TRUE; } +VOID ResizeWnd(INT cx, INT cy) +{ + HDWP hdwp; + RECT rs; + LONG StatusHeight; + + /* Size status bar */ + SendMessage(hwndStatus, WM_SIZE, 0, 0); + GetWindowRect(hwndStatus, &rs); + StatusHeight = rs.bottom - rs.top - 3 /* hack */; + + nSplitPos = min(max(nSplitPos, SPLIT_WIDTH/2), cx - SPLIT_WIDTH/2); + + hdwp = BeginDeferWindowPos(2); + + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hwndTreeView, + 0, + 0, 0, + nSplitPos - SPLIT_WIDTH/2, cy - StatusHeight, + SWP_NOZORDER | SWP_NOACTIVATE); + + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hwndListView, + 0, + nSplitPos + SPLIT_WIDTH/2, 0, + cx - nSplitPos - SPLIT_WIDTH/2, cy - StatusHeight, + SWP_NOZORDER | SWP_NOACTIVATE); + + if (hdwp) + EndDeferWindowPos(hdwp); +} LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) { RECT rect; - NMHDR *hdr; switch (message) { @@ -1305,14 +1415,16 @@ } case WM_NOTIFY: - switch (((LPNMHDR)lParam)->code) + { + LPNMHDR hdr = (LPNMHDR)lParam; + + if (hdr->hwndFrom == hwndListView) { - case NM_DBLCLK: - hdr = (NMHDR FAR*)lParam; - if (hdr->hwndFrom == hwndListView) + switch (hdr->code) + { + case NM_DBLCLK: { LPNMITEMACTIVATE lpnmitem = (LPNMITEMACTIVATE)lParam; - if (lpnmitem->iItem != -1) { DialogBoxW(hInst, @@ -1320,26 +1432,33 @@ hWnd, EventDetails); } - } - break; - } - break; - - case WM_COMMAND: - { - /* Parse the menu selections */ - if ((LOWORD(wParam) >= ID_FIRST_LOG) && (LOWORD(wParam) <= ID_FIRST_LOG + dwNumLogs)) - { - if (LogNames[LOWORD(wParam) - ID_FIRST_LOG]) - { - if (QueryEventMessages(lpComputerName, LogNames[LOWORD(wParam) - ID_FIRST_LOG])) - { - CheckMenuRadioItem(GetMenu(hWnd), ID_FIRST_LOG, ID_FIRST_LOG + dwNumLogs, LOWORD(wParam), MF_BYCOMMAND); + break; } } } - else - + else if (hdr->hwndFrom == hwndTreeView) + { + switch (hdr->code) + { + case TVN_SELCHANGED: + { + DWORD dwIndex = ((LPNMTREEVIEW)lParam)->itemNew.lParam; + + if ((dwIndex <= dwNumLogs) && LogNames[dwIndex]) + { + QueryEventMessages(lpComputerName, LogNames[dwIndex]); + } + + break; + } + } + } + break; + } + + case WM_COMMAND: + { + /* Parse the menu selections */ switch (LOWORD(wParam)) { case IDM_SAVE_EVENTLOG: @@ -1358,8 +1477,16 @@ break; case IDM_ABOUT: - DialogBoxW(hInst, MAKEINTRESOURCEW(IDD_ABOUTBOX), hWnd, About); + { + HICON hIcon; + WCHAR szCopyright[MAX_LOADSTRING]; + + hIcon = LoadIconW(hInst, MAKEINTRESOURCEW(IDI_EVENTVWR)); + LoadStringW(hInst, IDS_COPYRIGHT, szCopyright, ARRAYSIZE(szCopyright)); + ShellAboutW(hWnd, szTitle, szCopyright, hIcon); + DeleteObject(hIcon); break; + } case IDM_HELP: MessageBoxW(hwndMainWindow, @@ -1378,52 +1505,77 @@ break; } - case WM_SIZE: - { + case WM_SETCURSOR: + if (LOWORD(lParam) == HTCLIENT) + { + POINT pt; + GetCursorPos(&pt); + ScreenToClient(hWnd, &pt); + if (pt.x >= nSplitPos - SPLIT_WIDTH/2 && pt.x < nSplitPos + SPLIT_WIDTH/2 + 1) + { + SetCursor(LoadCursorW(NULL, IDC_SIZEWE)); + return TRUE; + } + } + goto Default; + + case WM_LBUTTONDOWN: + { + INT x = GET_X_LPARAM(lParam); GetClientRect(hWnd, &rect); - - MoveWindow(hwndListView, - 0, - 0, - rect.right, - rect.bottom - 20, - 1); - - SendMessageW(hwndStatus, message, wParam, lParam); - break; - } - - default: - return DefWindowProcW(hWnd, message, wParam, lParam); - } - - return 0; -} - - -/* Message handler for About box */ -INT_PTR CALLBACK -About(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) -{ - UNREFERENCED_PARAMETER(lParam); - switch (message) - { - case WM_INITDIALOG: - { - return (INT_PTR)TRUE; - } - - case WM_COMMAND: - if (LOWORD(wParam) == IDOK || LOWORD(wParam) == IDCANCEL) + if (x >= nSplitPos - SPLIT_WIDTH/2 && x < nSplitPos + SPLIT_WIDTH/2 + 1) { - EndDialog(hDlg, LOWORD(wParam)); - return (INT_PTR)TRUE; + SetCapture(hWnd); } break; - } - - return (INT_PTR)FALSE; -} + } + + case WM_LBUTTONUP: + case WM_RBUTTONDOWN: + if (GetCapture() == hWnd) + { + GetClientRect(hWnd, &rect); + nSplitPos = GET_X_LPARAM(lParam); + ResizeWnd(rect.right, rect.bottom); + ReleaseCapture(); + } + break; + + // case WM_CAPTURECHANGED: + // if (GetCapture() == hWnd && last_split>=0) + // draw_splitbar(hWnd, last_split); + // break; + + case WM_MOUSEMOVE: + if (GetCapture() == hWnd) + { + INT x = GET_X_LPARAM(lParam); + + GetClientRect(hWnd, &rect); + + x = min(max(x, SPLIT_WIDTH/2), rect.right - rect.left - SPLIT_WIDTH/2); + if (nSplitPos != x) + { + nSplitPos = x; + ResizeWnd(rect.right - rect.left, rect.bottom - rect.top); + } + } + break; + + case WM_SIZE: + { + // GetClientRect(hWnd, &rect); + ResizeWnd(LOWORD(lParam), HIWORD(lParam)); + break; + } + + default: Default: + return DefWindowProcW(hWnd, message, wParam, lParam); + } + + return 0; +} + VOID DisplayEvent(HWND hDlg) Modified: trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/eventvwr.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -15,6 +15,10 @@ /* Shared icons */ IDI_EVENTVWR ICON "res/eventvwr.ico" +IDI_EVENTLOG ICON "res/eventlog.ico" +IDI_CLOSED_CATEGORY ICON "res/folder.ico" +IDI_OPENED_CATEGORY ICON "res/folderopen.ico" + IDI_WARNINGICON ICON "res/warning.ico" IDI_INFORMATIONICON ICON "res/info.ico" IDI_ERRORICON ICON "res/error.ico" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -27,17 +27,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Ðа" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ÐÑеглед на ÑÑбиÑиÑ, в 1,0 за РеакÑÐС", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "ÐобÑе", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -89,9 +79,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ÐÑеглед на ÑÑбиÑиÑ" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Ðе е намеÑено опиÑаниеÑо на ÑÑбиÑие ( %lu ) в изÑоÑник ( %s ). ÐÑзможно е меÑÑиÑÑ ÐºÐ¾Ð¼Ð¿ÑÑÑÑ Ð´Ð° нÑма нÑжниÑе ÑÐ²ÐµÐ´ÐµÐ½Ð¸Ñ Ð² ÑегиÑÑÑÑа или DLL ÑайловеÑ, нÑжни за показване на ÑÑобÑÐµÐ½Ð¸Ñ Ð¾Ñ Ð¾ÑдалеÑен компÑÑÑÑ.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Error" IDS_EVENTLOG_WARNING_TYPE "Warning" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -27,17 +27,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "O programu" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS ProhlÞeÄ událostà 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -89,9 +79,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ProhlÞeÄ událostÃ" IDS_APP_TITLE_EX "%s - Protkol %s na \\\\" IDS_STATUS_MSG "PoÄet událostà v protokolu %s: %lu" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Popis ID události ( %lu ) zdroj ( %s ) nebyl nalezen. MÃstnà poÄÃtaÄ neobsahuje potÅebné informace v registru nebo chybà DLL soubory pro zobrazenà zpráv ze vzdáleného poÄÃtaÄe.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Chyba" IDS_EVENTLOG_WARNING_TYPE "UpozornÄnÃ" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Ãber" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Ereignisanzeige 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Ereignisanzeige" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Die Bezeichnung für die Ereignis-ID ( %lu ) in der Quelle ( %s ) kann nicht gefunden werden. Es könnte sein, dass der Lokale Computer die notwendigen Registry Einträge oder Nachrichten DLLs, um Nachrichten von Remoten Computern anzuzeigen, nicht besitzt.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Fehler" IDS_EVENTLOG_WARNING_TYPE "Warnung" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "ΣÏεÏικά" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Event Viewer Version 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Event Viewer" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "The description for Event ID ( %lu ) in Source ( %s ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "ÎÏάλμα" IDS_EVENTLOG_WARNING_TYPE "Î ÏοειδοÏοίηÏη" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -35,17 +35,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "About" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Event Viewer Version 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -97,9 +87,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Event Viewer" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "The description for Event ID ( %lu ) in Source ( %s ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Error" IDS_EVENTLOG_WARNING_TYPE "Warning" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Acerca de" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "Visor de eventos de ReactOS. Versión 1.0", IDC_STATIC, 49, 10, 124, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "Aceptar", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visor de eventos" IDS_APP_TITLE_EX "%s - Registro de %s en \\\\" IDS_STATUS_MSG "%s tiene %lu evento(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "No se pudo recuperar la descripción para el evento con ID (%lu) y origen (%s). El equipo local puede no tener la información necesaria en el registro o las DLLs necesarias para mostrar los mensajes de un equipo remoto.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Error" IDS_EVENTLOG_WARNING_TYPE "Advertencia" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "à propos" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "Visionneuse des événements ReactOS Version 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visionneuse d'événements" IDS_APP_TITLE_EX "%s - Journal %s sur \\\\" IDS_STATUS_MSG "%s contient %lu événement(s)" + IDS_EVENTLOG_SYSTEM "Journaux système" + IDS_EVENTLOG_USER "Journaux de l'utilisateur" IDS_EVENTSTRINGIDNOTFOUND "La description pour l'événement d'ID ( %lu ) dans la source ( %s ) ne peut être trouvée. L'ordinateur local pourrait ne pas avoir les informations registres nécessaires ou les fichiers DLL de message pour afficher les messages depuis un ordinateur distant.\n\nLes informations suivantes font partie de l'événement :\n\n" IDS_EVENTLOG_ERROR_TYPE "Erreur" IDS_EVENTLOG_WARNING_TYPE "Avertissement" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "××××ת" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "×צ×× ×××ר××¢×× ×©× ReactOS ××¨×¡× 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "××ש×ר", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "×××× ×××ר××¢××" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "The description for Event ID ( %lu ) in Source ( %s ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "ש××××" IDS_EVENTLOG_WARNING_TYPE "×××ר×" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Informazioni su" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Visualizzatore eventi Versione 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visualizzatore eventi" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "La descrizione per l'ID evento ( %lu ) proveniente da ( %s ) non può essere trovata. Il computer locale potrebbe non avere le informazioni sul registry necessarie o i file DLL con i messaggi necessari per la visualizzazione da un computer remoto.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Errore" IDS_EVENTLOG_WARNING_TYPE "Avviso" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "ãã¼ã¸ã§ã³æ å ±" -FONT 9, "MS UI Gothic", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS ã¤ãã³ã ãã¥ã¼ã¢ Version 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ã¤ãã³ã ãã¥ã¼ã¢" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "ã¤ãã³ã ID (%lu) (ã½ã¼ã¹ %s å ) ã«é¢ãã説æãè¦ã¤ããã¾ããã§ããã ãªã¢ã¼ã ã³ã³ãã¥ã¼ã¿ããã¡ãã»ã¼ã¸ã表示ããããã«å¿ è¦ãªã¬ã¸ã¹ããªæ å ±ã¾ãã¯ã¡ãã»ã¼ã¸ DLL ãã¡ã¤ã«ããã¼ã«ã« ã³ã³ãã¥ã¼ã¿ã«ãªãå¯è½æ§ãããã¾ãã\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "ã¨ã©ã¼" IDS_EVENTLOG_WARNING_TYPE "è¦å" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "ì ë³´" -FONT 9, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS ì´ë²¤í¸ ë·°ì´ Version 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "íì¸", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ì´ë²¤í¸ ë·°ì´" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "( %s ) ì ì´ë²¤í¸ID ( %lu ) ì ëí ì¤ëª ì ì°¾ì ì ììµëë¤. ë¡ì»¬ ì»´í¨í°ê° ì격 ì»´í¨í°ì ë©ì¸ì§ë¥¼ íìíëë° íìí ë ì§ì¤í¸ë¦¬ë DLL íì¼ì ê°ì§ì§ ìê³ ììì ììµëë¤.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "ìë¬" IDS_EVENTLOG_WARNING_TYPE "ê²½ê³ " Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -27,17 +27,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Om" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Hendelseliste Versjon 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -89,9 +79,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Hendelseliste" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Beskrivelsen for Hendelse ID ( %lu ) i kilden ( %s ) kan ikke bli finnet. Lokale datamaskinen har ikke nødvendige register informasjon eller melding DLL filer for å vise melding fra en fjern datamaskin.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Feil" IDS_EVENTLOG_WARNING_TYPE "Advarseler" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -31,17 +31,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "O programie" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "PodglÄ d zdarzeÅ ReactOS wersja 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -93,9 +83,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "PodglÄ d zdarzeÅ" IDS_APP_TITLE_EX "%s - %s Log na \\\\" IDS_STATUS_MSG "%s posiada %lu zdarzeÅ" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Opis zdarzenia dla danego numeru ID ( %lu ) nie zostaÅ odnaleziony w źródle ( %s ). Ten komputer może nie miec wystarczajÄ cych informacji w rejestrze, albo bibliotek DLL, aby wyÅwietliÄ wiadomoÅci z komputera zdalnego.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "BÅÄ d" IDS_EVENTLOG_WARNING_TYPE "Ostrzeżenie" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Sobre" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "Visualizador de Eventos ReactOS Versão 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visualizador de Eventos" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "A descrição para Event ID ( %lu ) em Fonte ( %s ) não foi encontrado. O computador local talvez não possua a informação de registro necessária ou mensagem de arquivos DLL para exibir mensagens de um computador remoto.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Erro" IDS_EVENTLOG_WARNING_TYPE "Aviso" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -32,17 +32,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Despre Observator de evenimente" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "Observator de Evenimente ReactOS Versiunea 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Drept de autor (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 150, 22 - DEFPUSHBUTTON "Ã&nchide", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -94,9 +84,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Drept de autor (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Observator de evenimente" IDS_APP_TITLE_EX "%s - %s autentificat pe \\\\" IDS_STATUS_MSG "%s are %lu eveniment(e)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Nu se poate gÄsi descrierea evenimentului cu ID-ul ( %lu ) în sursa ( %s ). Este posibil ca în calculatorul local sÄ nu existe informaÈiile de registru necesare sau fiÈierele dll de mesaje sÄ afiÈeze mesaje de la un calculator din reÈea.\n\nInformaÈii aferente evenimentului:\n\n" IDS_EVENTLOG_ERROR_TYPE "Eroare" IDS_EVENTLOG_WARNING_TYPE "Avertisment" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "РпÑогÑамме" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ÐÑоÑмоÑÑ ÑобÑÑий ReactOS. ÐеÑÑÐ¸Ñ 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "ÐвÑоÑÑкие пÑава (С) 2007 ÐаÑк ÐиÑлаÑÑ (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 140, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "ÐвÑоÑÑкие пÑава (С) 2007 ÐаÑк ÐиÑлаÑÑ (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ÐÑоÑмоÑÑ ÑобÑÑий" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Ðе найдено опиÑание Ð´Ð»Ñ ÑобÑÑÐ¸Ñ Ñ ÐºÐ¾Ð´Ð¾Ð¼ ( %lu ) в иÑÑоÑнике ( %s ). Ðозможно, на локалÑном компÑÑÑеÑе Ð½ÐµÑ Ð½ÑжнÑÑ Ð´Ð°Ð½Ð½ÑÑ Ð² ÑееÑÑÑе или Ñайлов DLL ÑообÑений Ð´Ð»Ñ Ð¾ÑобÑÐ°Ð¶ÐµÐ½Ð¸Ñ ÑообÑений Ñдаленного компÑÑÑеÑа.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "ÐÑибка" IDS_EVENTLOG_WARNING_TYPE "ÐÑедÑпÑеждение" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -32,17 +32,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Äo je ZobrazovaÄ udalostÃ" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ZobrazovaÄ udalostà systému ReactOS, verzia 1.0", IDC_STATIC, 49, 10, 167, 8, SS_NOPREFIX - LTEXT "Autorské práva (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 167, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -94,9 +84,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Autorské práva (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ZobrazovaÄ udalostÃ" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Popis pre udalosÅ¥ ID ( %lu ) zo zdroja ( %s ) nebol nájdený. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Chyba" IDS_EVENTLOG_WARNING_TYPE "Upozornenie" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -35,17 +35,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Rreth" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Event Viewer Versioni 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -97,9 +87,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Shikues ngjarjesh" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Përshkrimi për ngjarjet ID ( %lu ) në burim ( %s ) nuk gjindet. Kompjuter vendas mund të mos ketë informacionin e regjistrit te nevojshem ose mesazhin për dokumentat DLL për të shfaqur nga një kompjuter në distancë.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Error" IDS_EVENTLOG_WARNING_TYPE "Paralajmërim" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Om" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS Händelselogg Versjon 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Händelselogg" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "Beskrivning av Händelse ID ( %lu ) i källan ( %s ) kan inte hittas. Lokal dator har inte nödvendig registerinformation eller meddelander DLL filer for å vise meddelander från en fjärr dator.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Fel" IDS_EVENTLOG_WARNING_TYPE "Varning" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -35,17 +35,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "Ãzerine" -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "Olay Görüntüleyicisi - Sürüm: 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Telif Hakkı: 2007 - Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "Tamam", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -97,9 +87,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Telif Hakkı: 2007 - Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Olay Görüntüleyicisi" IDS_APP_TITLE_EX "%s - %s Oturum Aç \\\\" IDS_STATUS_MSG "%s -> %lu olay var." + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "( %s ) kaynaÄındaki ( %lu ) olay kimliÄi için açıklama bulunamıyor. Yerli bilgisayarda, uzak bilgisayardan iletileri görüntülemesi için gerekli DeÄer Defteri bilgisi veyâ ileti DLL kütükleri olmayabilir.\n\nAÅaÄıdaki bilgi olayın parçasıdır:\n\n" IDS_EVENTLOG_ERROR_TYPE "YanlıÅlık" IDS_EVENTLOG_WARNING_TYPE "Uyarı" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "ÐÑо..." -FONT 8, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ÐглÑÐ´Ð°Ñ Ð¿Ð¾Ð´Ñй ReactOS веÑÑÑÑ 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "OK", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ÐглÑÐ´Ð°Ñ Ð¿Ð¾Ð´Ñй" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "ÐÐ¿Ð¸Ñ Ð´Ð»Ñ ÐденÑиÑÑкаÑоÑа подÑÑ( %lu ) за джеÑелом ( %s ) не знайдено. ÐокалÑний комп'ÑÑÐµÑ Ð¼Ð¾Ð¶Ðµ не маÑи Ð½ÐµÐ¾Ð±Ñ ÑÐ´Ð½Ð¾Ñ ÑнÑоÑмаÑÑÑ Ð² ÑеÑÑÑÑÑ Ñи DLL ÑайлÑв повÑÐ´Ð¾Ð¼Ð»ÐµÐ½Ñ Ð´Ð»Ñ Ð²ÑдобÑÐ°Ð¶ÐµÐ½Ð½Ñ Ð¿Ð¾Ð²ÑдомленÑ, Ñо Ð½Ð°Ð´Ñ Ð¾Ð´ÑÑÑ Ð²Ñд вÑддаленого комп'ÑÑеÑа.\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "Ðомилка" IDS_EVENTLOG_WARNING_TYPE "ÐопеÑедженнÑ" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "å ³äº" -FONT 9, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS äºä»¶æ¥çå¨ çæ¬ 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "çæææ (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "ç¡®å®", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "çæææ (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "äºä»¶æ¥çå¨" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "æ¥æº ( %s ) ä¸çäºä»¶ ID ( %lu ) çæè¿°æ æ³æ¾å°ãæ¬å°è®¡ç®æºå¯è½æ²¡ææ¾ç¤ºæ¥èªè¿ç¨è®¡ç®æºæ¶æ¯æå¿ éç注å表信æ¯ææ¶æ¯ DLL æ件ã\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "é误" IDS_EVENTLOG_WARNING_TYPE "è¦å" Modified: trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -29,17 +29,7 @@ BEGIN "?", IDM_ABOUT, ASCII, ALT "/", IDM_ABOUT, ASCII, ALT -END - -IDD_ABOUTBOX DIALOGEX 0, 0, 230, 75 -STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CENTER | WS_CAPTION | WS_SYSMENU -CAPTION "éæ¼" -FONT 9, "MS Shell Dlg", 0, 0, 0x0 -BEGIN - ICON IDI_EVENTVWR, IDC_MYICON, 14, 9, 21, 20 - LTEXT "ReactOS äºä»¶æª¢è¦å¨ çæ¬ 1.0", IDC_STATIC, 49, 10, 119, 8, SS_NOPREFIX - LTEXT "çæ¬ææ (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)", IDC_STATIC, 49, 20, 119, 22 - DEFPUSHBUTTON "確å®", IDOK, 90, 48, 42, 16, WS_GROUP + VK_F5, IDM_REFRESH, VIRTKEY END IDD_PROGRESSBOX DIALOGEX 0, 0, 230, 40 @@ -91,9 +81,12 @@ STRINGTABLE BEGIN + IDS_COPYRIGHT "çæ¬ææ (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "äºä»¶æª¢è¦å¨" IDS_APP_TITLE_EX "%s - %s Log on \\\\" IDS_STATUS_MSG "%s has %lu event(s)" + IDS_EVENTLOG_SYSTEM "System Logs" + IDS_EVENTLOG_USER "User Logs" IDS_EVENTSTRINGIDNOTFOUND "ä¾æº ( %s ) ä¸çäºä»¶ ID ( %lu ) çæè¿°ç¡æ³æ¾å°ã æ¬å°é»è ¦å¯è½æ²æ顯示ä¾èªé 端é»è ¦æ¶æ¯æå¿ éç註å表è³è¨ææ¶æ¯ DLL æªã\n\nThe following information is part of the event:\n\n" IDS_EVENTLOG_ERROR_TYPE "é¯èª¤" IDS_EVENTLOG_WARNING_TYPE "è¦å" Added: trunk/reactos/base/applications/mscutils/eventvwr/res/eventlog.ico URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== Binary file - no diff available. Propchange: trunk/reactos/base/applications/mscutils/eventvwr/res/eventlog.ico ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Modified: trunk/reactos/base/applications/mscutils/eventvwr/res/eventvwr.ico URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== Binary files - no diff available. Modified: trunk/reactos/base/applications/mscutils/eventvwr/res/folder.ico URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== Binary files - no diff available. Modified: trunk/reactos/base/applications/mscutils/eventvwr/res/folderopen.ico URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== Binary files - no diff available. Modified: trunk/reactos/base/applications/mscutils/eventvwr/resource.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
============================================================================== --- trunk/reactos/base/applications/mscutils/eventvwr/resource.h [iso-8859-1] (original) +++ trunk/reactos/base/applications/mscutils/eventvwr/resource.h [iso-8859-1] Wed Jul 6 23:14:56 2016 @@ -2,12 +2,15 @@ /* Icon IDs */ #define IDI_EVENTVWR 10 -#define IDI_WARNINGICON 11 -#define IDI_INFORMATIONICON 12 -#define IDI_ERRORICON 13 -#define IDI_NEXT 14 -#define IDI_PREV 15 -#define IDI_COPY 16 +#define IDI_EVENTLOG 11 +#define IDI_CLOSED_CATEGORY 12 +#define IDI_OPENED_CATEGORY 13 +#define IDI_WARNINGICON 14 +#define IDI_INFORMATIONICON 15 +#define IDI_ERRORICON 16 +#define IDI_NEXT 17 +#define IDI_PREV 18 +#define IDI_COPY 19 /* Accelerator IDs */ @@ -15,29 +18,27 @@ /* Dialog IDs */ -#define IDD_ABOUTBOX 101 -#define IDD_PROGRESSBOX 102 -#define IDD_EVENTPROPERTIES 103 +#define IDD_PROGRESSBOX 101 +#define IDD_EVENTPROPERTIES 102 -/* Control IDs*/ +/* Control IDs */ #define IDC_STATIC -1 -#define IDC_MYICON 1000 -#define IDC_EVENTDATESTATIC 1001 -#define IDC_EVENTSOURCESTATIC 1002 -#define IDC_EVENTTIMESTATIC 1003 -#define IDC_EVENTCATEGORYSTATIC 1004 -#define IDC_EVENTTYPESTATIC 1005 -#define IDC_EVENTIDSTATIC 1006 -#define IDC_EVENTUSERSTATIC 1007 -#define IDC_EVENTCOMPUTERSTATIC 1008 -#define IDC_PREVIOUS 1009 -#define IDC_NEXT 1010 -#define IDC_COPY 1011 -#define IDC_EVENTTEXTEDIT 1012 -#define IDC_BYTESRADIO 1013 -#define IDC_WORDRADIO 1014 -#define IDC_EVENTDATAEDIT 1015 +#define IDC_EVENTDATESTATIC 1000 +#define IDC_EVENTSOURCESTATIC 1001 +#define IDC_EVENTTIMESTATIC 1002 +#define IDC_EVENTCATEGORYSTATIC 1003 +#define IDC_EVENTTYPESTATIC 1004 +#define IDC_EVENTIDSTATIC 1005 +#define IDC_EVENTUSERSTATIC 1006 +#define IDC_EVENTCOMPUTERSTATIC 1007 +#define IDC_PREVIOUS 1008 +#define IDC_NEXT 1009 +#define IDC_COPY 1010 +#define IDC_EVENTTEXTEDIT 1011 +#define IDC_BYTESRADIO 1012 +#define IDC_WORDRADIO 1013 +#define IDC_EVENTDATAEDIT 1014 /* Menu IDs */ @@ -50,13 +51,14 @@ #define IDM_HELP 32777 #define IDM_ABOUT 32778 -#define ID_FIRST_LOG 45000 - /* String IDs */ +#define IDS_COPYRIGHT 102 #define IDS_APP_TITLE 103 #define IDS_APP_TITLE_EX 104 #define IDS_STATUS_MSG 106 +#define IDS_EVENTLOG_SYSTEM 107 +#define IDS_EVENTLOG_USER 108 #define IDS_EVENTSTRINGIDNOTFOUND 209 #define IDS_EVENTLOG_ERROR_TYPE 251 #define IDS_EVENTLOG_WARNING_TYPE 252
8 years, 5 months
1
0
0
0
[zhu] 71835: Mostly cleanup. Removed abusive use of cancel spin lock, thanks to David for pointing that out for me.
by zhu@svn.reactos.org
Author: zhu Date: Wed Jul 6 20:53:31 2016 New Revision: 71835 URL:
http://svn.reactos.org/svn/reactos?rev=71835&view=rev
Log: Mostly cleanup. Removed abusive use of cancel spin lock, thanks to David for pointing that out for me. Modified: branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/address.c branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/main.c Modified: branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/address.c URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2016/lwIP-tcpip/drivers/ne…
============================================================================== --- branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/address.c [iso-8859-1] (original) +++ branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/address.c [iso-8859-1] Wed Jul 6 20:53:31 2016 @@ -9,6 +9,8 @@ #define NDEBUG #include <debug.h> + +volatile long int PcbCount; typedef struct { @@ -22,6 +24,7 @@ /* The pool tags we will use for all of our allocation */ #define TAG_ADDRESS_FILE 'FrdA' +#define TAG_DGRAM_REQST 'DgRq' #define TAG_TCP_CONTEXT 'TCPx' #define TAG_TCP_REQUEST 'TCPr' @@ -42,10 +45,9 @@ PTCP_CONTEXT Context; PTCP_REQUEST Request; KIRQL OldIrql; + NTSTATUS Status; DPRINT1("Prepare for cancel\n"); - - IoAcquireCancelSpinLock(&OldIrql); if (!Irp->Cancel) { @@ -53,9 +55,8 @@ if (!Request) { DPRINT1("Allocation failed, out of memory\n"); - IoReleaseCancelSpinLock(OldIrql); - - return STATUS_NO_MEMORY; + Status = STATUS_NO_MEMORY; + goto RETURN; } IrpSp = IoGetCurrentIrpStackLocation(Irp); @@ -66,31 +67,28 @@ Request->CancelMode = CancelMode; Request->PendingMode = PendingMode; - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); + IoSetCancelRoutine(Irp, CancelRoutine); InsertTailList(&Context->RequestListHead, &Request->ListEntry); - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); - IoSetCancelRoutine(Irp, CancelRoutine); + Status = STATUS_SUCCESS; + DPRINT1("Prepared for cancel\n"); - IoReleaseCancelSpinLock(OldIrql); - - DPRINT1("Prepared for cancel\n"); - - return STATUS_SUCCESS; + goto RETURN; } DPRINT1("Already cancelled\n"); - - IoReleaseCancelSpinLock(OldIrql); Irp->IoStatus.Status = STATUS_CANCELLED; Irp->IoStatus.Information = 0; - return STATUS_CANCELLED; +RETURN: + return Status; } /* implementation in testing */ -/* Does not dequeue the request, simply marks it as cancelled */ +/* TODO: get rid of datagram support, or merge datagram stuff into here */ VOID NTAPI CancelRequestRoutine( @@ -123,10 +121,11 @@ } TCP_CANCEL: + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); + Irp->IoStatus.Status = STATUS_CANCELLED; Irp->IoStatus.Information = 0; - - KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); + IoSetCancelRoutine(Irp, NULL); AddressFile = Context->AddressFile; DPRINT1("AddressFile at %08x\n", AddressFile); @@ -145,6 +144,8 @@ AddressFile->lwip_tcp_pcb = NULL; } tcp_abort(Context->lwip_tcp_pcb); + InterlockedDecrement(&PcbCount); + DPRINT1("\n PCB Count: %d\n", PcbCount); Context->lwip_tcp_pcb = NULL; RemoveEntryList(Entry); @@ -162,6 +163,8 @@ AddressFile->lwip_tcp_pcb = NULL; } tcp_close(Context->lwip_tcp_pcb); + InterlockedDecrement(&PcbCount); + DPRINT1("\n PCB Count: %d\n", PcbCount); Context->lwip_tcp_pcb = NULL; RemoveEntryList(Entry); @@ -194,15 +197,9 @@ DPRINT1("DGRAM_CANCEL\n"); FINISH: - DPRINT1("\n Minor Function: %08x\n", IrpSp->MinorFunction); - - IoAcquireCancelSpinLock(&OldIrql); - IoSetCancelRoutine(Irp, NULL); - IoReleaseCancelSpinLock(OldIrql); - IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - DPRINT1("\n CancelRequestRoutine Exiting\n"); + DPRINT1("CancelRequestRoutine Exiting\n"); return; } @@ -212,6 +209,8 @@ { KeInitializeSpinLock(&AddressListLock); InitializeListHead(&AddressListHead); + + PcbCount = 0; } static @@ -238,7 +237,6 @@ PLIST_ENTRY Temp; PIRP Irp; KIRQL OldIrql; - KIRQL CancelIrql; NTSTATUS Status; @@ -293,10 +291,8 @@ { if (Irp->Cancel) { - IoAcquireCancelSpinLock(&CancelIrql); Irp->Cancel = FALSE; IoSetCancelRoutine(Irp, NULL); - IoReleaseCancelSpinLock(CancelIrql); } Irp->IoStatus.Status = Status; Irp->IoStatus.Information = 0; @@ -312,22 +308,24 @@ if (Context->lwip_tcp_pcb != AddressFile->lwip_tcp_pcb) { - tcp_close(Context->lwip_tcp_pcb); + tcp_abort(Context->lwip_tcp_pcb); + InterlockedDecrement(&PcbCount); + DPRINT1("\n PCB Count\n", PcbCount); } Context->lwip_tcp_pcb = NULL; Entry = Entry->Flink; } + AddressFile->lwip_tcp_pcb = NULL; + KeReleaseSpinLock(&AddressFile->ContextListLock, OldIrql); - - AddressFile->lwip_tcp_pcb = NULL; return; case TDI_CONNECTION_FILE : Context = (PTCP_CONTEXT)arg; DPRINT1("AddressFile at %08x\n", Context->AddressFile); - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); HeadNest = &Context->RequestListHead; EntryNest = HeadNest->Flink; @@ -339,10 +337,8 @@ { if (Irp->Cancel) { - IoAcquireCancelSpinLock(&CancelIrql); Irp->Cancel = FALSE; IoSetCancelRoutine(Irp, NULL); - IoReleaseCancelSpinLock(CancelIrql); } Irp->IoStatus.Status = Status; Irp->IoStatus.Information = 0; @@ -354,9 +350,10 @@ EntryNest = Temp; } - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); - if (Context->lwip_tcp_pcb == Context->AddressFile->lwip_tcp_pcb); + if (Context->AddressFile && + (Context->lwip_tcp_pcb == Context->AddressFile->lwip_tcp_pcb)) { Context->AddressFile->lwip_tcp_pcb = NULL; } @@ -388,8 +385,7 @@ DPRINT1("Receiving datagram for addr 0x%08x on port %u.\n", ip4_addr_get_u32(addr), port); /* Block any cancellation that could occur */ - IoAcquireCancelSpinLock(&OldIrql); - KeAcquireSpinLockAtDpcLevel(&AddressFile->RequestLock); + KeAcquireSpinLock(&AddressFile->RequestLock, &OldIrql); ListEntry = AddressFile->RequestListHead.Flink; while (ListEntry != &AddressFile->RequestListHead) @@ -415,8 +411,7 @@ RemoveEntryList(&Request->ListEntry); Result = TRUE; - KeReleaseSpinLockFromDpcLevel(&AddressFile->RequestLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&AddressFile->RequestLock, OldIrql); /* In case of UDP, lwip provides a pbuf directly pointing to the data. * In other case, we must skip the IP header */ @@ -439,16 +434,14 @@ Irp->IoStatus.Status = STATUS_SUCCESS; IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - ExFreePoolWithTag(Request, TAG_TCP_REQUEST); + ExFreePoolWithTag(Request, TAG_DGRAM_REQST); /* Start again from the beginning */ - IoAcquireCancelSpinLock(&OldIrql); - KeAcquireSpinLockAtDpcLevel(&AddressFile->RequestLock); + KeAcquireSpinLock(&AddressFile->RequestLock, &OldIrql); } } - KeReleaseSpinLockFromDpcLevel(&AddressFile->RequestLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&AddressFile->RequestLock, OldIrql); return Result; } @@ -488,9 +481,8 @@ DPRINT1("lwIP TCP Accept Callback\n"); - IoAcquireCancelSpinLock(&OldIrql); AddressFile = (PADDRESS_FILE)arg; - KeAcquireSpinLockAtDpcLevel(&AddressFile->ContextListLock); + KeAcquireSpinLock(&AddressFile->ContextListLock, &OldIrql); Head = &AddressFile->ContextListHead; Entry = Head->Flink; @@ -499,10 +491,12 @@ Context = CONTAINING_RECORD(Entry, TCP_CONTEXT, ListEntry); if (Context->TcpState == TCP_STATE_LISTENING) { - KeReleaseSpinLockFromDpcLevel(&AddressFile->ContextListLock); - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); + KeReleaseSpinLock(&AddressFile->ContextListLock, OldIrql); + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); Context->lwip_tcp_pcb = newpcb; + InterlockedIncrement(&PcbCount); + DPRINT1("\n PCB Count: %d\n", PcbCount); Context->TcpState = TCP_STATE_ACCEPTED; tcp_accepted(AddressFile->lwip_tcp_pcb); Head = &Context->RequestListHead; @@ -513,10 +507,11 @@ IrpSp = IoGetCurrentIrpStackLocation(Irp); if (!Irp || IrpSp->MinorFunction != TDI_LISTEN) { - DPRINT1("Received callback for canceld TDI_LISTEN\n"); + DPRINT1("Received accept callback for cancelled TDI_LISTEN\n"); RemoveEntryList(Entry); Entry = Entry->Flink; ExFreePoolWithTag(Request, TAG_TCP_REQUEST); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); return ERR_ABRT; } @@ -525,19 +520,17 @@ IoSetCancelRoutine(Irp, NULL); Irp->Cancel = FALSE; - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); Irp->IoStatus.Status = STATUS_SUCCESS; IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - return ERR_OK; } Entry = Entry->Flink; } - KeReleaseSpinLockFromDpcLevel(&AddressFile->ContextListLock); - IoReleaseCancelSpinLock(OldIrql); - + KeReleaseSpinLock(&AddressFile->ContextListLock, OldIrql); + DPRINT1("Did not find a valid TDI_LISTEN\n"); return ERR_ABRT; } @@ -568,8 +561,7 @@ DPRINT1("lwIP TCP Sent Callback\n"); Context = (PTCP_CONTEXT)arg; - IoAcquireCancelSpinLock(&OldIrql); - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); Head = &Context->RequestListHead; Entry = Head->Flink; @@ -584,18 +576,18 @@ } Entry = Entry->Flink; } + DPRINT1("Matching TDI_SEND request not found\n"); - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); return ERR_ABRT; + FOUND: if (!Irp) { DPRINT1("Callback on cancelled IRP\n"); RemoveEntryList(&Request->ListEntry); ExFreePoolWithTag(Request, TAG_TCP_REQUEST); - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); return ERR_ABRT; } @@ -630,13 +622,17 @@ IrpSp = IoGetCurrentIrpStackLocation(Irp); RequestInfo = (PTDI_REQUEST_KERNEL_SEND)&IrpSp->Parameters; lwip_err = tcp_write(Context->lwip_tcp_pcb, Buffer, RequestInfo->SendLength, 0); + PrepareIrpForCancel( + Irp, + CancelRequestRoutine, + TCP_REQUEST_CANCEL_MODE_PRESERVE, + TCP_REQUEST_PENDING_SEND); break; } Entry = Entry->Flink; } - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); @@ -657,8 +653,6 @@ PNDIS_BUFFER Buffer; PTCP_CONTEXT Context; PTCP_REQUEST Request; - PIO_STACK_LOCATION IrpSp; - PTDI_REQUEST_KERNEL_RECEIVE ReceiveInfo; KIRQL OldIrql; INT CopiedLength; @@ -669,172 +663,122 @@ PLIST_ENTRY Head; PLIST_ENTRY Entry; NTSTATUS Status; + err_t lwip_err; DPRINT1("lwIP TCP Receive Callback\n"); - if (err != ERR_OK) + /* This error is currently unimplemented in lwIP */ +/* if (err != ERR_OK) { DPRINT1("lwIP Error %d\n", err); return ERR_ABRT; - } - - IoAcquireCancelSpinLock(&OldIrql); + }*/ Context = (PTCP_CONTEXT)arg; DPRINT1("Context at %08x\n", Context); DPRINT1("AddressFile at %08x\n", Context->AddressFile); - if (!(Context->TcpState & TCP_STATE_RECEIVING)) - { + if (!(Context->TcpState & TCP_STATE_RECEIVING)) { DPRINT1("Receive callback on connection that is not currently receiving\n"); - IoReleaseCancelSpinLock(OldIrql); return ERR_ARG; } - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); Head = &Context->RequestListHead; Entry = Head->Flink; Irp = NULL; - while (Entry != Head) - { + DPRINT1("Entering Loop\n"); + while (Entry != Head) { + DPRINT1("Fetching Request\n"); Request = CONTAINING_RECORD(Entry, TCP_REQUEST, ListEntry); - if (!Request->PendingIrp) - { + DPRINT1("Request Fetched. Points to %08x\n", Request); + if (!Request->PendingIrp) { + DPRINT1("IRP pointer dereferenced\n"); RemoveEntryList(Entry); + DPRINT1("Entry removed\n"); Entry = Entry->Flink; ExFreePoolWithTag(Request, TAG_TCP_REQUEST); continue; } - if (Request->PendingMode == TCP_REQUEST_PENDING_RECEIVE) - { + if (Request->PendingMode == TCP_REQUEST_PENDING_RECEIVE) { Irp = Request->PendingIrp; Entry = Entry->Flink; break; } Entry = Entry->Flink; } - if (!Irp) - { + if (!Irp) { DPRINT1("Receive callback on cancelled IRP\n"); - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); return ERR_ABRT; } + + /* IRP found, clear out the CANCEL flag */ DPRINT1("IRP at %08x\n", Irp); - - IrpSp = IoGetCurrentIrpStackLocation(Irp); - DPRINT1("IrpSp: %08x\n", IrpSp); - IoSetCancelRoutine(Irp, NULL); Irp->Cancel = FALSE; - if (Context->lwip_tcp_pcb != tpcb) - { + if (Context->lwip_tcp_pcb != tpcb) { DPRINT1("Receive tcp_pcb mismatch\n"); tcp_abort(tpcb); + InterlockedDecrement(&PcbCount); + DPRINT1("\n PCB Count\n", PcbCount); - RemoveEntryList(&Request->ListEntry); - ExFreePoolWithTag(Request, TAG_TCP_REQUEST); - - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); - - Irp->IoStatus.Status = STATUS_UNSUCCESSFUL; - Irp->IoStatus.Information = 0; - IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - - return ERR_ABRT; - } - if (!(Context->TcpState & (TCP_STATE_RECEIVING|TCP_STATE_ACCEPTED|TCP_STATE_CONNECTED))) - { + // TODO: better return code + Status = STATUS_UNSUCCESSFUL; + CopiedLength = 0; + lwip_err = ERR_ABRT; + goto BAD; + } + if (!(Context->TcpState & (TCP_STATE_RECEIVING|TCP_STATE_ACCEPTED|TCP_STATE_CONNECTED))) { DPRINT1("Invalid TCP state: %08x\n", Context->TcpState); - - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); - - return ERR_ABRT; + // TODO: better return code + Status = STATUS_UNSUCCESSFUL; + lwip_err = ERR_ABRT; + goto BAD; } Buffer = (PNDIS_BUFFER)Irp->MdlAddress; - ReceiveInfo = (PTDI_REQUEST_KERNEL_RECEIVE)&IrpSp->Parameters; - - DPRINT1("NDIS Buffer: %08x\n", Buffer); - - if (Buffer->MdlFlags & (MDL_MAPPED_TO_SYSTEM_VA|MDL_SOURCE_IS_NONPAGED_POOL)) - { - DPRINT1("Option 0\n"); - CurrentDestLocation = Buffer->MappedSystemVa; - } - else - { - DPRINT1("Option 1\n"); - CurrentDestLocation = MmMapLockedPages(Buffer, KernelMode); - } -// CurrentDestLocation = MmGetSystemAddressForMdl(Buffer); - RemainingDestBytes = Buffer->ByteCount; -// NdisQueryBuffer(Buffer, &CurrentDestLocation, &RemainingDestBytes); - - if (p) - { - DPRINT1("\n PTDI_REQUEST_KERNEL_RECEIVE->ReceiveLength = %d\n NDIS_BUFFER length = %d\n pbuf->tot_len = %d\n", - ReceiveInfo->ReceiveLength, - RemainingDestBytes, - p->tot_len); - } - else - { - DPRINT1("\n The pbuf pointer p is NULL\n"); - } - - if (!p) - { + + NdisQueryBuffer(Buffer, &CurrentDestLocation, &RemainingDestBytes); + + if (!p) { + /* I believe this means the pcb was closed */ + DPRINT1("NULL pbuf pointer\n"); CopiedLength = 0; Status = STATUS_ADDRESS_CLOSED; goto BAD; } - if (RemainingDestBytes <= p->len) - { + if (RemainingDestBytes <= p->len) { RtlCopyMemory(CurrentDestLocation, p->payload, RemainingDestBytes); CopiedLength = RemainingDestBytes; Status = STATUS_SUCCESS; goto RETURN; - } - else - { + } else { CopiedLength = 0; RemainingSrceBytes = p->len; CurrentSrceLocation = p->payload; - while (1) - { - if (RemainingSrceBytes < RemainingDestBytes) - { + while (1) { + if (RemainingSrceBytes < RemainingDestBytes) { RtlCopyMemory(CurrentDestLocation, CurrentSrceLocation, RemainingSrceBytes); CopiedLength += p->len; RemainingDestBytes -= p->len; CurrentDestLocation += p->len; - if (p->next) - { + if (p->next) { RemainingSrceBytes = p->next->len; CurrentSrceLocation = p->next->payload; - pbuf_free(p); p = p->next; - continue; - } - else - { + } else { Status = STATUS_SUCCESS; goto RETURN; } - } - else - { + } else { RtlCopyMemory(CurrentDestLocation, CurrentSrceLocation, RemainingDestBytes); CopiedLength += RemainingDestBytes; - Status = STATUS_SUCCESS; goto RETURN; } @@ -845,29 +789,26 @@ DPRINT1("Receive CopiedLength = %d\n", CopiedLength); tcp_recved(tpcb, CopiedLength); - - while (Entry != Head) - { + while (Entry != Head) { Request = CONTAINING_RECORD(Entry, TCP_REQUEST, ListEntry); - if (Request->PendingMode == TCP_REQUEST_PENDING_RECEIVE) - { + if (Request->PendingMode == TCP_REQUEST_PENDING_RECEIVE) { tcp_recv(tpcb, lwip_tcp_receive_callback); break; } } + lwip_err = ERR_OK; BAD: RemoveEntryList(&Request->ListEntry); ExFreePoolWithTag(Request, TAG_TCP_REQUEST); - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); Irp->IoStatus.Status = Status; Irp->IoStatus.Information = CopiedLength; IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - return ERR_OK; + return lwip_err; } static @@ -929,17 +870,18 @@ KIRQL OldIrql; PLIST_ENTRY Head; PLIST_ENTRY Entry; + err_t lwip_err; DPRINT1("lwIP TCP Connected Callback\n"); - IoAcquireCancelSpinLock(&OldIrql); - Context = (PTCP_CONTEXT)arg; + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); Head = &Context->RequestListHead; Entry = Head->Flink; if (Head == Entry) { DPRINT1("Request list is empty\n"); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); return ERR_ARG; } Request = CONTAINING_RECORD(Entry, TCP_REQUEST, ListEntry); @@ -947,45 +889,37 @@ if (!Irp) { DPRINT1("Callback on cancelled IRP\n"); - - KeAcquireSpinLockAtDpcLevel(&Request->Context->RequestListLock); RemoveEntryList(&Request->ListEntry); ExFreePoolWithTag(Request, TAG_TCP_REQUEST); - KeReleaseSpinLockFromDpcLevel(&Request->Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Request->Context->RequestListLock, OldIrql); return ERR_ABRT; } - - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); - - if (Context->TcpState != TCP_STATE_CONNECTING) - { - DPRINT1("Invalid TCP state: %d\n", Context->TcpState); - - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); - - return ERR_ABRT; - } - - Context->TcpState = TCP_STATE_CONNECTED; - IoSetCancelRoutine(Irp, NULL); Irp->Cancel = FALSE; + if (Context->TcpState != TCP_STATE_CONNECTING) + { + DPRINT1("Invalid TCP state: %d\n", Context->TcpState); + lwip_err = ERR_ABRT; + goto FINISH; + } + + Context->TcpState = TCP_STATE_CONNECTED; + lwip_err = ERR_OK; + +FINISH: RemoveEntryList(&Request->ListEntry); ExFreePoolWithTag(Request, TAG_TCP_REQUEST); - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - IoReleaseCancelSpinLock(OldIrql); + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); Irp->IoStatus.Status = STATUS_SUCCESS; IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - return ERR_OK; + return lwip_err; } /* implementation in testing */ @@ -1006,6 +940,8 @@ /* See if this port is already taken, and find a free one if needed. */ KeAcquireSpinLock(&AddressListLock, &OldIrql); + DPRINT1("Search through used ports\n"); + ListEntry = AddressListHead.Flink; while (ListEntry != &AddressListHead) { @@ -1046,6 +982,8 @@ ListEntry = ListEntry->Flink; } + DPRINT1("Find local interface for address\n"); + if (!AddrIsUnspecified(Address)) { /* Find the local interface for this address */ @@ -1071,6 +1009,8 @@ } } + DPRINT1("Allocate address file\n"); + /* Allocate our new address file */ AddressFile = ExAllocatePoolWithTag(NonPagedPool, sizeof(*AddressFile), TAG_ADDRESS_FILE); if (!AddressFile) @@ -1091,6 +1031,8 @@ KeInitializeSpinLock(&AddressFile->RequestLock); InitializeListHead(&AddressFile->RequestListHead); + DPRINT1("Protocol-dependent operations\n"); + /* Give it an entity ID and open a PCB if needed. */ switch (Protocol) { @@ -1101,6 +1043,8 @@ InsertEntityInstance(CO_TL_ENTITY, &AddressFile->Instance); AddressFile->ContextCount = 0; AddressFile->lwip_tcp_pcb = tcp_new(); + InterlockedIncrement(&PcbCount); + DPRINT1("\n PCB Count: %d\n", PcbCount); tcp_arg(AddressFile->lwip_tcp_pcb, AddressFile); tcp_err(AddressFile->lwip_tcp_pcb, lwip_tcp_err_callback); break; @@ -1140,6 +1084,8 @@ } } + DPRINT1("Insert into address list\n"); + /* Insert it into the list. */ InsertTailList(&AddressListHead, &AddressFile->ListEntry); KeReleaseSpinLock(&AddressListLock, OldIrql); @@ -1225,7 +1171,17 @@ } if (AddressFile->lwip_tcp_pcb) { - lwip_err = tcp_close(AddressFile->lwip_tcp_pcb); + if (AddressFile->lwip_tcp_pcb->state == LISTEN) + { + lwip_err = tcp_close(AddressFile->lwip_tcp_pcb); + } + else + { + tcp_abort(AddressFile->lwip_tcp_pcb); + lwip_err = ERR_OK; + } + InterlockedDecrement(&PcbCount); + DPRINT1("\n PCB Count: %d\n", PcbCount); if (lwip_err != ERR_OK) { DPRINT1("lwIP tcp_close error: %d", lwip_err); @@ -1283,7 +1239,17 @@ if (Context->lwip_tcp_pcb) { - lwip_err = tcp_close(Context->lwip_tcp_pcb); + if (Context->TcpState == TCP_STATE_LISTENING) + { + lwip_err = tcp_close(Context->lwip_tcp_pcb); + } + else + { + tcp_abort(Context->lwip_tcp_pcb); + lwip_err = ERR_OK; + } + InterlockedDecrement(&PcbCount); + DPRINT1("\n PCB Count: %d\n", PcbCount); if (lwip_err != ERR_OK) { DPRINT1("lwIP tcp_close error: %d", lwip_err); @@ -1384,14 +1350,15 @@ NT_ASSERT(ListEntry != &AddressFile->RequestListHead); RemoveEntryList(&Request->ListEntry); - KeReleaseSpinLock(&AddressFile->RequestLock, OldIrql); Irp->IoStatus.Status = STATUS_CANCELLED; Irp->IoStatus.Information = 0; + + KeReleaseSpinLock(&AddressFile->RequestLock, OldIrql); IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); - ExFreePoolWithTag(Request, TAG_TCP_REQUEST); + ExFreePoolWithTag(Request, TAG_DGRAM_REQST); } /* implementation in testing */ @@ -1625,14 +1592,13 @@ default : { DPRINT1("lwIP unexpected error\n"); - Status = STATUS_NOT_IMPLEMENTED; + // TODO: better return code + Status = STATUS_UNSUCCESSFUL; goto LEAVE; } } } } - - DPRINT1("TcpIpAssociateAddress Exiting\n"); Context->TcpState = TCP_STATE_BOUND; @@ -1679,14 +1645,12 @@ return STATUS_INVALID_ADDRESS; } - KeAcquireSpinLock(&AddressFile->ContextListLock, &OldIrql); - if (AddressFile->lwip_tcp_pcb == Context->lwip_tcp_pcb) { Context->lwip_tcp_pcb = NULL; } - KeAcquireSpinLockAtDpcLevel(&Context->RequestListLock); + KeAcquireSpinLock(&Context->RequestListLock, &OldIrql); if (!(IsListEmpty(&Context->RequestListHead))) { DPRINT1("Disassociating context with outstanding requests\n"); @@ -1706,12 +1670,12 @@ } } } - KeReleaseSpinLockFromDpcLevel(&Context->RequestListLock); - + KeReleaseSpinLock(&Context->RequestListLock, OldIrql); + + KeAcquireSpinLock(&AddressFile->ContextListLock, &OldIrql); RemoveEntryList(&Context->ListEntry); AddressFile->ContextCount--; Context->AddressFile = NULL; - KeReleaseSpinLock(&AddressFile->ContextListLock, OldIrql); if (AddressFile->ContextCount == 0) @@ -1766,6 +1730,7 @@ either INVALID_ADDRESS or NO_MEMORY if SO_REUSE is enabled in lwip options */ DPRINT1("lwip tcp_listen error\n"); + KeReleaseSpinLock(&AddressFile->ContextListLock, OldIrql); return STATUS_INVALID_ADDRESS; } tcp_arg(lpcb, AddressFile); @@ -1945,7 +1910,6 @@ RECEIVE_DATAGRAM_REQUEST* Request = NULL; PTDI_REQUEST_KERNEL_RECEIVEDG RequestInfo; NTSTATUS Status; - KIRQL OldIrql; /* Check this is really an address file */ if ((ULONG_PTR)IrpSp->FileObject->FsContext2 != TDI_TRANSPORT_ADDRESS_FILE) @@ -1966,7 +1930,7 @@ } /* Queue the request */ - Request = ExAllocatePoolWithTag(NonPagedPool, sizeof(*Request), TAG_TCP_REQUEST); + Request = ExAllocatePoolWithTag(NonPagedPool, sizeof(*Request), TAG_DGRAM_REQST); if (!Request) { Status = STATUS_INSUFFICIENT_RESOURCES; @@ -1997,14 +1961,10 @@ Request->ReturnInfo = RequestInfo->ReturnDatagramInformation; - /* Prepare for potential cancellation */ - IoAcquireCancelSpinLock(&OldIrql); - IoSetCancelRoutine(Irp, CancelReceiveDatagram); - IoReleaseCancelSpinLock(OldIrql); - /* Mark pending */ Irp->IoStatus.Status = STATUS_PENDING; IoMarkIrpPending(Irp); + IoSetCancelRoutine(Irp, CancelReceiveDatagram); /* We're ready to go */ ExInterlockedInsertTailList( @@ -2016,7 +1976,7 @@ Failure: if (Request) - ExFreePoolWithTag(Request, TAG_TCP_REQUEST); + ExFreePoolWithTag(Request, TAG_DGRAM_REQST); Irp->IoStatus.Status = Status; IoCompleteRequest(Irp, IO_NETWORK_INCREMENT); return Status; Modified: branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/main.c URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2016/lwIP-tcpip/drivers/ne…
============================================================================== --- branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/main.c [iso-8859-1] (original) +++ branches/GSoC_2016/lwIP-tcpip/drivers/network/tcpip/main.c [iso-8859-1] Wed Jul 6 20:53:31 2016 @@ -269,7 +269,9 @@ DPRINT1("\nPTA_IP_ADDRESS dump before\n %08x %08x %08x %08x\n %08x %08x %08x %08x\n", temp[7], temp[6], temp[5], temp[4], temp[3], temp[2], temp[1], temp[0]);*/ + DPRINT1("Call into TcpIpCreateAddress\n"); Status = TcpIpCreateAddress(Irp, &Address->Address[0].Address[0], Protocol); + DPRINT1("Returned from TcpIpCreateAddress\n"); if (Status != STATUS_SUCCESS) { goto Quickie;
8 years, 5 months
1
0
0
0
[mjansen] 71834: [SHELL32] Disable Paste menu items when no items are in the clipboard. Patch by Jared Smudde. CORE-11492 #resolve #comment Thanks!
by mjansen@svn.reactos.org
Author: mjansen Date: Wed Jul 6 19:30:59 2016 New Revision: 71834 URL:
http://svn.reactos.org/svn/reactos?rev=71834&view=rev
Log: [SHELL32] Disable Paste menu items when no items are in the clipboard. Patch by Jared Smudde. CORE-11492 #resolve #comment Thanks! Modified: trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp Modified: trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/CDefault…
============================================================================== --- trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp [iso-8859-1] (original) +++ trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp [iso-8859-1] Wed Jul 6 19:30:59 2016 @@ -366,8 +366,8 @@ mii.fMask = MIIM_STATE; mii.fState = MFS_DISABLED; - TRACE("result %d\n", SetMenuItemInfoW(hMenu, FCIDM_SHVIEW_INSERT, FALSE, &mii)); - TRACE("result %d\n", SetMenuItemInfoW(hMenu, FCIDM_SHVIEW_INSERTLINK, FALSE, &mii)); + SetMenuItemInfoW(hMenu, FCIDM_SHVIEW_INSERT, FALSE, &mii); + SetMenuItemInfoW(hMenu, FCIDM_SHVIEW_INSERTLINK, FALSE, &mii); } BOOL
8 years, 5 months
1
0
0
0
[tfaber] 71833: [XDK] - Define DRIVER_DISPATCH_PAGED and DRIVER_DISPATCH_RAISED
by tfaber@svn.reactos.org
Author: tfaber Date: Wed Jul 6 10:52:08 2016 New Revision: 71833 URL:
http://svn.reactos.org/svn/reactos?rev=71833&view=rev
Log: [XDK] - Define DRIVER_DISPATCH_PAGED and DRIVER_DISPATCH_RAISED Modified: trunk/reactos/sdk/include/xdk/iotypes.h Modified: trunk/reactos/sdk/include/xdk/iotypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/include/xdk/iotypes.h?…
============================================================================== --- trunk/reactos/sdk/include/xdk/iotypes.h [iso-8859-1] (original) +++ trunk/reactos/sdk/include/xdk/iotypes.h [iso-8859-1] Wed Jul 6 10:52:08 2016 @@ -2209,13 +2209,23 @@ typedef DRIVER_UNLOAD *PDRIVER_UNLOAD; _Function_class_(DRIVER_DISPATCH) -_IRQL_requires_(PASSIVE_LEVEL) +_IRQL_requires_max_(DISPATCH_LEVEL) _IRQL_requires_same_ typedef NTSTATUS (NTAPI DRIVER_DISPATCH)( _In_ struct _DEVICE_OBJECT *DeviceObject, _Inout_ struct _IRP *Irp); typedef DRIVER_DISPATCH *PDRIVER_DISPATCH; +typedef DRIVER_DISPATCH DRIVER_DISPATCH_RAISED; + +_Function_class_(DRIVER_DISPATCH) +_IRQL_requires_(PASSIVE_LEVEL) +_IRQL_requires_same_ +typedef NTSTATUS +(NTAPI DRIVER_DISPATCH_PAGED)( + _In_ struct _DEVICE_OBJECT *DeviceObject, + _Inout_ struct _IRP *Irp); +typedef DRIVER_DISPATCH_PAGED *PDRIVER_DISPATCH_PAGED; typedef struct _DRIVER_OBJECT { CSHORT Type;
8 years, 5 months
1
0
0
0
[tthompson] 71832: [NTFS] Fix copy-paste error in SetAttributeDataLength()
by tthompson@svn.reactos.org
Author: tthompson Date: Wed Jul 6 07:57:57 2016 New Revision: 71832 URL:
http://svn.reactos.org/svn/reactos?rev=71832&view=rev
Log: [NTFS] Fix copy-paste error in SetAttributeDataLength() Modified: branches/GSoC_2016/NTFS/drivers/filesystems/ntfs/mft.c Modified: branches/GSoC_2016/NTFS/drivers/filesystems/ntfs/mft.c URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2016/NTFS/drivers/filesyst…
============================================================================== --- branches/GSoC_2016/NTFS/drivers/filesystems/ntfs/mft.c [iso-8859-1] (original) +++ branches/GSoC_2016/NTFS/drivers/filesystems/ntfs/mft.c [iso-8859-1] Wed Jul 6 07:57:57 2016 @@ -228,9 +228,9 @@ NTSTATUS Status = STATUS_SUCCESS; // are we truncating the file? - if (DataSize->QuadPart < AttributeDataLength(&AttrContext->Record) - { - if (!MmCanFileBeTruncated(FileObject->SectionObjectPointer, (PLARGE_INTEGER)&AllocationSize)) + if (DataSize->QuadPart < AttributeDataLength(&AttrContext->Record)) + { + if (!MmCanFileBeTruncated(FileObject->SectionObjectPointer, DataSize)) { DPRINT1("Can't truncate a memory-mapped file!\n"); return STATUS_USER_MAPPED_FILE;
8 years, 5 months
1
0
0
0
[cwittich] 71831: [GDI32] reduce diff to wine (metafile)
by cwittich@svn.reactos.org
Author: cwittich Date: Wed Jul 6 06:20:36 2016 New Revision: 71831 URL:
http://svn.reactos.org/svn/reactos?rev=71831&view=rev
Log: [GDI32] reduce diff to wine (metafile) Modified: trunk/reactos/win32ss/gdi/gdi32/wine/enhmetafile.c trunk/reactos/win32ss/gdi/gdi32/wine/gdi_private.h trunk/reactos/win32ss/gdi/gdi32/wine/metafile.c trunk/reactos/win32ss/reactx/ntddraw/ddraw.c Modified: trunk/reactos/win32ss/gdi/gdi32/wine/enhmetafile.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/gdi/gdi32/wine/enh…
============================================================================== --- trunk/reactos/win32ss/gdi/gdi32/wine/enhmetafile.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/gdi/gdi32/wine/enhmetafile.c [iso-8859-1] Wed Jul 6 06:20:36 2016 @@ -2182,20 +2182,20 @@ case EMR_POLYDRAW16: case EMR_GLSRECORD: case EMR_GLSBOUNDEDRECORD: - case EMR_DRAWESCAPE : - case EMR_EXTESCAPE: - case EMR_STARTDOC: - case EMR_SMALLTEXTOUT: - case EMR_FORCEUFIMAPPING: - case EMR_NAMEDESCAPE: - case EMR_COLORCORRECTPALETTE: - case EMR_SETICMPROFILEA: - case EMR_SETICMPROFILEW: - case EMR_TRANSPARENTBLT: - case EMR_GRADIENTFILL: - case EMR_SETLINKEDUFI: - case EMR_COLORMATCHTOTARGETW: - case EMR_CREATECOLORSPACEW: + case EMR_DRAWESCAPE: + case EMR_EXTESCAPE: + case EMR_STARTDOC: + case EMR_SMALLTEXTOUT: + case EMR_FORCEUFIMAPPING: + case EMR_NAMEDESCAPE: + case EMR_COLORCORRECTPALETTE: + case EMR_SETICMPROFILEA: + case EMR_SETICMPROFILEW: + case EMR_TRANSPARENTBLT: + case EMR_GRADIENTFILL: + case EMR_SETLINKEDUFI: + case EMR_COLORMATCHTOTARGETW: + case EMR_CREATECOLORSPACEW: default: /* From docs: If PlayEnhMetaFileRecord doesn't recognize a @@ -2679,7 +2679,60 @@ return infoForCallBack.cEntries; } -typedef struct gdi_mf_comment +/****************************************************************** + * extract_emf_from_comment + * + * If the WMF was created by GetWinMetaFileBits, then extract the + * original EMF that is stored in MFCOMMENT chunks. + */ +static HENHMETAFILE extract_emf_from_comment( const BYTE *buf, UINT mf_size ) +{ + METAHEADER *mh = (METAHEADER *)buf; + METARECORD *mr; + emf_in_wmf_comment *chunk; + WORD checksum = 0; + DWORD size = 0, remaining, chunks; + BYTE *emf_bits = NULL, *ptr; + UINT offset; + HENHMETAFILE emf = NULL; + + if (mf_size < sizeof(*mh)) return NULL; + + for (offset = mh->mtHeaderSize * 2; offset < mf_size; offset += (mr->rdSize * 2)) + { + mr = (METARECORD *)((char *)mh + offset); + chunk = (emf_in_wmf_comment *)(mr->rdParm + 2); + + if (mr->rdFunction != META_ESCAPE || mr->rdParm[0] != MFCOMMENT) goto done; + if (chunk->magic != WMFC_MAGIC) goto done; + + if (!emf_bits) + { + size = remaining = chunk->emf_size; + chunks = chunk->num_chunks; + emf_bits = ptr = HeapAlloc( GetProcessHeap(), 0, size ); + if (!emf_bits) goto done; + } + if (chunk->chunk_size > remaining) goto done; + remaining -= chunk->chunk_size; + if (chunk->remaining_size != remaining) goto done; + memcpy( ptr, chunk->emf_data, chunk->chunk_size ); + ptr += chunk->chunk_size; + if (--chunks == 0) break; + } + + for (offset = 0; offset < mf_size / 2; offset++) + checksum += *((WORD *)buf + offset); + if (checksum) goto done; + + emf = SetEnhMetaFileBits( size, emf_bits ); + +done: + HeapFree( GetProcessHeap(), 0, emf_bits ); + return emf; +} + +typedef struct wmf_in_emf_comment { DWORD ident; DWORD iComment; @@ -2687,7 +2740,7 @@ DWORD nChecksum; DWORD fFlags; DWORD cbWinMetaFile; -} gdi_mf_comment; +} wmf_in_emf_comment; /****************************************************************** * SetWinMetaFileBits (GDI32.@) @@ -2714,6 +2767,9 @@ WARN("SetMetaFileBitsEx failed\n"); return NULL; } + + ret = extract_emf_from_comment( lpbBuffer, cbBuffer ); + if (ret) return ret; if(!hdcRef) hdcRef = hdcdisp = CreateDCW(szDisplayW, NULL, NULL, NULL); @@ -2767,10 +2823,10 @@ */ if (mm != MM_TEXT) { - gdi_mf_comment *mfcomment; + wmf_in_emf_comment *mfcomment; UINT mfcomment_size; - mfcomment_size = sizeof (gdi_mf_comment) + cbBuffer; + mfcomment_size = sizeof (*mfcomment) + cbBuffer; mfcomment = HeapAlloc(GetProcessHeap(), 0, mfcomment_size); if (mfcomment) { Modified: trunk/reactos/win32ss/gdi/gdi32/wine/gdi_private.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/gdi/gdi32/wine/gdi…
============================================================================== --- trunk/reactos/win32ss/gdi/gdi32/wine/gdi_private.h [iso-8859-1] (original) +++ trunk/reactos/win32ss/gdi/gdi32/wine/gdi_private.h [iso-8859-1] Wed Jul 6 06:20:36 2016 @@ -93,6 +93,26 @@ extern HMETAFILE MF_Create_HMETAFILE(METAHEADER *mh) DECLSPEC_HIDDEN; extern METAHEADER *MF_CreateMetaHeaderDisk(METAHEADER *mr, LPCVOID filename, BOOL unicode ) DECLSPEC_HIDDEN; +/* Format of comment record added by GetWinMetaFileBits */ +#include <pshpack2.h> +typedef struct +{ + DWORD magic; /* WMFC */ + WORD unk04; /* 1 */ + WORD unk06; /* 0 */ + WORD unk08; /* 0 */ + WORD unk0a; /* 1 */ + WORD checksum; + DWORD unk0e; /* 0 */ + DWORD num_chunks; + DWORD chunk_size; + DWORD remaining_size; + DWORD emf_size; + BYTE emf_data[1]; +} emf_in_wmf_comment; +#include <poppack.h> + +#define WMFC_MAGIC 0x43464d57 /* palette.c */ extern HPALETTE WINAPI GDISelectPalette( HDC hdc, HPALETTE hpal, WORD wBkg) DECLSPEC_HIDDEN; extern UINT WINAPI GDIRealizePalette( HDC hdc ) DECLSPEC_HIDDEN; Modified: trunk/reactos/win32ss/gdi/gdi32/wine/metafile.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/gdi/gdi32/wine/met…
============================================================================== --- trunk/reactos/win32ss/gdi/gdi32/wine/metafile.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/gdi/gdi32/wine/metafile.c [iso-8859-1] Wed Jul 6 06:20:36 2016 @@ -1115,26 +1115,6 @@ return mfSize; } -#include <pshpack2.h> -typedef struct -{ - DWORD magic; /* WMFC */ - WORD unk04; /* 1 */ - WORD unk06; /* 0 */ - WORD unk08; /* 0 */ - WORD unk0a; /* 1 */ - WORD checksum; - DWORD unk0e; /* 0 */ - DWORD num_chunks; - DWORD chunk_size; - DWORD remaining_size; - DWORD emf_size; - BYTE *emf_data; -} mf_comment_chunk; -#include <poppack.h> - -static const DWORD wmfc_magic = 0x43464d57; - /****************************************************************** * add_mf_comment * @@ -1147,7 +1127,7 @@ { DWORD size = GetEnhMetaFileBits(emf, 0, NULL), i; BYTE *bits, *chunk_data; - mf_comment_chunk *chunk = NULL; + emf_in_wmf_comment *chunk = NULL; BOOL ret = FALSE; static const DWORD max_chunk_size = 0x2000; @@ -1156,10 +1136,10 @@ if(!bits) return FALSE; if(!GetEnhMetaFileBits(emf, size, bits)) goto end; - chunk = HeapAlloc(GetProcessHeap(), 0, max_chunk_size + FIELD_OFFSET(mf_comment_chunk, emf_data)); + chunk = HeapAlloc(GetProcessHeap(), 0, FIELD_OFFSET(emf_in_wmf_comment, emf_data[max_chunk_size])); if(!chunk) goto end; - chunk->magic = wmfc_magic; + chunk->magic = WMFC_MAGIC; chunk->unk04 = 1; chunk->unk06 = 0; chunk->unk08 = 0; @@ -1177,10 +1157,10 @@ chunk->chunk_size = chunk->remaining_size; chunk->remaining_size -= chunk->chunk_size; - memcpy(&chunk->emf_data, chunk_data, chunk->chunk_size); + memcpy(chunk->emf_data, chunk_data, chunk->chunk_size); chunk_data += chunk->chunk_size; - if(!Escape(hdc, MFCOMMENT, chunk->chunk_size + FIELD_OFFSET(mf_comment_chunk, emf_data), (char*)chunk, NULL)) + if(!Escape(hdc, MFCOMMENT, FIELD_OFFSET(emf_in_wmf_comment, emf_data[chunk->chunk_size]), (char*)chunk, NULL)) goto end; } ret = TRUE; Modified: trunk/reactos/win32ss/reactx/ntddraw/ddraw.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/reactx/ntddraw/ddr…
============================================================================== --- trunk/reactos/win32ss/reactx/ntddraw/ddraw.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/reactx/ntddraw/ddraw.c [iso-8859-1] Wed Jul 6 06:20:36 2016 @@ -65,7 +65,7 @@ if ( ( pDev->DriverFunctions.DisableDirectDraw == NULL) || ( pDev->DriverFunctions.EnableDirectDraw == NULL)) { - DPRINT1("Waring : DisableDirectDraw and EnableDirectDraw are NULL, no dx driver \n"); + DPRINT1("Warning : DisableDirectDraw and EnableDirectDraw are NULL, no dx driver \n"); } else {
8 years, 5 months
1
0
0
0
[aandrejevic] 71830: [NTVDM] Implement an 800x600 256-color mode for testing purposes. Its register values and mode information should be correct already. Properly reset the VCLKs and the MCLK. Cle...
by aandrejevic@svn.reactos.org
Author: aandrejevic Date: Wed Jul 6 04:26:16 2016 New Revision: 71830 URL:
http://svn.reactos.org/svn/reactos?rev=71830&view=rev
Log: [NTVDM] Implement an 800x600 256-color mode for testing purposes. Its register values and mode information should be correct already. Properly reset the VCLKs and the MCLK. Clear the screen after switching to an extended video mode. Fix the screen size computation in "High Resolution" modes. Modified: trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.c trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.h trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/svga.c Modified: trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/ntvdm/bios…
============================================================================== --- trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.c [iso-8859-1] Wed Jul 6 04:26:16 2016 @@ -24,32 +24,114 @@ /* PRIVATE VARIABLES **********************************************************/ -static const VBE_MODE Modes[VBE_MODE_COUNT] = { - { 0x14, 0xFFFF, NULL /* TODO */, NULL }, - { 0x54, 0x10A, NULL /* TODO */, NULL /* TODO */ }, - { 0x55, 0x109, NULL /* TODO */, NULL /* TODO */ }, - { 0x58, 0x102, NULL /* TODO */, NULL /* TODO */ }, - { 0x5C, 0x103, NULL /* TODO */, NULL /* TODO */ }, - { 0x5D, 0x104, NULL /* TODO */, NULL /* TODO */ }, - { 0x5E, 0x100, NULL /* TODO */, NULL /* TODO */ }, - { 0x5F, 0x101, NULL /* TODO */, NULL /* TODO */ }, - { 0x60, 0x105, NULL /* TODO */, NULL /* TODO */ }, - { 0x64, 0x111, NULL /* TODO */, NULL /* TODO */ }, - { 0x65, 0x114, NULL /* TODO */, NULL /* TODO */ }, - { 0x66, 0x110, NULL /* TODO */, NULL /* TODO */ }, - { 0x67, 0x113, NULL /* TODO */, NULL /* TODO */ }, - { 0x68, 0x116, NULL /* TODO */, NULL /* TODO */ }, - { 0x69, 0x119, NULL /* TODO */, NULL /* TODO */ }, - { 0x6C, 0x106, NULL /* TODO */, NULL /* TODO */ }, - { 0x6D, 0x107, NULL /* TODO */, NULL /* TODO */ }, - { 0x71, 0x112, NULL /* TODO */, NULL /* TODO */ }, - { 0x72, 0xFFFF, NULL /* TODO */, NULL }, - { 0x73, 0xFFFF, NULL /* TODO */, NULL }, - { 0x74, 0x117, NULL /* TODO */, NULL /* TODO */ }, - { 0x75, 0x11A, NULL /* TODO */, NULL /* TODO */ }, - { 0x76, 0xFFFF, NULL /* TODO */, NULL }, - { 0x78, 0x115, NULL /* TODO */, NULL /* TODO */ }, - { 0x79, 0x118, NULL /* TODO */, NULL /* TODO */ }, +static const VBE_MODE_INFO VbeMode_800x600x256_Info = +{ + /* Attributes */ + VBE_MODE_SUPPORTED + | VBE_MODE_OPTIONAL_INFO + // | VBE_MODE_BIOS_SUPPORT + | VBE_MODE_COLOR + | VBE_MODE_GRAPHICS, + + /* Window A attributes */ + VBE_WINDOW_EXISTS | VBE_WINDOW_READABLE | VBE_WINDOW_WRITABLE, + /* Window B attributes */ + 0, + + 16, /* Window granularity, in KB */ + 64, /* Window size, in KB */ + 0xA000, /* Window A segment, or zero if not supported */ + 0x0000, /* Window B segment, or zero if not supported */ + 0x00000000, /* Window position function pointer */ + 800, /* Bytes per scanline */ + 800, /* Width */ + 600, /* Height */ + 8, /* Character cell width */ + 16, /* Character cell height */ + 1, /* Number of memory planes */ + 8, /* Bits per pixel */ + 1, /* Number of banks */ + VBE_MODEL_PACKED, /* Memory model */ + 0, /* Bank size */ + 7, /* Number of image pages */ + 0, /* Reserved field */ + 0, /* Red mask size */ + 0, /* Red field position */ + 0, /* Green mask size */ + 0, /* Green field position */ + 0, /* Blue mask size */ + 0, /* Blue field position */ + 0, /* Reserved mask size */ + 0, /* Reserved field position */ + 0, /* Direct color info */ +}; + +static SVGA_REGISTERS VbeMode_800x600x256_Registers = +{ + /* Miscellaneous Register */ + 0x63, + + /* Hidden Register */ + 0x00, + + /* Sequencer Registers */ + { + 0x03, 0x21, 0x0F, 0x00, 0x0E, 0x00, 0x12, 0x11, 0x00, 0x00, 0x18, 0x23, + 0x23, 0x23, 0x23, 0x98, 0x00, 0x00, 0x04, 0x00, 0x00, 0x04, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x14, 0x14, 0x14, 0x14, 0x2D + }, + + /* CRTC Registers */ + { + 0x7D, 0x63, 0x63, 0x80, 0x6B, 0x1A, 0x98, 0xF0, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x7D, 0x23, 0x57, 0x64, 0x40, 0x57, 0x98, 0xC3, + 0xFF, 0x00, 0x00, 0x22, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0xFF, + 0x80, 0x00, 0x20, 0xB8 + }, + + /* GC Registers */ + { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F, 0xFF, 0x00, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 + }, + + /* AC Registers */ + { + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0A, 0x0B, + 0x0C, 0x0D, 0x0E, 0x0F, 0x41, 0x00, 0x0F, 0x00, 0x00 + } +}; + +static const VBE_MODE Modes[VBE_MODE_COUNT] = +{ + { 0x14, 0xFFFF, NULL , NULL /* TODO */ }, + { 0x54, 0x10A , NULL /* TODO */ , NULL /* TODO */ }, + { 0x55, 0x109 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x58, 0x102 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x5C, 0x103 , &VbeMode_800x600x256_Info, &VbeMode_800x600x256_Registers }, + { 0x5D, 0x104 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x5E, 0x100 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x5F, 0x101 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x60, 0x105 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x64, 0x111 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x65, 0x114 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x66, 0x110 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x67, 0x113 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x68, 0x116 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x69, 0x119 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x6C, 0x106 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x6D, 0x107 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x71, 0x112 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x72, 0xFFFF, NULL , NULL /* TODO */ }, + { 0x73, 0xFFFF, NULL , NULL /* TODO */ }, + { 0x74, 0x117 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x75, 0x11A , NULL /* TODO */ , NULL /* TODO */ }, + { 0x76, 0xFFFF, NULL , NULL /* TODO */ }, + { 0x78, 0x115 , NULL /* TODO */ , NULL /* TODO */ }, + { 0x79, 0x118 , NULL /* TODO */ , NULL /* TODO */ }, }; /* PRIVATE FUNCTIONS **********************************************************/ @@ -207,6 +289,9 @@ /* Update the current video mode in the BDA */ Bda->VideoMode = ModeNumber; + /* Clear the screen */ + VgaClearMemory(); + return TRUE; } @@ -218,15 +303,53 @@ BOOLEAN Interrupts = getIF(); setIF(0); - /* Reset the extended sequencer registers */ - for (i = SVGA_SEQ_EXT_MODE_REG; i < SVGA_SEQ_MAX_REG; i++) - { - if (i != VGA_SEQ_MAX_REG && i != SVGA_SEQ_UNLOCK_REG) + /* Turn the video off */ + IOWriteB(VGA_SEQ_INDEX, VGA_SEQ_CLOCK_REG); + IOWriteB(VGA_SEQ_DATA , IOReadB(VGA_SEQ_DATA) | VGA_SEQ_CLOCK_SD); + + /* Synchronous reset on */ + IOWriteB(VGA_SEQ_INDEX, VGA_SEQ_RESET_REG); + IOWriteB(VGA_SEQ_DATA , VGA_SEQ_RESET_AR ); + + /* Clear the extended sequencer registers, except for the VCLKs and MCLK */ + for (i = SVGA_SEQ_EXT_MODE_REG; i < SVGA_SEQ_VCLK0_DENOMINATOR_REG; i++) + { + if (i != VGA_SEQ_MAX_REG && i != SVGA_SEQ_UNLOCK_REG + && (i < SVGA_SEQ_VCLK0_NUMERATOR_REG || i > SVGA_SEQ_VCLK3_NUMERATOR_REG)) { IOWriteB(VGA_SEQ_INDEX, i); IOWriteB(VGA_SEQ_DATA, 0x00); } } + + /* Reset the VCLKs */ + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK0_NUMERATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x66); + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK0_DENOMINATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x3B); + + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK1_NUMERATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x5B); + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK1_DENOMINATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x2F); + + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK2_NUMERATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x45); + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK2_DENOMINATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x30); + + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK3_NUMERATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x7E); + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_VCLK3_DENOMINATOR_REG); + IOWriteB(VGA_SEQ_DATA, 0x33); + + /* Reset the MCLK */ + IOWriteB(VGA_SEQ_INDEX, SVGA_SEQ_MCLK_REG); + IOWriteB(VGA_SEQ_DATA, 0x1C); + + /* Synchronous reset off */ + IOWriteB(VGA_SEQ_INDEX, VGA_SEQ_RESET_REG); + IOWriteB(VGA_SEQ_DATA , VGA_SEQ_RESET_SR | VGA_SEQ_RESET_AR); /* Reset the extended CRTC registers */ for (i = SVGA_CRTC_INTERLACE_END_REG; i < SVGA_CRTC_MAX_REG; i++) @@ -255,6 +378,10 @@ */ for (i = 0; i < 4; i++) IOReadB(VGA_DAC_MASK); IOWriteB(VGA_DAC_MASK, 0x00); + + /* Turn the video on */ + IOWriteB(VGA_SEQ_INDEX, VGA_SEQ_CLOCK_REG); + IOWriteB(VGA_SEQ_DATA , IOReadB(VGA_SEQ_DATA) & ~VGA_SEQ_CLOCK_SD); /* Restore interrupts */ setIF(Interrupts); @@ -356,7 +483,7 @@ WORD VesaNumber = getBX(); setAL(0x4F); - if (getBX() <= BIOS_MAX_VIDEO_MODE) + if (VesaNumber <= BIOS_MAX_VIDEO_MODE) { /* Call the VGA BIOS */ setAH(0x00); Modified: trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/ntvdm/bios…
============================================================================== --- trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/mvdm/ntvdm/bios/bios32/vbe.h [iso-8859-1] Wed Jul 6 04:26:16 2016 @@ -90,13 +90,15 @@ C_ASSERT(sizeof(VBE_MODE_INFO) % sizeof(WORD) == 0); +typedef const struct _VBE_MODE_INFO *PCVBE_MODE_INFO; + #pragma pack(pop) typedef struct _VBE_MODE { BYTE Number; WORD VesaNumber; - PVBE_MODE_INFO Info; + PCVBE_MODE_INFO Info; PSVGA_REGISTERS Registers; } VBE_MODE, *PVBE_MODE; Modified: trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/svga.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/ntvdm/hard…
============================================================================== --- trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/svga.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/mvdm/ntvdm/hardware/video/svga.c [iso-8859-1] Wed Jul 6 04:26:16 2016 @@ -1674,12 +1674,20 @@ if (VgaGcRegisters[VGA_GC_MISC_REG] & VGA_GC_MISC_NOALPHA) { - /* Multiply the horizontal resolution by the 9/8 dot mode */ - Resolution.X *= (VgaSeqRegisters[VGA_SEQ_CLOCK_REG] & VGA_SEQ_CLOCK_98DM) - ? 8 : 9; - - /* The horizontal resolution is halved in 8-bit mode */ - if (VgaAcRegisters[VGA_AC_CONTROL_REG] & VGA_AC_CONTROL_8BIT) Resolution.X /= 2; + /* In "High Resolution" mode, the width of a character is always 8 pixels */ + if (VgaSeqRegisters[SVGA_SEQ_EXT_MODE_REG] & SVGA_SEQ_EXT_MODE_HIGH_RES) + { + Resolution.X *= 8; + } + else + { + /* Multiply the horizontal resolution by the 9/8 dot mode */ + Resolution.X *= (VgaSeqRegisters[VGA_SEQ_CLOCK_REG] & VGA_SEQ_CLOCK_98DM) + ? 8 : 9; + + /* The horizontal resolution is halved in 8-bit mode */ + if (VgaAcRegisters[VGA_AC_CONTROL_REG] & VGA_AC_CONTROL_8BIT) Resolution.X /= 2; + } } if (VgaCrtcRegisters[VGA_CRTC_MAX_SCAN_LINE_REG] & VGA_CRTC_MAXSCANLINE_DOUBLE)
8 years, 5 months
1
0
0
0
[hbelusca] 71829: [CLIPBRD]: Use NULL for null pointer. [EVENTVWR]: Add folder icons (needed for later).
by hbelusca@svn.reactos.org
Author: hbelusca Date: Tue Jul 5 23:42:40 2016 New Revision: 71829 URL:
http://svn.reactos.org/svn/reactos?rev=71829&view=rev
Log: [CLIPBRD]: Use NULL for null pointer. [EVENTVWR]: Add folder icons (needed for later). Added: trunk/reactos/base/applications/mscutils/eventvwr/res/folder.ico - copied unchanged from r71828, trunk/reactos/base/applications/regedit/res/folder.ico trunk/reactos/base/applications/mscutils/eventvwr/res/folderopen.ico - copied unchanged from r71828, trunk/reactos/base/applications/regedit/res/folderopen.ico Modified: trunk/reactos/base/applications/clipbrd/clipbrd.c Modified: trunk/reactos/base/applications/clipbrd/clipbrd.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/clipbrd/…
============================================================================== --- trunk/reactos/base/applications/clipbrd/clipbrd.c [iso-8859-1] (original) +++ trunk/reactos/base/applications/clipbrd/clipbrd.c [iso-8859-1] Tue Jul 5 23:42:40 2016 @@ -256,12 +256,12 @@ case CMD_ABOUT: { + HICON hIcon; WCHAR szTitle[MAX_STRING_LEN]; - HICON hIcon; hIcon = LoadIconW(Globals.hInstance, MAKEINTRESOURCE(CLIPBRD_ICON)); LoadStringW(Globals.hInstance, STRING_CLIPBOARD, szTitle, ARRAYSIZE(szTitle)); - ShellAboutW(Globals.hMainWnd, szTitle, 0, hIcon); + ShellAboutW(Globals.hMainWnd, szTitle, NULL, hIcon); DeleteObject(hIcon); break; }
8 years, 5 months
1
0
0
0
[tfaber] 71828: [NTOS:OB] - Always set LinkHandle in NtOpenSymbolicLinkObject, as shown by tests CORE-11509 #resolve
by tfaber@svn.reactos.org
Author: tfaber Date: Tue Jul 5 22:24:54 2016 New Revision: 71828 URL:
http://svn.reactos.org/svn/reactos?rev=71828&view=rev
Log: [NTOS:OB] - Always set LinkHandle in NtOpenSymbolicLinkObject, as shown by tests CORE-11509 #resolve Modified: trunk/reactos/ntoskrnl/ob/oblink.c Modified: trunk/reactos/ntoskrnl/ob/oblink.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ob/oblink.c?rev=7…
============================================================================== --- trunk/reactos/ntoskrnl/ob/oblink.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ob/oblink.c [iso-8859-1] Tue Jul 5 22:24:54 2016 @@ -702,20 +702,18 @@ DesiredAccess, NULL, &hLink); - if (NT_SUCCESS(Status)) - { - _SEH2_TRY - { - /* Return the handle to caller */ - *LinkHandle = hLink; - } - _SEH2_EXCEPT(ExSystemExceptionFilter()) - { - /* Get exception code */ - Status = _SEH2_GetExceptionCode(); - } - _SEH2_END; - } + + _SEH2_TRY + { + /* Return the handle to caller */ + *LinkHandle = hLink; + } + _SEH2_EXCEPT(ExSystemExceptionFilter()) + { + /* Get exception code */ + Status = _SEH2_GetExceptionCode(); + } + _SEH2_END; /* Return status to caller */ return Status;
8 years, 5 months
1
0
0
0
[hbelusca] 71827: [RAPPS(_new)][REGEDIT]: Fix our usage of (Begin)DeferWindowPos. See https://blogs.msdn.microsoft.com/oldnewthing/20050706-26/?p=35023 for more details.
by hbelusca@svn.reactos.org
Author: hbelusca Date: Tue Jul 5 21:30:44 2016 New Revision: 71827 URL:
http://svn.reactos.org/svn/reactos?rev=71827&view=rev
Log: [RAPPS(_new)][REGEDIT]: Fix our usage of (Begin)DeferWindowPos. See
https://blogs.msdn.microsoft.com/oldnewthing/20050706-26/?p=35023
for more details. Modified: trunk/reactos/base/applications/rapps/splitter.c trunk/reactos/base/applications/rapps/winmain.c trunk/reactos/base/applications/rapps_new/gui.cpp trunk/reactos/base/applications/rapps_new/rosui.h trunk/reactos/base/applications/rapps_new/splitter.cpp trunk/reactos/base/applications/regedit/childwnd.c Modified: trunk/reactos/base/applications/rapps/splitter.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/rapps/sp…
============================================================================== --- trunk/reactos/base/applications/rapps/splitter.c [iso-8859-1] (original) +++ trunk/reactos/base/applications/rapps/splitter.c [iso-8859-1] Tue Jul 5 21:30:44 2016 @@ -75,36 +75,40 @@ hdwp = BeginDeferWindowPos(3); /* Size HSplitBar */ - DeferWindowPos(hdwp, - hHSplitter, - 0, - GetWindowWidth(hTreeView) + SPLIT_WIDTH, - Point.y, - Width, - SPLIT_WIDTH, - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hHSplitter, + 0, + GetWindowWidth(hTreeView) + SPLIT_WIDTH, + Point.y, + Width, + SPLIT_WIDTH, + SWP_NOZORDER|SWP_NOACTIVATE); /* Size ListView */ - DeferWindowPos(hdwp, - hListView, - 0, - GetWindowWidth(hTreeView) + SPLIT_WIDTH, - GetWindowHeight(hToolBar), - Width, - Point.y - GetWindowHeight(hToolBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hListView, + 0, + GetWindowWidth(hTreeView) + SPLIT_WIDTH, + GetWindowHeight(hToolBar), + Width, + Point.y - GetWindowHeight(hToolBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size RichEdit */ - DeferWindowPos(hdwp, - hRichEdit, - 0, - GetWindowWidth(hTreeView) + SPLIT_WIDTH, - Point.y + SPLIT_WIDTH, - Width, - GetClientWindowHeight(hMainWnd) - (Point.y + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), - SWP_NOZORDER|SWP_NOACTIVATE); - - EndDeferWindowPos(hdwp); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hRichEdit, + 0, + GetWindowWidth(hTreeView) + SPLIT_WIDTH, + Point.y + SPLIT_WIDTH, + Width, + GetClientWindowHeight(hMainWnd) - (Point.y + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + EndDeferWindowPos(hdwp); } break; } @@ -192,54 +196,60 @@ hdwp = BeginDeferWindowPos(5); /* Size VSplitBar */ - DeferWindowPos(hdwp, - hwnd, - 0, - Point.x, - GetWindowHeight(hToolBar), - SPLIT_WIDTH, - GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hwnd, + 0, + Point.x, + GetWindowHeight(hToolBar), + SPLIT_WIDTH, + GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size TreeView */ - DeferWindowPos(hdwp, - hTreeView, - 0, - 0, - GetWindowHeight(hToolBar), - Point.x, - GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hTreeView, + 0, + 0, + GetWindowHeight(hToolBar), + Point.x, + GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size ListView */ - DeferWindowPos(hdwp, - hListView, - 0, - Point.x + SPLIT_WIDTH, - GetWindowHeight(hToolBar), - GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), - GetHSplitterPos() - GetWindowHeight(hToolBar), - SWP_NOZORDER|SWP_NOACTIVATE); - - DeferWindowPos(hdwp, - hRichEdit, - 0, - Point.x + SPLIT_WIDTH, - GetHSplitterPos() + SPLIT_WIDTH, - GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), - GetClientWindowHeight(hMainWnd) - (GetHSplitterPos() + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), - SWP_NOZORDER|SWP_NOACTIVATE); - - DeferWindowPos(hdwp, - hHSplitter, - 0, - Point.x + SPLIT_WIDTH, - GetHSplitterPos(), - GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), - SPLIT_WIDTH, - SWP_NOZORDER|SWP_NOACTIVATE); - - EndDeferWindowPos(hdwp); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hListView, + 0, + Point.x + SPLIT_WIDTH, + GetWindowHeight(hToolBar), + GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), + GetHSplitterPos() - GetWindowHeight(hToolBar), + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hRichEdit, + 0, + Point.x + SPLIT_WIDTH, + GetHSplitterPos() + SPLIT_WIDTH, + GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), + GetClientWindowHeight(hMainWnd) - (GetHSplitterPos() + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hHSplitter, + 0, + Point.x + SPLIT_WIDTH, + GetHSplitterPos(), + GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), + SPLIT_WIDTH, + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + EndDeferWindowPos(hdwp); } break; } Modified: trunk/reactos/base/applications/rapps/winmain.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/rapps/wi…
============================================================================== --- trunk/reactos/base/applications/rapps/winmain.c [iso-8859-1] (original) +++ trunk/reactos/base/applications/rapps/winmain.c [iso-8859-1] Tue Jul 5 21:30:44 2016 @@ -517,24 +517,26 @@ */ /* Size vertical splitter bar */ - DeferWindowPos(hdwp, - hVSplitter, - 0, - (VSplitterPos = GetWindowWidth(hTreeView)), - GetWindowHeight(hToolBar), - SPLIT_WIDTH, - HIWORD(lParam) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hVSplitter, + 0, + (VSplitterPos = GetWindowWidth(hTreeView)), + GetWindowHeight(hToolBar), + SPLIT_WIDTH, + HIWORD(lParam) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size TreeView */ - DeferWindowPos(hdwp, - hTreeView, - 0, - 0, - GetWindowHeight(hToolBar), - VSplitterPos, - HIWORD(lParam) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hTreeView, + 0, + 0, + GetWindowHeight(hToolBar), + VSplitterPos, + HIWORD(lParam) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), + SWP_NOZORDER|SWP_NOACTIVATE); if(wParam != SIZE_MINIMIZED) { @@ -548,36 +550,40 @@ SetHSplitterPos(NewPos); /* Size ListView */ - DeferWindowPos(hdwp, - hListView, - 0, - VSplitterPos + SPLIT_WIDTH, - GetWindowHeight(hToolBar), - LOWORD(lParam) - (VSplitterPos + SPLIT_WIDTH), - GetHSplitterPos() - GetWindowHeight(hToolBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hListView, + 0, + VSplitterPos + SPLIT_WIDTH, + GetWindowHeight(hToolBar), + LOWORD(lParam) - (VSplitterPos + SPLIT_WIDTH), + GetHSplitterPos() - GetWindowHeight(hToolBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size RichEdit */ - DeferWindowPos(hdwp, - hRichEdit, - 0, - VSplitterPos + SPLIT_WIDTH, - GetHSplitterPos() + SPLIT_WIDTH, - LOWORD(lParam) - (VSplitterPos + SPLIT_WIDTH), - RichPos, - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hRichEdit, + 0, + VSplitterPos + SPLIT_WIDTH, + GetHSplitterPos() + SPLIT_WIDTH, + LOWORD(lParam) - (VSplitterPos + SPLIT_WIDTH), + RichPos, + SWP_NOZORDER|SWP_NOACTIVATE); /* Size horizontal splitter bar */ - DeferWindowPos(hdwp, - hHSplitter, - 0, - VSplitterPos + SPLIT_WIDTH, - GetHSplitterPos(), - LOWORD(lParam) - (VSplitterPos + SPLIT_WIDTH), - SPLIT_WIDTH, - SWP_NOZORDER|SWP_NOACTIVATE); - - EndDeferWindowPos(hdwp); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hHSplitter, + 0, + VSplitterPos + SPLIT_WIDTH, + GetHSplitterPos(), + LOWORD(lParam) - (VSplitterPos + SPLIT_WIDTH), + SPLIT_WIDTH, + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + EndDeferWindowPos(hdwp); } BOOL IsSelectedNodeInstalled(void) Modified: trunk/reactos/base/applications/rapps_new/gui.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/rapps_ne…
============================================================================== --- trunk/reactos/base/applications/rapps_new/gui.cpp [iso-8859-1] (original) +++ trunk/reactos/base/applications/rapps_new/gui.cpp [iso-8859-1] Tue Jul 5 21:30:44 2016 @@ -600,14 +600,14 @@ int count = m_ClientPanel->CountSizableChildren(); hdwp = BeginDeferWindowPos(count); - hdwp = m_ClientPanel->OnParentSize(r, hdwp); - EndDeferWindowPos(hdwp); + if (hdwp) hdwp = m_ClientPanel->OnParentSize(r, hdwp); + if (hdwp) EndDeferWindowPos(hdwp); // TODO: Sub-layouts for children of children count = m_SearchBar->CountSizableChildren(); hdwp = BeginDeferWindowPos(count); - hdwp = m_SearchBar->OnParentSize(r, hdwp); - EndDeferWindowPos(hdwp); + if (hdwp) hdwp = m_SearchBar->OnParentSize(r, hdwp); + if (hdwp) EndDeferWindowPos(hdwp); } BOOL ProcessWindowMessage(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam, LRESULT& theResult, DWORD dwMapId) Modified: trunk/reactos/base/applications/rapps_new/rosui.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/rapps_ne…
============================================================================== --- trunk/reactos/base/applications/rapps_new/rosui.h [iso-8859-1] (original) +++ trunk/reactos/base/applications/rapps_new/rosui.h [iso-8859-1] Tue Jul 5 21:30:44 2016 @@ -769,8 +769,8 @@ HDWP hdwp = NULL; hdwp = BeginDeferWindowPos(count); - hdwp = OnParentSize(m_LastRect, hdwp); - EndDeferWindowPos(hdwp); + if (hdwp) hdwp = OnParentSize(m_LastRect, hdwp); + if (hdwp) EndDeferWindowPos(hdwp); } public: Modified: trunk/reactos/base/applications/rapps_new/splitter.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/rapps_ne…
============================================================================== --- trunk/reactos/base/applications/rapps_new/splitter.cpp [iso-8859-1] (original) +++ trunk/reactos/base/applications/rapps_new/splitter.cpp [iso-8859-1] Tue Jul 5 21:30:44 2016 @@ -75,36 +75,40 @@ hdwp = BeginDeferWindowPos(3); /* Size HSplitBar */ - DeferWindowPos(hdwp, - hHSplitter, - 0, - GetWindowWidth(hTreeView) + SPLIT_WIDTH, - Point.y, - Width, - SPLIT_WIDTH, - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hHSplitter, + 0, + GetWindowWidth(hTreeView) + SPLIT_WIDTH, + Point.y, + Width, + SPLIT_WIDTH, + SWP_NOZORDER|SWP_NOACTIVATE); /* Size ListView */ - DeferWindowPos(hdwp, - hListView, - 0, - GetWindowWidth(hTreeView) + SPLIT_WIDTH, - GetWindowHeight(hToolBar), - Width, - Point.y - GetWindowHeight(hToolBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hListView, + 0, + GetWindowWidth(hTreeView) + SPLIT_WIDTH, + GetWindowHeight(hToolBar), + Width, + Point.y - GetWindowHeight(hToolBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size RichEdit */ - DeferWindowPos(hdwp, - hRichEdit, - 0, - GetWindowWidth(hTreeView) + SPLIT_WIDTH, - Point.y + SPLIT_WIDTH, - Width, - GetClientWindowHeight(hMainWnd) - (Point.y + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), - SWP_NOZORDER|SWP_NOACTIVATE); - - EndDeferWindowPos(hdwp); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hRichEdit, + 0, + GetWindowWidth(hTreeView) + SPLIT_WIDTH, + Point.y + SPLIT_WIDTH, + Width, + GetClientWindowHeight(hMainWnd) - (Point.y + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + EndDeferWindowPos(hdwp); } break; } @@ -192,54 +196,60 @@ hdwp = BeginDeferWindowPos(5); /* Size VSplitBar */ - DeferWindowPos(hdwp, - hwnd, - 0, - Point.x, - GetWindowHeight(hToolBar), - SPLIT_WIDTH, - GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hwnd, + 0, + Point.x, + GetWindowHeight(hToolBar), + SPLIT_WIDTH, + GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size TreeView */ - DeferWindowPos(hdwp, - hTreeView, - 0, - 0, - GetWindowHeight(hToolBar), - Point.x, - GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), - SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hTreeView, + 0, + 0, + GetWindowHeight(hToolBar), + Point.x, + GetClientWindowHeight(hMainWnd) - GetWindowHeight(hToolBar) - GetWindowHeight(hStatusBar), + SWP_NOZORDER|SWP_NOACTIVATE); /* Size ListView */ - DeferWindowPos(hdwp, - hListView, - 0, - Point.x + SPLIT_WIDTH, - GetWindowHeight(hToolBar), - GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), - GetHSplitterPos() - GetWindowHeight(hToolBar), - SWP_NOZORDER|SWP_NOACTIVATE); - - DeferWindowPos(hdwp, - hRichEdit, - 0, - Point.x + SPLIT_WIDTH, - GetHSplitterPos() + SPLIT_WIDTH, - GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), - GetClientWindowHeight(hMainWnd) - (GetHSplitterPos() + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), - SWP_NOZORDER|SWP_NOACTIVATE); - - DeferWindowPos(hdwp, - hHSplitter, - 0, - Point.x + SPLIT_WIDTH, - GetHSplitterPos(), - GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), - SPLIT_WIDTH, - SWP_NOZORDER|SWP_NOACTIVATE); - - EndDeferWindowPos(hdwp); + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hListView, + 0, + Point.x + SPLIT_WIDTH, + GetWindowHeight(hToolBar), + GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), + GetHSplitterPos() - GetWindowHeight(hToolBar), + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hRichEdit, + 0, + Point.x + SPLIT_WIDTH, + GetHSplitterPos() + SPLIT_WIDTH, + GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), + GetClientWindowHeight(hMainWnd) - (GetHSplitterPos() + SPLIT_WIDTH + GetWindowHeight(hStatusBar)), + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + hdwp = DeferWindowPos(hdwp, + hHSplitter, + 0, + Point.x + SPLIT_WIDTH, + GetHSplitterPos(), + GetClientWindowWidth(hMainWnd) - (Point.x + SPLIT_WIDTH), + SPLIT_WIDTH, + SWP_NOZORDER|SWP_NOACTIVATE); + + if (hdwp) + EndDeferWindowPos(hdwp); } break; } Modified: trunk/reactos/base/applications/regedit/childwnd.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/regedit/…
============================================================================== --- trunk/reactos/base/applications/regedit/childwnd.c [iso-8859-1] (original) +++ trunk/reactos/base/applications/regedit/childwnd.c [iso-8859-1] Tue Jul 5 21:30:44 2016 @@ -52,11 +52,11 @@ } GetWindowRect(g_pChildWnd->hAddressBtnWnd, &rb); cx = g_pChildWnd->nSplitPos + SPLIT_WIDTH/2; - DeferWindowPos(hdwp, g_pChildWnd->hAddressBarWnd, 0, rt.left, rt.top, rt.right-rt.left - 2*tHeight, tHeight, SWP_NOZORDER|SWP_NOACTIVATE); - DeferWindowPos(hdwp, g_pChildWnd->hAddressBtnWnd, 0, rt.right - 2*tHeight, rt.top, 2*tHeight, tHeight, SWP_NOZORDER|SWP_NOACTIVATE); - DeferWindowPos(hdwp, g_pChildWnd->hTreeWnd, 0, rt.left, rt.top + tHeight+2, g_pChildWnd->nSplitPos-SPLIT_WIDTH/2-rt.left, rt.bottom-rt.top-cy, SWP_NOZORDER|SWP_NOACTIVATE); - DeferWindowPos(hdwp, g_pChildWnd->hListWnd, 0, rt.left+cx, rt.top + tHeight+2, rt.right-cx, rt.bottom-rt.top-cy, SWP_NOZORDER|SWP_NOACTIVATE); - EndDeferWindowPos(hdwp); + if (hdwp) hdwp = DeferWindowPos(hdwp, g_pChildWnd->hAddressBarWnd, 0, rt.left, rt.top, rt.right-rt.left - 2*tHeight, tHeight, SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) hdwp = DeferWindowPos(hdwp, g_pChildWnd->hAddressBtnWnd, 0, rt.right - 2*tHeight, rt.top, 2*tHeight, tHeight, SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) hdwp = DeferWindowPos(hdwp, g_pChildWnd->hTreeWnd, 0, rt.left, rt.top + tHeight+2, g_pChildWnd->nSplitPos-SPLIT_WIDTH/2-rt.left, rt.bottom-rt.top-cy, SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) hdwp = DeferWindowPos(hdwp, g_pChildWnd->hListWnd, 0, rt.left+cx, rt.top + tHeight+2, rt.right-cx, rt.bottom-rt.top-cy, SWP_NOZORDER|SWP_NOACTIVATE); + if (hdwp) EndDeferWindowPos(hdwp); } /*******************************************************************************
8 years, 5 months
1
0
0
0
← Newer
1
...
21
22
23
24
25
26
27
...
36
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
Results per page:
10
25
50
100
200