mirror of
https://github.com/reactos/reactos.git
synced 2024-08-03 01:50:57 +00:00
[CMAKE]
Sync with trunk head (r48826) svn path=/branches/cmake-bringup/; revision=48831
This commit is contained in:
commit
912ce51ae6
|
@ -359,6 +359,7 @@ CLEANUP:
|
||||||
|
|
||||||
VOID ShowInfo(BOOL bAll)
|
VOID ShowInfo(BOOL bAll)
|
||||||
{
|
{
|
||||||
|
MIB_IFROW mibEntry;
|
||||||
PIP_ADAPTER_INFO pAdapterInfo = NULL;
|
PIP_ADAPTER_INFO pAdapterInfo = NULL;
|
||||||
PIP_ADAPTER_INFO pAdapter = NULL;
|
PIP_ADAPTER_INFO pAdapter = NULL;
|
||||||
ULONG adaptOutBufLen = 0;
|
ULONG adaptOutBufLen = 0;
|
||||||
|
@ -441,6 +442,9 @@ VOID ShowInfo(BOOL bAll)
|
||||||
{
|
{
|
||||||
LPTSTR IntType, myConType;
|
LPTSTR IntType, myConType;
|
||||||
|
|
||||||
|
mibEntry.dwIndex = pAdapter->Index;
|
||||||
|
GetIfEntry(&mibEntry);
|
||||||
|
|
||||||
IntType = GetInterfaceTypeName(pAdapter->Type);
|
IntType = GetInterfaceTypeName(pAdapter->Type);
|
||||||
myConType = GetConnectionType(pAdapter->AdapterName);
|
myConType = GetConnectionType(pAdapter->AdapterName);
|
||||||
|
|
||||||
|
@ -449,7 +453,7 @@ VOID ShowInfo(BOOL bAll)
|
||||||
if (myConType != NULL) HeapFree(ProcessHeap, 0, myConType);
|
if (myConType != NULL) HeapFree(ProcessHeap, 0, myConType);
|
||||||
|
|
||||||
/* check if the adapter is connected to the media */
|
/* check if the adapter is connected to the media */
|
||||||
if (_tcscmp(pAdapter->IpAddressList.IpAddress.String, "0.0.0.0") == 0)
|
if (mibEntry.dwOperStatus != MIB_IF_OPER_STATUS_CONNECTED && mibEntry.dwOperStatus != MIB_IF_OPER_STATUS_OPERATIONAL)
|
||||||
{
|
{
|
||||||
_tprintf(_T("\tMedia State . . . . . . . . . . . : Media disconnected\n"));
|
_tprintf(_T("\tMedia State . . . . . . . . . . . : Media disconnected\n"));
|
||||||
pAdapter = pAdapter->Next;
|
pAdapter = pAdapter->Next;
|
||||||
|
|
|
@ -237,12 +237,13 @@ BOOL DisplayOutput()
|
||||||
ShowUdpStatistics();
|
ShowUdpStatistics();
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
else //if (bDoShowAllCons)
|
else
|
||||||
{
|
{
|
||||||
_tprintf(_T("\nActive Connections\n"));
|
_tprintf(_T("\nActive Connections\n"));
|
||||||
_tprintf(_T("\n Proto Local Address Foreign Address State\n"));
|
_tprintf(_T("\n Proto Local Address Foreign Address State\n"));
|
||||||
ShowTcpTable();
|
ShowTcpTable();
|
||||||
ShowUdpTable();
|
if (bDoShowAllCons)
|
||||||
|
ShowUdpTable();
|
||||||
}
|
}
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
@ -422,23 +423,24 @@ VOID ShowTcpTable()
|
||||||
CHAR Remote[ADDRESSLEN];
|
CHAR Remote[ADDRESSLEN];
|
||||||
|
|
||||||
/* Get the table of TCP endpoints */
|
/* Get the table of TCP endpoints */
|
||||||
dwSize = 0;
|
dwSize = sizeof (MIB_TCPTABLE);
|
||||||
error = GetTcpTable(NULL, &dwSize, TRUE);
|
/* Should also work when we get new connections between 2 GetTcpTable()
|
||||||
if (error != ERROR_INSUFFICIENT_BUFFER)
|
* calls: */
|
||||||
|
do
|
||||||
|
{
|
||||||
|
tcpTable = (PMIB_TCPTABLE) HeapAlloc(GetProcessHeap(), 0, dwSize);
|
||||||
|
error = GetTcpTable(tcpTable, &dwSize, TRUE);
|
||||||
|
if ( error != NO_ERROR )
|
||||||
|
HeapFree(GetProcessHeap(), 0, tcpTable);
|
||||||
|
}
|
||||||
|
while ( error == ERROR_INSUFFICIENT_BUFFER );
|
||||||
|
|
||||||
|
if (error != NO_ERROR)
|
||||||
{
|
{
|
||||||
printf("Failed to snapshot TCP endpoints.\n");
|
printf("Failed to snapshot TCP endpoints.\n");
|
||||||
DoFormatMessage(error);
|
DoFormatMessage(error);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
tcpTable = (PMIB_TCPTABLE) HeapAlloc(GetProcessHeap(), 0, dwSize);
|
|
||||||
error = GetTcpTable(tcpTable, &dwSize, TRUE );
|
|
||||||
if (error)
|
|
||||||
{
|
|
||||||
printf("Failed to snapshot TCP endpoints table.\n");
|
|
||||||
DoFormatMessage(error);
|
|
||||||
HeapFree(GetProcessHeap(), 0, tcpTable);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Dump the TCP table */
|
/* Dump the TCP table */
|
||||||
for (i = 0; i < tcpTable->dwNumEntries; i++)
|
for (i = 0; i < tcpTable->dwNumEntries; i++)
|
||||||
|
|
|
@ -587,8 +587,8 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
pt.x = pt.y = 0;
|
pt.x = pt.y = 0;
|
||||||
|
ClientToScreen(pChildWnd->hListWnd, &pt);
|
||||||
}
|
}
|
||||||
ClientToScreen(pChildWnd->hListWnd, &pt);
|
|
||||||
if(i == -1)
|
if(i == -1)
|
||||||
{
|
{
|
||||||
TrackPopupMenu(GetSubMenu(hPopupMenus, PM_NEW), TPM_RIGHTBUTTON, pt.x, pt.y, 0, hFrameWnd, NULL);
|
TrackPopupMenu(GetSubMenu(hPopupMenus, PM_NEW), TPM_RIGHTBUTTON, pt.x, pt.y, 0, hFrameWnd, NULL);
|
||||||
|
|
|
@ -47,9 +47,11 @@ typedef struct
|
||||||
|
|
||||||
INT SelStart;
|
INT SelStart;
|
||||||
INT SelEnd;
|
INT SelEnd;
|
||||||
BOOL SelOnField;
|
|
||||||
} HEXEDIT_DATA, *PHEXEDIT_DATA;
|
} HEXEDIT_DATA, *PHEXEDIT_DATA;
|
||||||
|
|
||||||
|
static const TCHAR ClipboardFormatName[] = TEXT("RegEdit_HexData");
|
||||||
|
static UINT ClipboardFormatID = 0;
|
||||||
|
|
||||||
/* hit test codes */
|
/* hit test codes */
|
||||||
#define HEHT_LEFTMARGIN (0x1)
|
#define HEHT_LEFTMARGIN (0x1)
|
||||||
#define HEHT_ADDRESS (0x2)
|
#define HEHT_ADDRESS (0x2)
|
||||||
|
@ -67,6 +69,8 @@ RegisterHexEditorClass(HINSTANCE hInstance)
|
||||||
{
|
{
|
||||||
WNDCLASSEX WndClass;
|
WNDCLASSEX WndClass;
|
||||||
|
|
||||||
|
ClipboardFormatID = RegisterClipboardFormat(ClipboardFormatName);
|
||||||
|
|
||||||
ZeroMemory(&WndClass, sizeof(WNDCLASSEX));
|
ZeroMemory(&WndClass, sizeof(WNDCLASSEX));
|
||||||
WndClass.cbSize = sizeof(WNDCLASSEX);
|
WndClass.cbSize = sizeof(WNDCLASSEX);
|
||||||
WndClass.style = CS_DBLCLKS;
|
WndClass.style = CS_DBLCLKS;
|
||||||
|
@ -218,7 +222,7 @@ HEXEDIT_PaintLines(PHEXEDIT_DATA hed, HDC hDC, DWORD ScrollPos, DWORD First, DWO
|
||||||
if(ScrollPos + First == 0)
|
if(ScrollPos + First == 0)
|
||||||
{
|
{
|
||||||
/* draw address */
|
/* draw address */
|
||||||
_stprintf(addr, _T("%04X"), 0);
|
wsprintf(addr, TEXT("%04X"), 0);
|
||||||
TextOut(hDC, hed->LeftMargin, First * hed->LineHeight, addr, 4);
|
TextOut(hDC, hed->LeftMargin, First * hed->LineHeight, addr, 4);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -240,7 +244,7 @@ HEXEDIT_PaintLines(PHEXEDIT_DATA hed, HDC hDC, DWORD ScrollPos, DWORD First, DWO
|
||||||
dx = hed->LeftMargin;
|
dx = hed->LeftMargin;
|
||||||
|
|
||||||
/* draw address */
|
/* draw address */
|
||||||
_stprintf(addr, _T("%04lX"), linestart);
|
wsprintf(addr, TEXT("%04lX"), linestart);
|
||||||
TextOut(hDC, dx, dy, addr, 4);
|
TextOut(hDC, dx, dy, addr, 4);
|
||||||
|
|
||||||
dx += ((4 + hed->AddressSpacing) * hed->CharWidth);
|
dx += ((4 + hed->AddressSpacing) * hed->CharWidth);
|
||||||
|
@ -260,7 +264,7 @@ HEXEDIT_PaintLines(PHEXEDIT_DATA hed, HDC hDC, DWORD ScrollPos, DWORD First, DWO
|
||||||
rct.left += dh;
|
rct.left += dh;
|
||||||
rct.right += dh;
|
rct.right += dh;
|
||||||
|
|
||||||
_stprintf(hex, _T("%02X"), *(current++));
|
wsprintf(hex, TEXT("%02X"), *(current++));
|
||||||
if (i0 <= i && i < i1)
|
if (i0 <= i && i < i1)
|
||||||
{
|
{
|
||||||
rct2.left = dx;
|
rct2.left = dx;
|
||||||
|
@ -275,7 +279,7 @@ HEXEDIT_PaintLines(PHEXEDIT_DATA hed, HDC hDC, DWORD ScrollPos, DWORD First, DWO
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
ExtTextOut(hDC, dx, dy, ETO_OPAQUE, &rct, hex, 2, NULL);
|
ExtTextOut(hDC, dx, dy, ETO_OPAQUE, &rct, hex, 2, NULL);
|
||||||
dx += dh;
|
dx += dh;
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -285,8 +289,8 @@ HEXEDIT_PaintLines(PHEXEDIT_DATA hed, HDC hDC, DWORD ScrollPos, DWORD First, DWO
|
||||||
i = isave;
|
i = isave;
|
||||||
for(x = 0; x < hed->ColumnsPerLine && current < end; x++)
|
for(x = 0; x < hed->ColumnsPerLine && current < end; x++)
|
||||||
{
|
{
|
||||||
_stprintf(hex, _T("%C"), *(current++));
|
wsprintf(hex, _T("%C"), *(current++));
|
||||||
hex[0] = ((hex[0] & _T('\x007f')) >= _T(' ') ? hex[0] : _T('.'));
|
hex[0] = ((hex[0] & _T('\x007f')) >= _T(' ') ? hex[0] : _T('.'));
|
||||||
if (i0 <= i && i < i1)
|
if (i0 <= i && i < i1)
|
||||||
{
|
{
|
||||||
rct2.left = dx;
|
rct2.left = dx;
|
||||||
|
@ -300,7 +304,7 @@ HEXEDIT_PaintLines(PHEXEDIT_DATA hed, HDC hDC, DWORD ScrollPos, DWORD First, DWO
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
TextOut(hDC, dx, dy, hex, 1);
|
TextOut(hDC, dx, dy, hex, 1);
|
||||||
dx += hed->CharWidth;
|
dx += hed->CharWidth;
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -415,6 +419,149 @@ HEXEDIT_IndexFromPoint(PHEXEDIT_DATA hed, POINTS pt, DWORD Hit, POINT *EditPos,
|
||||||
return Index;
|
return Index;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
HEXEDIT_Copy(PHEXEDIT_DATA hed)
|
||||||
|
{
|
||||||
|
PBYTE pb, buf;
|
||||||
|
UINT cb;
|
||||||
|
INT i0, i1;
|
||||||
|
HGLOBAL hGlobal;
|
||||||
|
|
||||||
|
if (hed->SelStart < hed->SelEnd)
|
||||||
|
{
|
||||||
|
i0 = hed->SelStart;
|
||||||
|
i1 = hed->SelEnd;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
i0 = hed->SelEnd;
|
||||||
|
i1 = hed->SelStart;
|
||||||
|
}
|
||||||
|
|
||||||
|
cb = i1 - i0;
|
||||||
|
if (cb == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
|
hGlobal = GlobalAlloc(GHND | GMEM_SHARE, cb + sizeof(DWORD));
|
||||||
|
if (hGlobal == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
|
pb = GlobalLock(hGlobal);
|
||||||
|
if (pb)
|
||||||
|
{
|
||||||
|
*(PDWORD)pb = cb;
|
||||||
|
pb += sizeof(DWORD);
|
||||||
|
buf = (PBYTE) LocalLock(hed->hBuffer);
|
||||||
|
if (buf)
|
||||||
|
{
|
||||||
|
CopyMemory(pb, buf + i0, cb);
|
||||||
|
LocalUnlock(hed->hBuffer);
|
||||||
|
}
|
||||||
|
GlobalUnlock(hGlobal);
|
||||||
|
|
||||||
|
if (OpenClipboard(hed->hWndSelf))
|
||||||
|
{
|
||||||
|
EmptyClipboard();
|
||||||
|
SetClipboardData(ClipboardFormatID, hGlobal);
|
||||||
|
CloseClipboard();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
GlobalFree(hGlobal);
|
||||||
|
}
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
HEXEDIT_Delete(PHEXEDIT_DATA hed)
|
||||||
|
{
|
||||||
|
PBYTE buf;
|
||||||
|
INT i0, i1;
|
||||||
|
UINT bufsize;
|
||||||
|
|
||||||
|
if (hed->SelStart < hed->SelEnd)
|
||||||
|
{
|
||||||
|
i0 = hed->SelStart;
|
||||||
|
i1 = hed->SelEnd;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
i0 = hed->SelEnd;
|
||||||
|
i1 = hed->SelStart;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i0 != i1)
|
||||||
|
{
|
||||||
|
bufsize = (hed->hBuffer ? LocalSize(hed->hBuffer) : 0);
|
||||||
|
buf = (PBYTE) LocalLock(hed->hBuffer);
|
||||||
|
if (buf)
|
||||||
|
{
|
||||||
|
MoveMemory(buf + i0, buf + i1, bufsize - i1);
|
||||||
|
LocalUnlock(hed->hBuffer);
|
||||||
|
}
|
||||||
|
HexEdit_SetMaxBufferSize(hed->hWndSelf, bufsize - (i1 - i0));
|
||||||
|
hed->InMid = FALSE;
|
||||||
|
hed->Index = hed->SelStart = hed->SelEnd = i0;
|
||||||
|
hed->CaretCol = hed->Index % hed->ColumnsPerLine;
|
||||||
|
hed->CaretLine = hed->Index / hed->ColumnsPerLine;
|
||||||
|
InvalidateRect(hed->hWndSelf, NULL, TRUE);
|
||||||
|
HEXEDIT_MoveCaret(hed, TRUE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
HEXEDIT_Paste(PHEXEDIT_DATA hed)
|
||||||
|
{
|
||||||
|
HGLOBAL hGlobal;
|
||||||
|
UINT bufsize;
|
||||||
|
PBYTE pb, buf;
|
||||||
|
DWORD cb;
|
||||||
|
|
||||||
|
HEXEDIT_Delete(hed);
|
||||||
|
bufsize = (hed->hBuffer ? LocalSize(hed->hBuffer) : 0);
|
||||||
|
|
||||||
|
if (OpenClipboard(hed->hWndSelf))
|
||||||
|
{
|
||||||
|
hGlobal = GetClipboardData(ClipboardFormatID);
|
||||||
|
if (hGlobal != NULL)
|
||||||
|
{
|
||||||
|
pb = (PBYTE) GlobalLock(hGlobal);
|
||||||
|
cb = *(PDWORD) pb;
|
||||||
|
pb += sizeof(DWORD);
|
||||||
|
HexEdit_SetMaxBufferSize(hed->hWndSelf, bufsize + cb);
|
||||||
|
buf = (PBYTE) LocalLock(hed->hBuffer);
|
||||||
|
if (buf)
|
||||||
|
{
|
||||||
|
MoveMemory(buf + hed->Index + cb, buf + hed->Index,
|
||||||
|
bufsize - hed->Index);
|
||||||
|
CopyMemory(buf + hed->Index, pb, cb);
|
||||||
|
LocalUnlock(hed->hBuffer);
|
||||||
|
}
|
||||||
|
GlobalUnlock(hGlobal);
|
||||||
|
}
|
||||||
|
CloseClipboard();
|
||||||
|
}
|
||||||
|
InvalidateRect(hed->hWndSelf, NULL, TRUE);
|
||||||
|
HEXEDIT_MoveCaret(hed, TRUE);
|
||||||
|
}
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
HEXEDIT_Cut(PHEXEDIT_DATA hed)
|
||||||
|
{
|
||||||
|
HEXEDIT_Copy(hed);
|
||||||
|
HEXEDIT_Delete(hed);
|
||||||
|
}
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
HEXEDIT_SelectAll(PHEXEDIT_DATA hed)
|
||||||
|
{
|
||||||
|
INT bufsize;
|
||||||
|
|
||||||
|
bufsize = (hed->hBuffer ? (INT) LocalSize(hed->hBuffer) : 0);
|
||||||
|
hed->Index = hed->SelStart = 0;
|
||||||
|
hed->SelEnd = bufsize;
|
||||||
|
InvalidateRect(hed->hWndSelf, NULL, TRUE);
|
||||||
|
HEXEDIT_MoveCaret(hed, TRUE);
|
||||||
|
}
|
||||||
|
|
||||||
/*** Control specific messages ************************************************/
|
/*** Control specific messages ************************************************/
|
||||||
|
|
||||||
static LRESULT
|
static LRESULT
|
||||||
|
@ -808,19 +955,18 @@ HEXEDIT_WM_LBUTTONDOWN(PHEXEDIT_DATA hed, INT Buttons, POINTS Pt)
|
||||||
|
|
||||||
if (GetAsyncKeyState(VK_SHIFT) < 0)
|
if (GetAsyncKeyState(VK_SHIFT) < 0)
|
||||||
{
|
{
|
||||||
if (hed->SelOnField)
|
if (hed->EditingField)
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_HEXDUMP, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_HEXDUMP, &EditPos, &NewField);
|
||||||
else
|
else
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_ASCIIDUMP, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_ASCIIDUMP, &EditPos, &NewField);
|
||||||
hed->SelEnd = hed->Index;
|
hed->SelEnd = hed->Index;
|
||||||
hed->EditingField = hed->SelOnField;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Hit = HEXEDIT_HitRegionTest(hed, Pt);
|
Hit = HEXEDIT_HitRegionTest(hed, Pt);
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, Hit, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, Hit, &EditPos, &NewField);
|
||||||
hed->SelStart = hed->SelEnd = hed->Index;
|
hed->SelStart = hed->SelEnd = hed->Index;
|
||||||
hed->SelOnField = hed->EditingField = NewField;
|
hed->EditingField = NewField;
|
||||||
SetCapture(hed->hWndSelf);
|
SetCapture(hed->hWndSelf);
|
||||||
}
|
}
|
||||||
hed->CaretCol = EditPos.x;
|
hed->CaretCol = EditPos.x;
|
||||||
|
@ -839,7 +985,7 @@ HEXEDIT_WM_LBUTTONUP(PHEXEDIT_DATA hed, INT Buttons, POINTS Pt)
|
||||||
POINT EditPos;
|
POINT EditPos;
|
||||||
if (GetCapture() == hed->hWndSelf)
|
if (GetCapture() == hed->hWndSelf)
|
||||||
{
|
{
|
||||||
if (hed->SelOnField)
|
if (hed->EditingField)
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_HEXDUMP, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_HEXDUMP, &EditPos, &NewField);
|
||||||
else
|
else
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_ASCIIDUMP, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_ASCIIDUMP, &EditPos, &NewField);
|
||||||
|
@ -860,7 +1006,7 @@ HEXEDIT_WM_MOUSEMOVE(PHEXEDIT_DATA hed, INT Buttons, POINTS Pt)
|
||||||
POINT EditPos;
|
POINT EditPos;
|
||||||
if (GetCapture() == hed->hWndSelf)
|
if (GetCapture() == hed->hWndSelf)
|
||||||
{
|
{
|
||||||
if (hed->SelOnField)
|
if (hed->EditingField)
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_HEXDUMP, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_HEXDUMP, &EditPos, &NewField);
|
||||||
else
|
else
|
||||||
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_ASCIIDUMP, &EditPos, &NewField);
|
hed->Index = HEXEDIT_IndexFromPoint(hed, Pt, HEHT_ASCIIDUMP, &EditPos, &NewField);
|
||||||
|
@ -900,8 +1046,51 @@ HEXEDIT_WM_KEYDOWN(PHEXEDIT_DATA hed, INT VkCode)
|
||||||
|
|
||||||
switch(VkCode)
|
switch(VkCode)
|
||||||
{
|
{
|
||||||
case VK_DELETE:
|
case 'X':
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) >= 0 &&
|
||||||
|
GetAsyncKeyState(VK_CONTROL) < 0 && hed->SelStart != hed->SelEnd)
|
||||||
|
HEXEDIT_Cut(hed);
|
||||||
|
else
|
||||||
|
return TRUE;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'C':
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) >= 0 &&
|
||||||
|
GetAsyncKeyState(VK_CONTROL) < 0 && hed->SelStart != hed->SelEnd)
|
||||||
|
HEXEDIT_Copy(hed);
|
||||||
|
else
|
||||||
|
return TRUE;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'V':
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) >= 0 && GetAsyncKeyState(VK_CONTROL) < 0)
|
||||||
|
HEXEDIT_Paste(hed);
|
||||||
|
else
|
||||||
|
return TRUE;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'A':
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) >= 0 && GetAsyncKeyState(VK_CONTROL) < 0)
|
||||||
|
HEXEDIT_SelectAll(hed);
|
||||||
|
else
|
||||||
|
return TRUE;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case VK_INSERT:
|
||||||
if (hed->SelStart != hed->SelEnd)
|
if (hed->SelStart != hed->SelEnd)
|
||||||
|
{
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) >= 0 && GetAsyncKeyState(VK_CONTROL) < 0)
|
||||||
|
HEXEDIT_Copy(hed);
|
||||||
|
}
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) < 0 && GetAsyncKeyState(VK_CONTROL) >= 0)
|
||||||
|
HEXEDIT_Paste(hed);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case VK_DELETE:
|
||||||
|
if (GetAsyncKeyState(VK_SHIFT) < 0 && GetAsyncKeyState(VK_CONTROL) >= 0 &&
|
||||||
|
hed->SelStart != hed->SelEnd)
|
||||||
|
HEXEDIT_Copy(hed);
|
||||||
|
if (i0 != i1)
|
||||||
{
|
{
|
||||||
buf = (PBYTE) LocalLock(hed->hBuffer);
|
buf = (PBYTE) LocalLock(hed->hBuffer);
|
||||||
if (buf)
|
if (buf)
|
||||||
|
@ -946,7 +1135,7 @@ HEXEDIT_WM_KEYDOWN(PHEXEDIT_DATA hed, INT VkCode)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case VK_BACK:
|
case VK_BACK:
|
||||||
if (hed->SelStart != hed->SelEnd)
|
if (i0 != i1)
|
||||||
{
|
{
|
||||||
buf = (PBYTE) LocalLock(hed->hBuffer);
|
buf = (PBYTE) LocalLock(hed->hBuffer);
|
||||||
if (buf)
|
if (buf)
|
||||||
|
@ -986,6 +1175,8 @@ HEXEDIT_WM_KEYDOWN(PHEXEDIT_DATA hed, INT VkCode)
|
||||||
hed->CaretCol = hed->Index % hed->ColumnsPerLine;
|
hed->CaretCol = hed->Index % hed->ColumnsPerLine;
|
||||||
hed->CaretLine = hed->Index / hed->ColumnsPerLine;
|
hed->CaretLine = hed->Index / hed->ColumnsPerLine;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
return TRUE;
|
||||||
HexEdit_SetMaxBufferSize(hed->hWndSelf, bufsize - 1);
|
HexEdit_SetMaxBufferSize(hed->hWndSelf, bufsize - 1);
|
||||||
hed->InMid = FALSE;
|
hed->InMid = FALSE;
|
||||||
}
|
}
|
||||||
|
@ -1056,6 +1247,9 @@ HEXEDIT_WM_KEYDOWN(PHEXEDIT_DATA hed, INT VkCode)
|
||||||
InvalidateRect(hed->hWndSelf, NULL, TRUE);
|
InvalidateRect(hed->hWndSelf, NULL, TRUE);
|
||||||
HEXEDIT_MoveCaret(hed, TRUE);
|
HEXEDIT_MoveCaret(hed, TRUE);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
@ -1185,6 +1379,40 @@ HEXEDIT_WM_SIZE(PHEXEDIT_DATA hed, DWORD sType, WORD NewWidth, WORD NewHeight)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
HEXEDIT_WM_CONTEXTMENU(PHEXEDIT_DATA hed, INT x, INT y)
|
||||||
|
{
|
||||||
|
HMENU hMenu;
|
||||||
|
RECT rc;
|
||||||
|
|
||||||
|
if (x == -1 && y == -1)
|
||||||
|
{
|
||||||
|
GetWindowRect(hed->hWndSelf, &rc);
|
||||||
|
x = rc.left;
|
||||||
|
y = rc.top;
|
||||||
|
}
|
||||||
|
|
||||||
|
hMenu = GetSubMenu(hPopupMenus, PM_HEXEDIT);
|
||||||
|
if (hed->SelStart == hed->SelEnd)
|
||||||
|
{
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_CUT, MF_GRAYED);
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_COPY, MF_GRAYED);
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_PASTE, MF_GRAYED);
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_DELETE, MF_GRAYED);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_CUT, MF_ENABLED);
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_COPY, MF_ENABLED);
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_PASTE, MF_ENABLED);
|
||||||
|
EnableMenuItem(hMenu, ID_HEXEDIT_DELETE, MF_ENABLED);
|
||||||
|
}
|
||||||
|
|
||||||
|
SetForegroundWindow(hed->hWndSelf);
|
||||||
|
TrackPopupMenu(hMenu, TPM_RIGHTBUTTON, x, y, 0, hed->hWndSelf, NULL);
|
||||||
|
PostMessage(hed->hWndSelf, WM_NULL, 0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
INT_PTR CALLBACK
|
INT_PTR CALLBACK
|
||||||
HexEditWndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
HexEditWndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||||
{
|
{
|
||||||
|
@ -1291,11 +1519,32 @@ HexEditWndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WM_CONTEXTMENU:
|
case WM_CONTEXTMENU:
|
||||||
/* FIXME: Implement Cut, Copy, Paste, Delete and Select All */
|
HEXEDIT_WM_CONTEXTMENU(hed, (short)LOWORD(lParam), (short)HIWORD(lParam));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WM_COMMAND:
|
case WM_COMMAND:
|
||||||
/* FIXME: Implement Cut, Copy, Paste, Delete and Select All */
|
switch(LOWORD(wParam))
|
||||||
|
{
|
||||||
|
case ID_HEXEDIT_CUT:
|
||||||
|
HEXEDIT_Cut(hed);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case ID_HEXEDIT_COPY:
|
||||||
|
HEXEDIT_Copy(hed);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case ID_HEXEDIT_PASTE:
|
||||||
|
HEXEDIT_Paste(hed);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case ID_HEXEDIT_DELETE:
|
||||||
|
HEXEDIT_Delete(hed);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case ID_HEXEDIT_SELECT_ALL:
|
||||||
|
HEXEDIT_SelectAll(hed);
|
||||||
|
break;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Çàïîìíÿíå ñòîéíîñòòà íà êëþ÷à", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Çàïîìíÿíå ñòîéíîñòòà íà êëþ÷à", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -160,6 +160,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "Z&kopírovat název klíèe", ID_EDIT_COPYKEYNAME
|
MENUITEM "Z&kopírovat název klíèe", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "S&chlüsselnamen kopieren", ID_EDIT_COPYKEYNAME
|
MENUITEM "S&chlüsselnamen kopieren", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "&Ausschneiden", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Kopieren", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Einfügen", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Löschen", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "A&lles auswählen", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&ÁíôéãñáöÞ Ïíüìáôïò Êëåéäéïý", ID_EDIT_COPYKEYNAME
|
MENUITEM "&ÁíôéãñáöÞ Ïíüìáôïò Êëåéäéïý", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -160,6 +160,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -165,6 +165,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copiar nombre de clave", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copiar nombre de clave", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -165,6 +165,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copier le nom de la clé", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copier le nom de la clé", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -163,6 +163,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Nama Kunci", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Nama Kunci", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -165,6 +165,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copia il nome della chiave", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copia il nome della chiave", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -160,6 +160,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "キー名のコピー(&C)", ID_EDIT_COPYKEYNAME
|
MENUITEM "キー名のコピー(&C)", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "切り取り(&C)", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "コピー(&C)", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "貼\り付け(&P)", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "削除(&D)", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "すべて選択(&A)", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -147,6 +147,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "키 이름 복사(&C)", ID_EDIT_COPYKEYNAME
|
MENUITEM "키 이름 복사(&C)", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Kopier nøkkelnavn", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Kopier nøkkelnavn", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -167,6 +167,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Kopiuj nazwê klucza", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Kopiuj nazwê klucza", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -163,6 +163,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copiar nome da chave", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copiar nome da chave", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -163,6 +163,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Êîïèðîâàòü èìÿ êëþ÷à", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Êîïèðîâàòü èìÿ êëþ÷à", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -147,6 +147,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -160,6 +160,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Kopiera nyckelnamn", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Kopiera nyckelnamn", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -163,6 +163,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Êîï³þâàòè ³ì'ÿ ðîçä³ëó", ID_EDIT_COPYKEYNAME
|
MENUITEM "&Êîï³þâàòè ³ì'ÿ ðîçä³ëó", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,6 +162,15 @@ BEGIN
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "复制项名称(&C)", ID_EDIT_COPYKEYNAME
|
MENUITEM "复制项名称(&C)", ID_EDIT_COPYKEYNAME
|
||||||
END
|
END
|
||||||
|
POPUP ""
|
||||||
|
BEGIN
|
||||||
|
MENUITEM "C&ut", ID_HEXEDIT_CUT
|
||||||
|
MENUITEM "&Copy", ID_HEXEDIT_COPY
|
||||||
|
MENUITEM "&Paste", ID_HEXEDIT_PASTE
|
||||||
|
MENUITEM "&Delete", ID_HEXEDIT_DELETE
|
||||||
|
MENUITEM SEPARATOR
|
||||||
|
MENUITEM "Select &All", ID_HEXEDIT_SELECT_ALL
|
||||||
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -35,6 +35,7 @@
|
||||||
#define PM_MODIFYVALUE 0
|
#define PM_MODIFYVALUE 0
|
||||||
#define PM_NEW 1
|
#define PM_NEW 1
|
||||||
#define PM_TREECONTEXT 2
|
#define PM_TREECONTEXT 2
|
||||||
|
#define PM_HEXEDIT 3
|
||||||
|
|
||||||
#define MAX_NEW_KEY_LEN 128
|
#define MAX_NEW_KEY_LEN 128
|
||||||
|
|
||||||
|
|
|
@ -108,6 +108,11 @@
|
||||||
#define ID_REGISTRY_PRINTSUBTREE 32832
|
#define ID_REGISTRY_PRINTSUBTREE 32832
|
||||||
#define ID_REGISTRY_PRINTERSETUP 32833
|
#define ID_REGISTRY_PRINTERSETUP 32833
|
||||||
#define ID_REGISTRY_SAVESUBTREEAS 32834
|
#define ID_REGISTRY_SAVESUBTREEAS 32834
|
||||||
|
#define ID_HEXEDIT_CUT 32835
|
||||||
|
#define ID_HEXEDIT_COPY 32836
|
||||||
|
#define ID_HEXEDIT_PASTE 32837
|
||||||
|
#define ID_HEXEDIT_DELETE 32838
|
||||||
|
#define ID_HEXEDIT_SELECT_ALL 32839
|
||||||
#define IDS_LICENSE 32835
|
#define IDS_LICENSE 32835
|
||||||
#define IDS_ERROR 32836
|
#define IDS_ERROR 32836
|
||||||
#define IDS_BAD_VALUE 32837
|
#define IDS_BAD_VALUE 32837
|
||||||
|
@ -203,6 +208,7 @@
|
||||||
#define IDC_LOOKAT_DATA 2016
|
#define IDC_LOOKAT_DATA 2016
|
||||||
#define IDC_MATCHSTRING 2017
|
#define IDC_MATCHSTRING 2017
|
||||||
#define IDC_MATCHCASE 2018
|
#define IDC_MATCHCASE 2018
|
||||||
|
|
||||||
#define IDS_FINISHEDFIND 2019
|
#define IDS_FINISHEDFIND 2019
|
||||||
|
|
||||||
#define ID_FAVORITES_MIN 2100
|
#define ID_FAVORITES_MIN 2100
|
||||||
|
@ -210,4 +216,5 @@
|
||||||
|
|
||||||
#define ID_ACCEL 3000
|
#define ID_ACCEL 3000
|
||||||
|
|
||||||
|
|
||||||
#define IDC_STATIC -1
|
#define IDC_STATIC -1
|
||||||
|
|
|
@ -540,15 +540,16 @@ BOOL CreateNewKey(HWND hwndTV, HTREEITEM hItem)
|
||||||
TCHAR szNewKey[128];
|
TCHAR szNewKey[128];
|
||||||
LPCTSTR pszKeyPath;
|
LPCTSTR pszKeyPath;
|
||||||
int iIndex = 1;
|
int iIndex = 1;
|
||||||
HKEY hRootKey;
|
LONG nResult;
|
||||||
HKEY hKey = NULL;
|
HKEY hRootKey = NULL, hKey = NULL, hNewKey = NULL;
|
||||||
HKEY hNewKey = NULL;
|
|
||||||
BOOL bSuccess = FALSE;
|
BOOL bSuccess = FALSE;
|
||||||
DWORD dwDisposition;
|
DWORD dwDisposition;
|
||||||
HTREEITEM hNewItem;
|
HTREEITEM hNewItem;
|
||||||
|
|
||||||
pszKeyPath = GetItemPath(g_pChildWnd->hTreeWnd, hItem, &hRootKey);
|
pszKeyPath = GetItemPath(hwndTV, hItem, &hRootKey);
|
||||||
if (RegOpenKey(hRootKey, pszKeyPath, &hKey) != ERROR_SUCCESS)
|
if (pszKeyPath[0] == TEXT('\0'))
|
||||||
|
hKey = hRootKey;
|
||||||
|
else if (RegOpenKey(hRootKey, pszKeyPath, &hKey) != ERROR_SUCCESS)
|
||||||
goto done;
|
goto done;
|
||||||
|
|
||||||
if (LoadString(hInst, IDS_NEW_KEY, szNewKeyFormat, sizeof(szNewKeyFormat) / sizeof(szNewKeyFormat[0])) <= 0)
|
if (LoadString(hInst, IDS_NEW_KEY, szNewKeyFormat, sizeof(szNewKeyFormat) / sizeof(szNewKeyFormat[0])) <= 0)
|
||||||
|
@ -557,13 +558,20 @@ BOOL CreateNewKey(HWND hwndTV, HTREEITEM hItem)
|
||||||
/* Need to create a new key with a unique name */
|
/* Need to create a new key with a unique name */
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
_sntprintf(szNewKey, sizeof(szNewKey) / sizeof(szNewKey[0]), szNewKeyFormat, iIndex++);
|
wsprintf(szNewKey, szNewKeyFormat, iIndex++);
|
||||||
RegCreateKeyEx(hKey, szNewKey, 0, NULL, 0, KEY_ALL_ACCESS, NULL, &hNewKey, &dwDisposition);
|
nResult = RegCreateKeyEx(hKey, szNewKey, 0, NULL, 0, KEY_WRITE, NULL, &hNewKey, &dwDisposition);
|
||||||
if (hNewKey && (dwDisposition == REG_OPENED_EXISTING_KEY))
|
if (hNewKey && dwDisposition == REG_OPENED_EXISTING_KEY)
|
||||||
{
|
{
|
||||||
RegCloseKey(hNewKey);
|
RegCloseKey(hNewKey);
|
||||||
hNewKey = NULL;
|
hNewKey = NULL;
|
||||||
}
|
}
|
||||||
|
else if (!hNewKey)
|
||||||
|
{
|
||||||
|
TCHAR sz[256];
|
||||||
|
wsprintf(sz, TEXT("Cannot create new key!\n\nError Code: %d"), nResult);
|
||||||
|
MessageBox(hFrameWnd, sz, NULL, MB_ICONERROR);
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
while(!hNewKey);
|
while(!hNewKey);
|
||||||
|
|
||||||
|
@ -578,7 +586,7 @@ BOOL CreateNewKey(HWND hwndTV, HTREEITEM hItem)
|
||||||
bSuccess = TRUE;
|
bSuccess = TRUE;
|
||||||
|
|
||||||
done:
|
done:
|
||||||
if (hKey)
|
if (hKey != hRootKey && hKey)
|
||||||
RegCloseKey(hKey);
|
RegCloseKey(hKey);
|
||||||
if (hNewKey)
|
if (hNewKey)
|
||||||
RegCloseKey(hNewKey);
|
RegCloseKey(hNewKey);
|
||||||
|
|
|
@ -4,86 +4,265 @@
|
||||||
* FILE: base/system/sc/create.c
|
* FILE: base/system/sc/create.c
|
||||||
* PURPOSE: Create a service
|
* PURPOSE: Create a service
|
||||||
* COPYRIGHT: Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>
|
* COPYRIGHT: Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>
|
||||||
|
* Roel Messiant <roelmessiant@gmail.com>
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "sc.h"
|
#include "sc.h"
|
||||||
|
|
||||||
BOOL Create(LPCTSTR ServiceName, LPCTSTR *ServiceArgs)
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
LPCTSTR lpOption;
|
||||||
|
DWORD dwValue;
|
||||||
|
} OPTION_INFO;
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
LPCTSTR lpServiceName;
|
||||||
|
LPCTSTR lpDisplayName;
|
||||||
|
DWORD dwServiceType;
|
||||||
|
DWORD dwStartType;
|
||||||
|
DWORD dwErrorControl;
|
||||||
|
LPCTSTR lpBinaryPathName;
|
||||||
|
LPCTSTR lpLoadOrderGroup;
|
||||||
|
DWORD dwTagId;
|
||||||
|
LPCTSTR lpDependencies;
|
||||||
|
LPCTSTR lpServiceStartName;
|
||||||
|
LPCTSTR lpPassword;
|
||||||
|
|
||||||
|
BOOL bTagId;
|
||||||
|
} SERVICE_CREATE_INFO, *LPSERVICE_CREATE_INFO;
|
||||||
|
|
||||||
|
|
||||||
|
static const OPTION_INFO TypeOpts[] =
|
||||||
|
{
|
||||||
|
{ _T("own"), SERVICE_WIN32_OWN_PROCESS },
|
||||||
|
{ _T("share"), SERVICE_WIN32_SHARE_PROCESS },
|
||||||
|
{ _T("interact"), SERVICE_INTERACTIVE_PROCESS },
|
||||||
|
{ _T("kernel"), SERVICE_KERNEL_DRIVER },
|
||||||
|
{ _T("filesys"), SERVICE_FILE_SYSTEM_DRIVER },
|
||||||
|
{ _T("rec"), SERVICE_RECOGNIZER_DRIVER }
|
||||||
|
};
|
||||||
|
|
||||||
|
static const OPTION_INFO StartOpts[] =
|
||||||
|
{
|
||||||
|
{ _T("boot"), SERVICE_BOOT_START },
|
||||||
|
{ _T("system"), SERVICE_SYSTEM_START },
|
||||||
|
{ _T("auto"), SERVICE_AUTO_START },
|
||||||
|
{ _T("demand"), SERVICE_DEMAND_START },
|
||||||
|
{ _T("disabled"), SERVICE_DISABLED }
|
||||||
|
};
|
||||||
|
|
||||||
|
static const OPTION_INFO ErrorOpts[] =
|
||||||
|
{
|
||||||
|
{ _T("normal"), SERVICE_ERROR_NORMAL },
|
||||||
|
{ _T("severe"), SERVICE_ERROR_SEVERE },
|
||||||
|
{ _T("critical"), SERVICE_ERROR_CRITICAL },
|
||||||
|
{ _T("ignore"), SERVICE_ERROR_IGNORE }
|
||||||
|
};
|
||||||
|
|
||||||
|
static const OPTION_INFO TagOpts[] =
|
||||||
|
{
|
||||||
|
{ _T("yes"), TRUE },
|
||||||
|
{ _T("no"), FALSE }
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
static BOOL ParseCreateArguments(
|
||||||
|
LPCTSTR *ServiceArgs,
|
||||||
|
INT ArgCount,
|
||||||
|
OUT LPSERVICE_CREATE_INFO lpServiceInfo
|
||||||
|
)
|
||||||
|
{
|
||||||
|
INT i, ArgIndex = 1;
|
||||||
|
|
||||||
|
if (ArgCount < 1)
|
||||||
|
return FALSE;
|
||||||
|
|
||||||
|
ZeroMemory(lpServiceInfo, sizeof(SERVICE_CREATE_INFO));
|
||||||
|
|
||||||
|
lpServiceInfo->lpServiceName = ServiceArgs[0];
|
||||||
|
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
|
while (ArgCount > 1)
|
||||||
|
{
|
||||||
|
if (!lstrcmpi(ServiceArgs[ArgIndex], _T("type=")))
|
||||||
|
{
|
||||||
|
for (i = 0; i < sizeof(TypeOpts) / sizeof(TypeOpts[0]); i++)
|
||||||
|
if (!lstrcmpi(ServiceArgs[ArgIndex + 1], TypeOpts[i].lpOption))
|
||||||
|
{
|
||||||
|
lpServiceInfo->dwServiceType |= TypeOpts[i].dwValue;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i == sizeof(TypeOpts) / sizeof(TypeOpts[0]))
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("start=")))
|
||||||
|
{
|
||||||
|
for (i = 0; i < sizeof(StartOpts) / sizeof(StartOpts[0]); i++)
|
||||||
|
if (!lstrcmpi(ServiceArgs[ArgIndex + 1], StartOpts[i].lpOption))
|
||||||
|
{
|
||||||
|
lpServiceInfo->dwStartType = StartOpts[i].dwValue;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i == sizeof(StartOpts) / sizeof(StartOpts[0]))
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("error=")))
|
||||||
|
{
|
||||||
|
for (i = 0; i < sizeof(ErrorOpts) / sizeof(ErrorOpts[0]); i++)
|
||||||
|
if (!lstrcmpi(ServiceArgs[ArgIndex + 1], ErrorOpts[i].lpOption))
|
||||||
|
{
|
||||||
|
lpServiceInfo->dwErrorControl = ErrorOpts[i].dwValue;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i == sizeof(ErrorOpts) / sizeof(ErrorOpts[0]))
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("tag=")))
|
||||||
|
{
|
||||||
|
for (i = 0; i < sizeof(TagOpts) / sizeof(TagOpts[0]); i++)
|
||||||
|
if (!lstrcmpi(ServiceArgs[ArgIndex + 1], TagOpts[i].lpOption))
|
||||||
|
{
|
||||||
|
lpServiceInfo->bTagId = TagOpts[i].dwValue;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i == sizeof(TagOpts) / sizeof(TagOpts[0]))
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("binpath=")))
|
||||||
|
{
|
||||||
|
lpServiceInfo->lpBinaryPathName = ServiceArgs[ArgIndex + 1];
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("group=")))
|
||||||
|
{
|
||||||
|
lpServiceInfo->lpLoadOrderGroup = ServiceArgs[ArgIndex + 1];
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("depend=")))
|
||||||
|
{
|
||||||
|
lpServiceInfo->lpDependencies = ServiceArgs[ArgIndex + 1];
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("obj=")))
|
||||||
|
{
|
||||||
|
lpServiceInfo->lpServiceStartName = ServiceArgs[ArgIndex + 1];
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("displayname=")))
|
||||||
|
{
|
||||||
|
lpServiceInfo->lpDisplayName = ServiceArgs[ArgIndex + 1];
|
||||||
|
}
|
||||||
|
else if (!lstrcmpi(ServiceArgs[ArgIndex], _T("password=")))
|
||||||
|
{
|
||||||
|
lpServiceInfo->lpPassword = ServiceArgs[ArgIndex + 1];
|
||||||
|
}
|
||||||
|
|
||||||
|
ArgIndex += 2;
|
||||||
|
ArgCount -= 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (ArgCount == 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
BOOL Create(LPCTSTR *ServiceArgs, INT ArgCount)
|
||||||
{
|
{
|
||||||
SC_HANDLE hSCManager;
|
SC_HANDLE hSCManager;
|
||||||
SC_HANDLE hSc;
|
SC_HANDLE hSc;
|
||||||
BOOL bRet = FALSE;
|
BOOL bRet = FALSE;
|
||||||
|
|
||||||
DWORD dwServiceType = SERVICE_WIN32_OWN_PROCESS;
|
INT i;
|
||||||
DWORD dwStartType = SERVICE_DEMAND_START;
|
INT Length;
|
||||||
DWORD dwErrorControl = SERVICE_ERROR_NORMAL;
|
LPTSTR lpBuffer = NULL;
|
||||||
LPCTSTR lpBinaryPathName = NULL;
|
SERVICE_CREATE_INFO ServiceInfo;
|
||||||
LPCTSTR lpLoadOrderGroup = NULL;
|
|
||||||
DWORD dwTagId = 0;
|
|
||||||
LPCTSTR lpDependencies = NULL;
|
|
||||||
LPCTSTR lpServiceStartName = NULL;
|
|
||||||
LPCTSTR lpPassword = NULL;
|
|
||||||
|
|
||||||
/* quick hack to get it working */
|
if (!ParseCreateArguments(ServiceArgs, ArgCount, &ServiceInfo))
|
||||||
lpBinaryPathName = *ServiceArgs;
|
|
||||||
|
|
||||||
#ifdef SCDBG
|
|
||||||
_tprintf(_T("service name - %s\n"), ServiceName);
|
|
||||||
_tprintf(_T("display name - %s\n"), ServiceName);
|
|
||||||
_tprintf(_T("service type - %lu\n"), dwServiceType);
|
|
||||||
_tprintf(_T("start type - %lu\n"), dwStartType);
|
|
||||||
_tprintf(_T("error control - %lu\n"), dwErrorControl);
|
|
||||||
_tprintf(_T("Binary path - %s\n"), lpBinaryPathName);
|
|
||||||
_tprintf(_T("load order group - %s\n"), lpLoadOrderGroup);
|
|
||||||
_tprintf(_T("tag - %lu\n"), dwTagId);
|
|
||||||
_tprintf(_T("dependincies - %s\n"), lpDependencies);
|
|
||||||
_tprintf(_T("account start name - %s\n"), lpServiceStartName);
|
|
||||||
_tprintf(_T("account password - %s\n"), lpPassword);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (!ServiceName)
|
|
||||||
{
|
{
|
||||||
CreateUsage();
|
CreateUsage();
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
hSCManager = OpenSCManager(NULL,
|
if (!ServiceInfo.dwServiceType)
|
||||||
NULL,
|
ServiceInfo.dwServiceType = SERVICE_WIN32_OWN_PROCESS;
|
||||||
SC_MANAGER_CREATE_SERVICE);
|
|
||||||
if (hSCManager == NULL)
|
if (!ServiceInfo.dwStartType)
|
||||||
|
ServiceInfo.dwStartType = SERVICE_DEMAND_START;
|
||||||
|
|
||||||
|
if (!ServiceInfo.dwErrorControl)
|
||||||
|
ServiceInfo.dwErrorControl = SERVICE_ERROR_NORMAL;
|
||||||
|
|
||||||
|
if (ServiceInfo.lpDependencies)
|
||||||
{
|
{
|
||||||
ReportLastError();
|
Length = lstrlen(ServiceInfo.lpDependencies);
|
||||||
return FALSE;
|
|
||||||
|
lpBuffer = HeapAlloc(GetProcessHeap(),
|
||||||
|
0,
|
||||||
|
(Length + 2) * sizeof(TCHAR));
|
||||||
|
|
||||||
|
for (i = 0; i < Length; i++)
|
||||||
|
if (ServiceInfo.lpDependencies[i] == _T('/'))
|
||||||
|
lpBuffer[i] = 0;
|
||||||
|
else
|
||||||
|
lpBuffer[i] = ServiceInfo.lpDependencies[i];
|
||||||
|
|
||||||
|
lpBuffer[Length] = 0;
|
||||||
|
lpBuffer[Length + 1] = 0;
|
||||||
|
|
||||||
|
ServiceInfo.lpDependencies = lpBuffer;
|
||||||
}
|
}
|
||||||
|
|
||||||
hSc = CreateService(hSCManager,
|
#ifdef SCDBG
|
||||||
ServiceName,
|
_tprintf(_T("service name - %s\n"), ServiceInfo.lpServiceName);
|
||||||
ServiceName,
|
_tprintf(_T("display name - %s\n"), ServiceInfo.lpDisplayName);
|
||||||
SERVICE_ALL_ACCESS,
|
_tprintf(_T("service type - %lu\n"), ServiceInfo.dwServiceType);
|
||||||
dwServiceType,
|
_tprintf(_T("start type - %lu\n"), ServiceInfo.dwStartType);
|
||||||
dwStartType,
|
_tprintf(_T("error control - %lu\n"), ServiceInfo.dwErrorControl);
|
||||||
dwErrorControl,
|
_tprintf(_T("Binary path - %s\n"), ServiceInfo.lpBinaryPathName);
|
||||||
lpBinaryPathName,
|
_tprintf(_T("load order group - %s\n"), ServiceInfo.lpLoadOrderGroup);
|
||||||
lpLoadOrderGroup,
|
_tprintf(_T("tag - %lu\n"), ServiceInfo.dwTagId);
|
||||||
&dwTagId,
|
_tprintf(_T("dependencies - %s\n"), ServiceInfo.lpDependencies);
|
||||||
lpDependencies,
|
_tprintf(_T("account start name - %s\n"), ServiceInfo.lpServiceStartName);
|
||||||
lpServiceStartName,
|
_tprintf(_T("account password - %s\n"), ServiceInfo.lpPassword);
|
||||||
lpPassword);
|
#endif
|
||||||
|
|
||||||
if (hSc == NULL)
|
hSCManager = OpenSCManager(NULL, NULL, SC_MANAGER_CREATE_SERVICE);
|
||||||
|
|
||||||
|
if (hSCManager != NULL)
|
||||||
{
|
{
|
||||||
ReportLastError();
|
hSc = CreateService(hSCManager,
|
||||||
|
ServiceInfo.lpServiceName,
|
||||||
|
ServiceInfo.lpDisplayName,
|
||||||
|
SERVICE_ALL_ACCESS,
|
||||||
|
ServiceInfo.dwServiceType,
|
||||||
|
ServiceInfo.dwStartType,
|
||||||
|
ServiceInfo.dwErrorControl,
|
||||||
|
ServiceInfo.lpBinaryPathName,
|
||||||
|
ServiceInfo.lpLoadOrderGroup,
|
||||||
|
ServiceInfo.bTagId ? &ServiceInfo.dwTagId : NULL,
|
||||||
|
ServiceInfo.lpDependencies,
|
||||||
|
ServiceInfo.lpServiceStartName,
|
||||||
|
ServiceInfo.lpPassword);
|
||||||
|
|
||||||
|
if (hSc != NULL)
|
||||||
|
{
|
||||||
|
_tprintf(_T("[SC] CreateService SUCCESS\n"));
|
||||||
|
|
||||||
|
CloseServiceHandle(hSc);
|
||||||
|
bRet = TRUE;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
ReportLastError();
|
||||||
|
|
||||||
CloseServiceHandle(hSCManager);
|
CloseServiceHandle(hSCManager);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
ReportLastError();
|
||||||
_tprintf(_T("[SC] CreateService SUCCESS\n"));
|
|
||||||
|
|
||||||
CloseServiceHandle(hSc);
|
if (lpBuffer != NULL)
|
||||||
CloseServiceHandle(hSCManager);
|
HeapFree(GetProcessHeap(), 0, lpBuffer);
|
||||||
bRet = TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return bRet;
|
return bRet;
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,11 +67,11 @@ ScControl(LPCTSTR Server, // remote machine name
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("start")))
|
else if (!lstrcmpi(Command, _T("start")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 0)
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
{
|
{
|
||||||
|
ServiceName = *ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
Start(ServiceName,
|
Start(ServiceName,
|
||||||
ServiceArgs,
|
ServiceArgs,
|
||||||
ArgCount);
|
ArgCount);
|
||||||
|
@ -81,11 +81,11 @@ ScControl(LPCTSTR Server, // remote machine name
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("pause")))
|
else if (!lstrcmpi(Command, _T("pause")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 0)
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
{
|
{
|
||||||
|
ServiceName = *ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
Control(SERVICE_CONTROL_PAUSE,
|
Control(SERVICE_CONTROL_PAUSE,
|
||||||
ServiceName,
|
ServiceName,
|
||||||
ServiceArgs,
|
ServiceArgs,
|
||||||
|
@ -96,11 +96,11 @@ ScControl(LPCTSTR Server, // remote machine name
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("interrogate")))
|
else if (!lstrcmpi(Command, _T("interrogate")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 0)
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
{
|
{
|
||||||
|
ServiceName = *ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
Control(SERVICE_CONTROL_INTERROGATE,
|
Control(SERVICE_CONTROL_INTERROGATE,
|
||||||
ServiceName,
|
ServiceName,
|
||||||
ServiceArgs,
|
ServiceArgs,
|
||||||
|
@ -111,11 +111,11 @@ ScControl(LPCTSTR Server, // remote machine name
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("stop")))
|
else if (!lstrcmpi(Command, _T("stop")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 0)
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
{
|
{
|
||||||
|
ServiceName = *ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
Control(SERVICE_CONTROL_STOP,
|
Control(SERVICE_CONTROL_STOP,
|
||||||
ServiceName,
|
ServiceName,
|
||||||
ServiceArgs,
|
ServiceArgs,
|
||||||
|
@ -126,11 +126,11 @@ ScControl(LPCTSTR Server, // remote machine name
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("continue")))
|
else if (!lstrcmpi(Command, _T("continue")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 0)
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
{
|
{
|
||||||
|
ServiceName = *ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
Control(SERVICE_CONTROL_CONTINUE,
|
Control(SERVICE_CONTROL_CONTINUE,
|
||||||
ServiceName,
|
ServiceName,
|
||||||
ServiceArgs,
|
ServiceArgs,
|
||||||
|
@ -141,51 +141,49 @@ ScControl(LPCTSTR Server, // remote machine name
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("delete")))
|
else if (!lstrcmpi(Command, _T("delete")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 0)
|
||||||
ArgCount--;
|
{
|
||||||
|
ServiceName = *ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
Delete(ServiceName);
|
Delete(ServiceName);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
DeleteUsage();
|
DeleteUsage();
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("create")))
|
else if (!lstrcmpi(Command, _T("create")))
|
||||||
{
|
{
|
||||||
ServiceName = *ServiceArgs++;
|
Create(ServiceArgs, ArgCount);
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (*ServiceArgs)
|
|
||||||
Create(ServiceName,
|
|
||||||
ServiceArgs);
|
|
||||||
else
|
|
||||||
CreateUsage();
|
|
||||||
}
|
}
|
||||||
else if (!lstrcmpi(Command, _T("control")))
|
else if (!lstrcmpi(Command, _T("control")))
|
||||||
{
|
{
|
||||||
INT CtlValue;
|
INT CtlValue;
|
||||||
|
|
||||||
ServiceName = *ServiceArgs++;
|
if (ArgCount > 1)
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
CtlValue = _ttoi(ServiceArgs[0]);
|
|
||||||
ServiceArgs++;
|
|
||||||
ArgCount--;
|
|
||||||
|
|
||||||
if (ServiceName)
|
|
||||||
{
|
{
|
||||||
if ((CtlValue >=128) && CtlValue <= 255)
|
ServiceName = *ServiceArgs++;
|
||||||
{
|
ArgCount--;
|
||||||
|
|
||||||
|
CtlValue = _ttoi(ServiceArgs[0]);
|
||||||
|
ServiceArgs++;
|
||||||
|
ArgCount--;
|
||||||
|
|
||||||
|
if ((CtlValue >= 128) && (CtlValue <= 255))
|
||||||
Control(CtlValue,
|
Control(CtlValue,
|
||||||
ServiceName,
|
ServiceName,
|
||||||
ServiceArgs,
|
ServiceArgs,
|
||||||
ArgCount);
|
ArgCount);
|
||||||
|
else
|
||||||
return 0;
|
ControlUsage();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
else
|
||||||
ContinueUsage();
|
ControlUsage();
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
MainUsage();
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
|
|
||||||
/* control functions */
|
/* control functions */
|
||||||
BOOL Start(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, INT ArgCount);
|
BOOL Start(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, INT ArgCount);
|
||||||
BOOL Create(LPCTSTR ServiceName, LPCTSTR *ServiceArgs);
|
BOOL Create(LPCTSTR *ServiceArgs, INT ArgCount);
|
||||||
BOOL Delete(LPCTSTR ServiceName);
|
BOOL Delete(LPCTSTR ServiceName);
|
||||||
BOOL Control(DWORD Control, LPCTSTR ServiceName, LPCTSTR *Args, INT ArgCount);
|
BOOL Control(DWORD Control, LPCTSTR ServiceName, LPCTSTR *Args, INT ArgCount);
|
||||||
BOOL Query(LPCTSTR *ServiceArgs, DWORD ArgCount, BOOL bExtended);
|
BOOL Query(LPCTSTR *ServiceArgs, DWORD ArgCount, BOOL bExtended);
|
||||||
|
@ -29,3 +29,4 @@ VOID ConfigUsage(VOID);
|
||||||
VOID DescriptionUsage(VOID);
|
VOID DescriptionUsage(VOID);
|
||||||
VOID DeleteUsage(VOID);
|
VOID DeleteUsage(VOID);
|
||||||
VOID CreateUsage(VOID);
|
VOID CreateUsage(VOID);
|
||||||
|
VOID ControlUsage(VOID);
|
||||||
|
|
|
@ -118,7 +118,7 @@ VOID InterrogateUsage(VOID)
|
||||||
VOID StopUsage(VOID)
|
VOID StopUsage(VOID)
|
||||||
{
|
{
|
||||||
_tprintf(_T("DESCRIPTION:\n")
|
_tprintf(_T("DESCRIPTION:\n")
|
||||||
_T(" Sends an STOP control request to a service.\n")
|
_T(" Sends a STOP control request to a service.\n")
|
||||||
_T("USAGE:\n")
|
_T("USAGE:\n")
|
||||||
_T(" sc <server> stop [service name]\n"));
|
_T(" sc <server> stop [service name]\n"));
|
||||||
}
|
}
|
||||||
|
@ -126,7 +126,7 @@ VOID StopUsage(VOID)
|
||||||
VOID ContinueUsage(VOID)
|
VOID ContinueUsage(VOID)
|
||||||
{
|
{
|
||||||
_tprintf(_T("DESCRIPTION:\n")
|
_tprintf(_T("DESCRIPTION:\n")
|
||||||
_T(" Sends an CONTINUE control request to a service.\n")
|
_T(" Sends a CONTINUE control request to a service.\n")
|
||||||
_T("USAGE:\n")
|
_T("USAGE:\n")
|
||||||
_T(" sc <server> continue [service name]\n"));
|
_T(" sc <server> continue [service name]\n"));
|
||||||
}
|
}
|
||||||
|
@ -179,3 +179,11 @@ VOID CreateUsage(VOID)
|
||||||
_T(" DisplayName= <display name>\n")
|
_T(" DisplayName= <display name>\n")
|
||||||
_T(" password= <password>\n"));
|
_T(" password= <password>\n"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
VOID ControlUsage(VOID)
|
||||||
|
{
|
||||||
|
_tprintf(_T("DESCRIPTION:\n")
|
||||||
|
_T(" Sends a CONTROL control request to a service.\n")
|
||||||
|
_T("USAGE:\n")
|
||||||
|
_T(" sc <server> control [service name] <value>\n"));
|
||||||
|
}
|
||||||
|
|
|
@ -38,7 +38,6 @@ HWND hApplicationPageSwitchToButton; /* Application Switch To button
|
||||||
HWND hApplicationPageNewTaskButton; /* Application New Task button */
|
HWND hApplicationPageNewTaskButton; /* Application New Task button */
|
||||||
static int nApplicationPageWidth;
|
static int nApplicationPageWidth;
|
||||||
static int nApplicationPageHeight;
|
static int nApplicationPageHeight;
|
||||||
static HANDLE hApplicationPageEvent = NULL; /* When this event becomes signaled then we refresh the app list */
|
|
||||||
static BOOL bSortAscending = TRUE;
|
static BOOL bSortAscending = TRUE;
|
||||||
DWORD WINAPI ApplicationPageRefreshThread(void *lpParameter);
|
DWORD WINAPI ApplicationPageRefreshThread(void *lpParameter);
|
||||||
BOOL noApps;
|
BOOL noApps;
|
||||||
|
@ -51,6 +50,11 @@ void ApplicationPageShowContextMenu2(void);
|
||||||
int CALLBACK ApplicationPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
|
int CALLBACK ApplicationPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
|
||||||
int ProcGetIndexByProcessId(DWORD dwProcessId);
|
int ProcGetIndexByProcessId(DWORD dwProcessId);
|
||||||
|
|
||||||
|
#ifdef RUN_APPS_PAGE
|
||||||
|
static HANDLE hApplicationThread = NULL;
|
||||||
|
static DWORD dwApplicationThread;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
void SwitchToThisWindow (
|
void SwitchToThisWindow (
|
||||||
HWND hWnd, /* Handle to the window that should be activated */
|
HWND hWnd, /* Handle to the window that should be activated */
|
||||||
|
@ -92,7 +96,6 @@ ApplicationPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
LV_COLUMN column;
|
LV_COLUMN column;
|
||||||
WCHAR szTemp[256];
|
WCHAR szTemp[256];
|
||||||
int cx, cy;
|
int cx, cy;
|
||||||
HANDLE hRefreshThread = NULL;
|
|
||||||
|
|
||||||
switch (message) {
|
switch (message) {
|
||||||
case WM_INITDIALOG:
|
case WM_INITDIALOG:
|
||||||
|
@ -132,15 +135,16 @@ ApplicationPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
UpdateApplicationListControlViewSetting();
|
UpdateApplicationListControlViewSetting();
|
||||||
|
|
||||||
/* Start our refresh thread */
|
/* Start our refresh thread */
|
||||||
hRefreshThread = CreateThread(NULL, 0, ApplicationPageRefreshThread, NULL, 0, NULL);
|
#ifdef RUN_APPS_PAGE
|
||||||
|
hApplicationThread = CreateThread(NULL, 0, ApplicationPageRefreshThread, NULL, 0, &dwApplicationThread);
|
||||||
|
#endif
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
case WM_DESTROY:
|
case WM_DESTROY:
|
||||||
/* Close the event handle, this will make the */
|
/* Close refresh thread */
|
||||||
/* refresh thread exit when the wait fails */
|
#ifdef RUN_APPS_PAGE
|
||||||
CloseHandle(hApplicationPageEvent);
|
EndLocalThread(&hApplicationThread, dwApplicationThread);
|
||||||
CloseHandle(hRefreshThread);
|
#endif
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WM_COMMAND:
|
case WM_COMMAND:
|
||||||
|
@ -213,9 +217,11 @@ ApplicationPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
|
|
||||||
void RefreshApplicationPage(void)
|
void RefreshApplicationPage(void)
|
||||||
{
|
{
|
||||||
|
#ifdef RUN_APPS_PAGE
|
||||||
/* Signal the event so that our refresh thread */
|
/* Signal the event so that our refresh thread */
|
||||||
/* will wake up and refresh the application page */
|
/* will wake up and refresh the application page */
|
||||||
SetEvent(hApplicationPageEvent);
|
PostThreadMessage(dwApplicationThread, WM_TIMER, 0, 0);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void UpdateApplicationListControlViewSetting(void)
|
void UpdateApplicationListControlViewSetting(void)
|
||||||
|
@ -236,6 +242,7 @@ void UpdateApplicationListControlViewSetting(void)
|
||||||
|
|
||||||
DWORD WINAPI ApplicationPageRefreshThread(void *lpParameter)
|
DWORD WINAPI ApplicationPageRefreshThread(void *lpParameter)
|
||||||
{
|
{
|
||||||
|
MSG msg;
|
||||||
INT i;
|
INT i;
|
||||||
BOOL bItemRemoved = FALSE;
|
BOOL bItemRemoved = FALSE;
|
||||||
LV_ITEM item;
|
LV_ITEM item;
|
||||||
|
@ -243,30 +250,15 @@ DWORD WINAPI ApplicationPageRefreshThread(void *lpParameter)
|
||||||
HIMAGELIST hImageListLarge;
|
HIMAGELIST hImageListLarge;
|
||||||
HIMAGELIST hImageListSmall;
|
HIMAGELIST hImageListSmall;
|
||||||
|
|
||||||
/* Create the event */
|
|
||||||
hApplicationPageEvent = CreateEventW(NULL, TRUE, TRUE, NULL);
|
|
||||||
|
|
||||||
/* If we couldn't create the event then exit the thread */
|
/* If we couldn't create the event then exit the thread */
|
||||||
if (!hApplicationPageEvent)
|
|
||||||
return 0;
|
|
||||||
|
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
DWORD dwWaitVal;
|
/* Wait for an the event or application close */
|
||||||
|
if (GetMessage(&msg, NULL, 0, 0) <= 0)
|
||||||
/* Wait on the event */
|
|
||||||
dwWaitVal = WaitForSingleObject(hApplicationPageEvent, INFINITE);
|
|
||||||
|
|
||||||
/* If the wait failed then the event object must have been */
|
|
||||||
/* closed and the task manager is exiting so exit this thread */
|
|
||||||
if (dwWaitVal == WAIT_FAILED)
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (dwWaitVal == WAIT_OBJECT_0)
|
if (msg.message == WM_TIMER)
|
||||||
{
|
{
|
||||||
/* Reset our event */
|
|
||||||
ResetEvent(hApplicationPageEvent);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* FIXME:
|
* FIXME:
|
||||||
*
|
*
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* debug.cpp
|
* debug.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
||||||
* 2005 Klemens Friedl <frik85@reactos.at>
|
* 2005 Klemens Friedl <frik85@reactos.at>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* endproc.cpp
|
* endproc.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
||||||
* 2005 Klemens Friedl <frik85@reactos.at>
|
* 2005 Klemens Friedl <frik85@reactos.at>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* graph.cpp
|
* graph.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
||||||
*
|
*
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* GraphCtrl.cpp
|
* graphctl.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2002 Robert Dickenson <robd@reactos.org>
|
* Copyright (C) 2002 Robert Dickenson <robd@reactos.org>
|
||||||
*
|
*
|
||||||
|
@ -425,7 +425,7 @@ void GraphCtrl_DrawPoint(TGraphCtrl* this)
|
||||||
* note: the m_dcPlot covers the entire client
|
* note: the m_dcPlot covers the entire client
|
||||||
* but we only shift bitmap that is the size
|
* but we only shift bitmap that is the size
|
||||||
* of the plot rectangle
|
* of the plot rectangle
|
||||||
* grab the right side of the plot (exluding m_nShiftPixels on the left)
|
* grab the right side of the plot (excluding m_nShiftPixels on the left)
|
||||||
* move this grabbed bitmap to the left by m_nShiftPixels
|
* move this grabbed bitmap to the left by m_nShiftPixels
|
||||||
*/
|
*/
|
||||||
BitBlt(this->m_dcPlot, this->m_rectPlot.left, this->m_rectPlot.top+1,
|
BitBlt(this->m_dcPlot, this->m_rectPlot.left, this->m_rectPlot.top+1,
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* GraphCtrl.h
|
* graphctl.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2002 Robert Dickenson <robd@reactos.org>
|
* Copyright (C) 2002 Robert Dickenson <robd@reactos.org>
|
||||||
*
|
*
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -159,6 +159,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -45,67 +45,54 @@ BEGIN
|
||||||
|
|
||||||
END
|
END
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "Iconos &Grandes", ID_VIEW_LARGE
|
MENUITEM "Iconos &Grandes", ID_VIEW_LARGE
|
||||||
MENUITEM "Iconos &Pequeños", ID_VIEW_SMALL
|
MENUITEM "Iconos &Pequeños", ID_VIEW_SMALL
|
||||||
MENUITEM "&Detalles", ID_VIEW_DETAILS,
|
MENUITEM "&Detalles", ID_VIEW_DETAILS, CHECKED
|
||||||
CHECKED
|
MENUITEM "&Seleccionar Columnas...", ID_VIEW_SELECTCOLUMNS
|
||||||
MENUITEM "&Seleccionar Columnas...",
|
|
||||||
ID_VIEW_SELECTCOLUMNS
|
|
||||||
POPUP "Historial de la &CPU"
|
POPUP "Historial de la &CPU"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "&Una Gráfica, Todas las CPUs",
|
MENUITEM "&Una Gráfica, Todas las CPUs", ID_VIEW_CPUHISTORY_ONEGRAPHALL
|
||||||
ID_VIEW_CPUHISTORY_ONEGRAPHALL
|
|
||||||
|
|
||||||
MENUITEM "Una Gráfica, &Por CPU",
|
MENUITEM "Una Gráfica, &Por CPU", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU, CHECKED
|
||||||
ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU
|
|
||||||
, CHECKED
|
|
||||||
END
|
END
|
||||||
MENUITEM "&Mostrar tiempos del Núcleo",
|
MENUITEM "&Mostrar tiempos del Núcleo", ID_VIEW_SHOWKERNELTIMES
|
||||||
ID_VIEW_SHOWKERNELTIMES
|
|
||||||
END
|
END
|
||||||
POPUP "&Ventanas"
|
POPUP "&Ventanas"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "Mosaico &Horizontal",
|
MENUITEM "Mosaico &Horizontal", ID_WINDOWS_TILEHORIZONTALLY
|
||||||
ID_WINDOWS_TILEHORIZONTALLY
|
MENUITEM "Mosaico &Vertical", ID_WINDOWS_TILEVERTICALLY
|
||||||
MENUITEM "Mosaico &Vertical",
|
MENUITEM "&Minimizar", ID_WINDOWS_MINIMIZE
|
||||||
ID_WINDOWS_TILEVERTICALLY
|
MENUITEM "Ma&ximizar", ID_WINDOWS_MAXIMIZE
|
||||||
MENUITEM "&Minimizar", ID_WINDOWS_MINIMIZE
|
MENUITEM "&Cascada", ID_WINDOWS_CASCADE
|
||||||
MENUITEM "Ma&ximizar", ID_WINDOWS_MAXIMIZE
|
MENUITEM "&Traer al Frente", ID_WINDOWS_BRINGTOFRONT
|
||||||
MENUITEM "&Cascada", ID_WINDOWS_CASCADE
|
|
||||||
MENUITEM "&Traer al Frente",
|
|
||||||
ID_WINDOWS_BRINGTOFRONT
|
|
||||||
END
|
END
|
||||||
POPUP "A&yuda"
|
POPUP "A&yuda"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "&Temas de Ayuda del Administrador de Tareas",
|
MENUITEM "&Temas de Ayuda del Administrador de Tareas", ID_HELP_TOPICS
|
||||||
ID_HELP_TOPICS
|
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Acerca del Administrador de Tareas",
|
MENUITEM "&Acerca del Administrador de Tareas", ID_HELP_ABOUT
|
||||||
ID_HELP_ABOUT
|
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
IDR_WINDOWSMENU MENU DISCARDABLE
|
IDR_WINDOWSMENU MENU DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "Mosaico &Horizontal",
|
MENUITEM "Mosaico &Horizontal", ID_WINDOWS_TILEHORIZONTALLY
|
||||||
ID_WINDOWS_TILEHORIZONTALLY
|
MENUITEM "Mosaico &Vertical", ID_WINDOWS_TILEVERTICALLY
|
||||||
MENUITEM "Mosaico &Vertical", ID_WINDOWS_TILEVERTICALLY
|
MENUITEM "&Minimizar", ID_WINDOWS_MINIMIZE
|
||||||
MENUITEM "&Minimizar", ID_WINDOWS_MINIMIZE
|
MENUITEM "Ma&ximizar", ID_WINDOWS_MAXIMIZE
|
||||||
MENUITEM "Ma&ximizar", ID_WINDOWS_MAXIMIZE
|
|
||||||
MENUITEM "&Cascada", ID_WINDOWS_CASCADE
|
MENUITEM "&Cascada", ID_WINDOWS_CASCADE
|
||||||
MENUITEM "&Traer al Frente", ID_WINDOWS_BRINGTOFRONT
|
MENUITEM "&Traer al Frente", ID_WINDOWS_BRINGTOFRONT
|
||||||
END
|
END
|
||||||
|
|
||||||
IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE
|
IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
POPUP "DUMMY"
|
POPUP "DUMMY"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "&Nueva Tarea (Ejecutar...)", ID_FILE_NEW
|
MENUITEM "&Nueva Tarea (Ejecutar...)", ID_FILE_NEW
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "Iconos &Grandes", ID_VIEW_LARGE
|
MENUITEM "Iconos &Grandes", ID_VIEW_LARGE
|
||||||
MENUITEM "Iconos &Pequeños", ID_VIEW_SMALL
|
MENUITEM "Iconos &Pequeños", ID_VIEW_SMALL
|
||||||
MENUITEM "&Detalles", ID_VIEW_DETAILS,
|
MENUITEM "&Detalles", ID_VIEW_DETAILS, CHECKED
|
||||||
CHECKED
|
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
@ -113,21 +100,17 @@ IDR_APPLICATION_PAGE_CONTEXT2 MENU DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
POPUP "DUMMY"
|
POPUP "DUMMY"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "&Cambiar A",
|
MENUITEM "&Cambiar A", ID_APPLICATION_PAGE_SWITCHTO
|
||||||
ID_APPLICATION_PAGE_SWITCHTO
|
MENUITEM "&Traer al Frente", ID_WINDOWS_BRINGTOFRONT
|
||||||
MENUITEM "&Traer al Frente",
|
|
||||||
ID_WINDOWS_BRINGTOFRONT
|
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "Mosaico &Horizontal",
|
MENUITEM "Mosaico &Horizontal", ID_WINDOWS_TILEHORIZONTALLY
|
||||||
ID_WINDOWS_TILEHORIZONTALLY
|
MENUITEM "Mosaico &Vertical", ID_WINDOWS_TILEVERTICALLY
|
||||||
MENUITEM "Mosaico &Vertical",
|
MENUITEM "&Minimizar", ID_WINDOWS_MINIMIZE
|
||||||
ID_WINDOWS_TILEVERTICALLY
|
MENUITEM "Ma&ximizar", ID_WINDOWS_MAXIMIZE
|
||||||
MENUITEM "&Minimizar", ID_WINDOWS_MINIMIZE
|
MENUITEM "Ca&scada", ID_WINDOWS_CASCADE
|
||||||
MENUITEM "Ma&ximizar", ID_WINDOWS_MAXIMIZE
|
|
||||||
MENUITEM "Ca&scada", ID_WINDOWS_CASCADE
|
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Finalizar Tarea", ID_APPLICATION_PAGE_ENDTASK
|
MENUITEM "&Finalizar Tarea", ID_APPLICATION_PAGE_ENDTASK
|
||||||
MENUITEM "&Ir al Proceso", ID_APPLICATION_PAGE_GOTOPROCESS
|
MENUITEM "&Ir al Proceso", ID_APPLICATION_PAGE_GOTOPROCESS
|
||||||
|
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
@ -136,10 +119,10 @@ IDR_TRAY_POPUP MENU DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
POPUP "DUMMY"
|
POPUP "DUMMY"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "&Restaurar", ID_RESTORE
|
MENUITEM "&Restaurar", ID_RESTORE
|
||||||
MENUITEM "&Cerrar", ID_FILE_EXIT
|
MENUITEM "&Cerrar", ID_FILE_EXIT
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "&Siempre Visible", ID_OPTIONS_ALWAYSONTOP
|
MENUITEM "&Siempre Visible", ID_OPTIONS_ALWAYSONTOP
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
|
||||||
|
@ -147,27 +130,27 @@ IDR_PROCESS_PAGE_CONTEXT MENU DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
POPUP "DUMMY"
|
POPUP "DUMMY"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "&Finalizar Proceso", ID_PROCESS_PAGE_ENDPROCESS
|
MENUITEM "&Finalizar Proceso", ID_PROCESS_PAGE_ENDPROCESS
|
||||||
MENUITEM "Finalizar &Árbol de Procesos", ID_PROCESS_PAGE_ENDPROCESSTREE
|
MENUITEM "Finalizar &Árbol de Procesos", ID_PROCESS_PAGE_ENDPROCESSTREE
|
||||||
|
|
||||||
MENUITEM "&Depurador", ID_PROCESS_PAGE_DEBUG
|
MENUITEM "&Depurador", ID_PROCESS_PAGE_DEBUG
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
POPUP "Establecer &Prioridad"
|
POPUP "Establecer &Prioridad"
|
||||||
BEGIN
|
BEGIN
|
||||||
MENUITEM "Tiempo-&Real", ID_PROCESS_PAGE_SETPRIORITY_REALTIME
|
MENUITEM "Tiempo-&Real", ID_PROCESS_PAGE_SETPRIORITY_REALTIME
|
||||||
|
|
||||||
MENUITEM "&Alta", ID_PROCESS_PAGE_SETPRIORITY_HIGH
|
MENUITEM "&Alta", ID_PROCESS_PAGE_SETPRIORITY_HIGH
|
||||||
|
|
||||||
MENUITEM "Arr&iba de lo Normal", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL
|
MENUITEM "Arr&iba de lo Normal", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL
|
||||||
|
|
||||||
MENUITEM "&Normal", ID_PROCESS_PAGE_SETPRIORITY_NORMAL
|
MENUITEM "&Normal", ID_PROCESS_PAGE_SETPRIORITY_NORMAL
|
||||||
|
|
||||||
MENUITEM "&Debajo de lo Normal", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL
|
MENUITEM "&Debajo de lo Normal", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL
|
||||||
|
|
||||||
MENUITEM "&Baja", ID_PROCESS_PAGE_SETPRIORITY_LOW
|
MENUITEM "&Baja", ID_PROCESS_PAGE_SETPRIORITY_LOW
|
||||||
|
|
||||||
END
|
END
|
||||||
MENUITEM "Establecer &Afinidad...", ID_PROCESS_PAGE_SETAFFINITY
|
MENUITEM "Establecer &Afinidad...", ID_PROCESS_PAGE_SETAFFINITY
|
||||||
MENUITEM "Editar &Canales de Depuración...", ID_PROCESS_PAGE_DEBUGCHANNELS
|
MENUITEM "Editar &Canales de Depuración...", ID_PROCESS_PAGE_DEBUGCHANNELS
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
@ -177,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
@ -186,8 +170,7 @@ CAPTION "Administrador de Tareas"
|
||||||
MENU IDR_TASKMANAGER
|
MENU IDR_TASKMANAGER
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
CONTROL
|
CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,3,3,257,228
|
||||||
"Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,3,3,257,228
|
|
||||||
END
|
END
|
||||||
|
|
||||||
IDD_APPLICATION_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210
|
IDD_APPLICATION_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210
|
||||||
|
@ -195,8 +178,7 @@ STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
CONTROL "List2",IDC_APPLIST,"SysListView32",LVS_REPORT |
|
CONTROL "List2",IDC_APPLIST,"SysListView32",LVS_REPORT |
|
||||||
LVS_SHOWSELALWAYS | WS_BORDER |
|
LVS_SHOWSELALWAYS | WS_BORDER |WS_TABSTOP,7,7,233,177
|
||||||
WS_TABSTOP,7,7,233,177
|
|
||||||
PUSHBUTTON "&Nueva Tarea...",IDC_NEWTASK,187,189,53,14
|
PUSHBUTTON "&Nueva Tarea...",IDC_NEWTASK,187,189,53,14
|
||||||
PUSHBUTTON "&Cambiar A",IDC_SWITCHTO,131,189,53,14,WS_DISABLED
|
PUSHBUTTON "&Cambiar A",IDC_SWITCHTO,131,189,53,14,WS_DISABLED
|
||||||
PUSHBUTTON "&Finalizar Tarea",IDC_ENDTASK,75,189,53,14,WS_DISABLED
|
PUSHBUTTON "&Finalizar Tarea",IDC_ENDTASK,75,189,53,14,WS_DISABLED
|
||||||
|
@ -206,8 +188,7 @@ IDD_PROCESS_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210
|
||||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
CONTROL "List2",IDC_PROCESSLIST,"SysListView32",LVS_REPORT
|
CONTROL "List2",IDC_PROCESSLIST,"SysListView32",LVS_REPORT |
|
||||||
|
|
|
||||||
LVS_SINGLESEL | LVS_SHOWSELALWAYS |
|
LVS_SINGLESEL | LVS_SHOWSELALWAYS |
|
||||||
WS_BORDER | WS_TABSTOP,7,7,233,177
|
WS_BORDER | WS_TABSTOP,7,7,233,177
|
||||||
PUSHBUTTON "&Finalizar Proceso",IDC_ENDPROCESS,171,189,69,14
|
PUSHBUTTON "&Finalizar Proceso",IDC_ENDPROCESS,171,189,69,14
|
||||||
|
@ -251,8 +232,7 @@ BEGIN
|
||||||
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
||||||
EDITTEXT IDC_PHYSICAL_MEMORY_AVAILABLE,185,140,48,8,ES_RIGHT |
|
EDITTEXT IDC_PHYSICAL_MEMORY_AVAILABLE,185,140,48,8,ES_RIGHT |
|
||||||
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
||||||
EDITTEXT
|
EDITTEXT IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT |
|
||||||
IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT |
|
|
||||||
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
||||||
LTEXT "Total",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8
|
LTEXT "Total",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8
|
||||||
LTEXT "Paginado",IDS_KERNEL_MEMORY_PAGED,137,184,30,8
|
LTEXT "Paginado",IDS_KERNEL_MEMORY_PAGED,137,184,30,8
|
||||||
|
@ -265,10 +245,8 @@ IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT |
|
||||||
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
ES_READONLY | ES_NUMBER | NOT WS_BORDER | NOT WS_TABSTOP
|
||||||
GROUPBOX "Historial de uso de la CPU",IDC_CPU_USAGE_HISTORY_FRAME,74,5,168,54,0,WS_EX_TRANSPARENT
|
GROUPBOX "Historial de uso de la CPU",IDC_CPU_USAGE_HISTORY_FRAME,74,5,168,54,0,WS_EX_TRANSPARENT
|
||||||
GROUPBOX "Historial de uso de la Memoria",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT
|
GROUPBOX "Historial de uso de la Memoria",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT
|
||||||
PUSHBUTTON "Display de uso de la CPU",IDC_CPU_USAGE_GRAPH,12,17,47,37,NOT WS_TABSTOP,
|
PUSHBUTTON "Display de uso de la CPU",IDC_CPU_USAGE_GRAPH,12,17,47,37,NOT WS_TABSTOP,WS_EX_CLIENTEDGE
|
||||||
WS_EX_CLIENTEDGE
|
PUSHBUTTON "Display de uso de la Memoria",IDC_MEM_USAGE_GRAPH,12,75,47,37,NOT WS_TABSTOP,WS_EX_CLIENTEDGE
|
||||||
PUSHBUTTON "Display de uso de la Memoria",IDC_MEM_USAGE_GRAPH,12,75,47,37,NOT WS_TABSTOP,
|
|
||||||
WS_EX_CLIENTEDGE
|
|
||||||
PUSHBUTTON "Historial de uso de la CPU",IDC_CPU_USAGE_HISTORY_GRAPH,81,17,
|
PUSHBUTTON "Historial de uso de la CPU",IDC_CPU_USAGE_HISTORY_GRAPH,81,17,
|
||||||
153,37,NOT WS_TABSTOP,WS_EX_CLIENTEDGE
|
153,37,NOT WS_TABSTOP,WS_EX_CLIENTEDGE
|
||||||
PUSHBUTTON "Historial de uso de la Memoria",IDC_MEM_USAGE_HISTORY_GRAPH,81,75,
|
PUSHBUTTON "Historial de uso de la Memoria",IDC_MEM_USAGE_HISTORY_GRAPH,81,75,
|
||||||
|
@ -281,8 +259,7 @@ CAPTION "Canales de Depuraci
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT |
|
CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT |
|
||||||
LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER |
|
LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP |
|
||||||
WS_TABSTOP |
|
|
||||||
LVS_SORTASCENDING,7,7,233,177
|
LVS_SORTASCENDING,7,7,233,177
|
||||||
PUSHBUTTON "Cerrar",IDOK,171,189,69,14
|
PUSHBUTTON "Cerrar",IDOK,171,189,69,14
|
||||||
END
|
END
|
||||||
|
@ -389,8 +366,7 @@ BEGIN
|
||||||
WS_TABSTOP,7,105,80,10 //53
|
WS_TABSTOP,7,105,80,10 //53
|
||||||
CONTROL "O&bjetos de USUARIO",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX |
|
CONTROL "O&bjetos de USUARIO",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,116,80,10 //62
|
WS_TABSTOP,7,116,80,10 //62
|
||||||
CONTROL "Lecturas E/S",IDC_IOREADS,"Button",BS_AUTOCHECKBOX
|
CONTROL "Lecturas E/S",IDC_IOREADS,"Button",BS_AUTOCHECKBOX |
|
||||||
|
|
|
||||||
WS_TABSTOP,7,127,60,10 //49
|
WS_TABSTOP,7,127,60,10 //49
|
||||||
CONTROL "Bytes E/S Leidos",IDC_IOREADBYTES,"Button",
|
CONTROL "Bytes E/S Leidos",IDC_IOREADBYTES,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,7,138,65,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,7,138,65,10
|
||||||
|
@ -610,7 +586,6 @@ BEGIN
|
||||||
ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL
|
ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL
|
||||||
"Establece el proceso en prioridad ABAJO DE LO NORMAL"
|
"Establece el proceso en prioridad ABAJO DE LO NORMAL"
|
||||||
ID_PROCESS_PAGE_SETPRIORITY_LOW "Establece el proceso en prioridad BAJA"
|
ID_PROCESS_PAGE_SETPRIORITY_LOW "Establece el proceso en prioridad BAJA"
|
||||||
|
|
||||||
END // Spanish (SPAIN) resources by Carlos Garcia Gomez
|
END // Spanish (SPAIN) resources by Carlos Garcia Gomez
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -161,6 +161,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -159,6 +159,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -163,6 +163,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,12 +160,13 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU |
|
WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU |
|
||||||
WS_THICKFRAME
|
WS_THICKFRAME
|
||||||
CAPTION "Oppgavebehandler"
|
CAPTION "Oppgavebehandling"
|
||||||
MENU IDR_TASKMANAGER
|
MENU IDR_TASKMANAGER
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
|
|
|
@ -165,6 +165,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
@ -520,8 +521,8 @@ END
|
||||||
|
|
||||||
STRINGTABLE DISCARDABLE
|
STRINGTABLE DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
IDS_APP_TITLE "Gestionar de activități"
|
IDS_APP_TITLE "Gestionarul de activități"
|
||||||
IDC_TASKMGR "Gestoinar de activități"
|
IDC_TASKMGR "Gestionarul de activități"
|
||||||
IDS_IDLE_PROCESS "Proces sistem inactiv"
|
IDS_IDLE_PROCESS "Proces sistem inactiv"
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
|
@ -159,6 +159,7 @@ END
|
||||||
//
|
//
|
||||||
// Äèàëîãè
|
// Äèàëîãè
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -159,6 +159,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
@ -521,8 +522,8 @@ END
|
||||||
|
|
||||||
STRINGTABLE DISCARDABLE
|
STRINGTABLE DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
IDS_APP_TITLE "Správca úloh"
|
IDS_APP_TITLE "Správca úloh systému"
|
||||||
IDC_TASKMGR "Správca úloh"
|
IDC_TASKMGR "Správca úloh systému"
|
||||||
IDS_IDLE_PROCESS "Procesy systémovej neèinnosti"
|
IDS_IDLE_PROCESS "Procesy systémovej neèinnosti"
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
|
@ -177,6 +177,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -160,6 +160,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
@ -338,65 +339,65 @@ BEGIN
|
||||||
WS_DISABLED | WS_TABSTOP,175,119,41,10
|
WS_DISABLED | WS_TABSTOP,175,119,41,10
|
||||||
END
|
END
|
||||||
|
|
||||||
IDD_COLUMNS_DIALOG DIALOGEX DISCARDABLE 0, 0, 195, 199
|
IDD_COLUMNS_DIALOG DIALOGEX DISCARDABLE 0, 0, 227, 199
|
||||||
STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||||
CAPTION "Âèá³ð ñòîâïö³â"
|
CAPTION "Âèá³ð ñòîâïö³â"
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
DEFPUSHBUTTON "Òàê",IDOK,84,178,50,14
|
DEFPUSHBUTTON "ÎÊ",IDOK,116,178,50,14
|
||||||
PUSHBUTTON "ͳ",IDCANCEL,138,178,50,14
|
PUSHBUTTON "Ñêàñóâàòè",IDCANCEL,170,178,50,14
|
||||||
LTEXT "Âèáåð³òü ñòîâïö³, ÿê³ ñë³ä â³äîáðàæàòè íà âêëàäö³ Ïðîöåñ äèñïåò÷åðà çàâäàíü.",
|
LTEXT "Âèáåð³òü ñòîâïö³, ÿê³ ñë³ä â³äîáðàæàòè íà âêëàäö³ Ïðîöåñè äèñïåò÷åðà çàâäàíü.",
|
||||||
IDC_STATIC,7,7,181,17
|
IDC_STATIC,7,7,181,17
|
||||||
CONTROL "&²ì'ÿ îáðàçó",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX |
|
CONTROL "&²ì'ÿ îáðàçó",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_DISABLED | WS_TABSTOP,7,28,56,10
|
WS_DISABLED | WS_TABSTOP,7,28,56,10
|
||||||
CONTROL "²äåíòè&ô. ïðîöåñó (PID)",IDC_PID,"Button",
|
CONTROL "²äåíòè&ô. ïðîöåñó (PID)",IDC_PID,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,7,39,88,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,7,39,91,10
|
||||||
CONTROL "&Âèêîðèñòàííÿ ÖÏ",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX |
|
CONTROL "&Âèêîðèñòàííÿ ÖÏ",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,50,53,10
|
WS_TABSTOP,7,50,71,10
|
||||||
CONTROL "&×àñ ÖÏ",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX |
|
CONTROL "&×àñ ÖÏ",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,61,48,10
|
WS_TABSTOP,7,61,48,10
|
||||||
CONTROL "&Ïàì'ÿòü - âèêîðèñòàííÿ",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX |
|
CONTROL "&Ïàì'ÿòü - âèêîðèñòàííÿ",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,72,63,10
|
WS_TABSTOP,7,72,92,10
|
||||||
CONTROL "Ïàì'ÿòü - çì³&íà",IDC_MEMORYUSAGEDELTA,"Button",
|
CONTROL "Ïàì'ÿòü - çì³&íà",IDC_MEMORYUSAGEDELTA,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,7,83,82,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,7,83,82,10
|
||||||
CONTROL "Ïàì'ÿòü - &ìàêñèìóì",IDC_PEAKMEMORYUSAGE,"Button",
|
CONTROL "Ïàì'ÿòü - &ìàêñèìóì",IDC_PEAKMEMORYUSAGE,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,7,94,82,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,7,94,82,10
|
||||||
CONTROL "Ï&îìèëîê ñòîð³íêè",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX |
|
CONTROL "Ï&îìèëîê ñòîð³íêè",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,105,53,10
|
WS_TABSTOP,7,105,73,10
|
||||||
CONTROL "Î&á'ºêòè USER",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX |
|
CONTROL "Î&á'ºêòè USER",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,116,62,10
|
WS_TABSTOP,7,116,62,10
|
||||||
CONTROL "ʳëüê³ñòü ÷èòàíü",IDC_IOREADS,"Button",BS_AUTOCHECKBOX |
|
CONTROL "ʳëüê³ñòü ÷èòàíü",IDC_IOREADS,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,127,49,10
|
WS_TABSTOP,7,127,68,10
|
||||||
CONTROL "Ïðî÷èòàíî áàéò³â",IDC_IOREADBYTES,"Button",
|
CONTROL "Ïðî÷èòàíî áàéò³â",IDC_IOREADBYTES,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,7,138,65,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,7,138,72,10
|
||||||
CONTROL "Êîä ñå&àíñó",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX |
|
CONTROL "Êîä ñå&àíñó",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,149,50,10
|
WS_TABSTOP,7,149,50,10
|
||||||
CONTROL "²ì'&ÿ êîðèñòóâà÷à",IDC_USERNAME,"Button",BS_AUTOCHECKBOX |
|
CONTROL "²ì'&ÿ êîðèñòóâà÷à",IDC_USERNAME,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,160,51,10
|
WS_TABSTOP,7,160,70,10
|
||||||
CONTROL "Ïîìèëîê &ñòîð³íêè - çì³íà",IDC_PAGEFAULTSDELTA,"Button",
|
CONTROL "Ïîìèëîê &ñòîð³íêè - çì³íà",IDC_PAGEFAULTSDELTA,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,107,28,72,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,107,28,72,10
|
||||||
CONTROL "Îá'ºì â³ðòóàë&üíî¿ ïàì'ÿò³",IDC_VIRTUALMEMORYSIZE,"Button",
|
CONTROL "Îá'ºì â³ðòóàë&üíî¿ ïàì'ÿò³",IDC_VIRTUALMEMORYSIZE,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,107,39,77,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,107,39,100,10
|
||||||
CONTROL "Âèâàíòà&æóâàíèé ïóë",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX |
|
CONTROL "Âèâàíòà&æóâàíèé ïóë",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,107,50,53,10
|
WS_TABSTOP,107,50,88,10
|
||||||
CONTROL "Íåâèâàíòàæ&óâàíèé ïóë",IDC_NONPAGEDPOOL,"Button",
|
CONTROL "Íåâèâàíòàæ&óâàíèé ïóë",IDC_NONPAGEDPOOL,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,107,61,67,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,107,61,96,10
|
||||||
CONTROL "Áàçîâè&é ïð³îðèòåò",IDC_BASEPRIORITY,"Button",
|
CONTROL "Áàçîâè&é ïð³îðèòåò",IDC_BASEPRIORITY,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,107,72,55,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,107,72,75,10
|
||||||
CONTROL "˳÷èëüíèê &äåñêðèïòîð³â",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX |
|
CONTROL "˳÷èëüíèê &äåñêðèïòîð³â",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,107,83,59,10
|
WS_TABSTOP,107,83,98,10
|
||||||
CONTROL "&˳÷èëüíèê ïîòîê³â",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX |
|
CONTROL "&˳÷èëüíèê ïîòîê³â",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,107,94,59,10
|
WS_TABSTOP,107,94,79,10
|
||||||
CONTROL "Îá'&ºêòè GDI",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX |
|
CONTROL "Îá'&ºêòè GDI",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,107,105,55,10
|
WS_TABSTOP,107,105,55,10
|
||||||
CONTROL "ʳëüê³ñòü çàïèñ³â",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX |
|
CONTROL "ʳëüê³ñòü çàïèñ³â",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,107,116,49,10
|
WS_TABSTOP,107,116,73,10
|
||||||
CONTROL "Çàïèñàíî áàéò³â",IDC_IOWRITEBYTES,"Button",
|
CONTROL "Çàïèñàíî áàéò³â",IDC_IOWRITEBYTES,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,107,127,65,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,107,127,67,10
|
||||||
CONTROL "²íøèé ââ³ä-âèâ³ä",IDC_IOOTHER,"Button",BS_AUTOCHECKBOX |
|
CONTROL "²íøèé ââ³ä-âèâ³ä",IDC_IOOTHER,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,107,138,46,10
|
WS_TABSTOP,107,138,71,10
|
||||||
CONTROL "²íøèõ áàéò³â ï³ä ÷àñ ââîäó-âèâîäó",IDC_IOOTHERBYTES,"Button",
|
CONTROL "²íøèõ áàéò³â ïðè ââîä³-âèâîä³",IDC_IOOTHERBYTES,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,107,149,65,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,107,149,114,10
|
||||||
END
|
END
|
||||||
|
|
||||||
|
|
||||||
|
@ -522,7 +523,7 @@ STRINGTABLE DISCARDABLE
|
||||||
BEGIN
|
BEGIN
|
||||||
IDS_APP_TITLE "Äèñïåò÷åð çàâäàíü"
|
IDS_APP_TITLE "Äèñïåò÷åð çàâäàíü"
|
||||||
IDC_TASKMGR "Äèñïåò÷åð çàâäàíü"
|
IDC_TASKMGR "Äèñïåò÷åð çàâäàíü"
|
||||||
IDS_IDLE_PROCESS "Íåä³ÿííÿ ñèñòåìè"
|
IDS_IDLE_PROCESS "Áåçä³ÿëüí³ñòü ñèñòåìè"
|
||||||
END
|
END
|
||||||
|
|
||||||
STRINGTABLE DISCARDABLE
|
STRINGTABLE DISCARDABLE
|
||||||
|
|
|
@ -168,6 +168,7 @@ END
|
||||||
//
|
//
|
||||||
// Dialog
|
// Dialog
|
||||||
//
|
//
|
||||||
|
// TRANSLATORS: CAPTION must be the same as IDS_APP_TITLE to be brought back to focus when already opened
|
||||||
|
|
||||||
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
IDD_TASKMGR_DIALOG DIALOGEX DISCARDABLE 0, 0, 264, 246
|
||||||
STYLE DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
STYLE DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP |
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* optnmenu.cpp
|
* optnmenu.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
||||||
*
|
*
|
||||||
|
@ -110,7 +110,7 @@ void TaskManager_OnOptionsShow16BitTasks(void)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* FIXME: Currently this is useless because the
|
* FIXME: Currently this is useless because the
|
||||||
* current implemetation doesn't list the 16-bit
|
* current implementation doesn't list the 16-bit
|
||||||
* processes. I believe that would require querying
|
* processes. I believe that would require querying
|
||||||
* each ntvdm.exe process for it's children.
|
* each ntvdm.exe process for it's children.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* perfdata.cpp
|
* perfdata.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
||||||
*
|
*
|
||||||
|
|
|
@ -51,11 +51,14 @@ HWND hPerformancePageTotalsHandleCountEdit; /* Total Handles Edit Con
|
||||||
HWND hPerformancePageTotalsProcessCountEdit; /* Total Processes Edit Control */
|
HWND hPerformancePageTotalsProcessCountEdit; /* Total Processes Edit Control */
|
||||||
HWND hPerformancePageTotalsThreadCountEdit; /* Total Threads Edit Control */
|
HWND hPerformancePageTotalsThreadCountEdit; /* Total Threads Edit Control */
|
||||||
|
|
||||||
|
#ifdef RUN_PERF_PAGE
|
||||||
|
static HANDLE hPerformanceThread = NULL;
|
||||||
|
static DWORD dwPerformanceThread;
|
||||||
|
#endif
|
||||||
|
|
||||||
static int nPerformancePageWidth;
|
static int nPerformancePageWidth;
|
||||||
static int nPerformancePageHeight;
|
static int nPerformancePageHeight;
|
||||||
static int lastX, lastY;
|
static int lastX, lastY;
|
||||||
static HANDLE hPerformancePageEvent = NULL; /* When this event becomes signaled then we refresh the performance page */
|
|
||||||
DWORD WINAPI PerformancePageRefreshThread(void *lpParameter);
|
DWORD WINAPI PerformancePageRefreshThread(void *lpParameter);
|
||||||
|
|
||||||
void AdjustFrameSize(HWND hCntrl, HWND hDlg, int nXDifference, int nYDifference, int pos)
|
void AdjustFrameSize(HWND hCntrl, HWND hDlg, int nXDifference, int nYDifference, int pos)
|
||||||
|
@ -94,12 +97,12 @@ void AdjustFrameSize(HWND hCntrl, HWND hDlg, int nXDifference, int nYDifference,
|
||||||
InvalidateRect(hCntrl, NULL, TRUE);
|
InvalidateRect(hCntrl, NULL, TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AdjustControlPostion(HWND hCntrl, HWND hDlg, int nXDifference, int nYDifference)
|
static void AdjustControlPostion(HWND hCntrl, HWND hDlg, int nXDifference, int nYDifference)
|
||||||
{
|
{
|
||||||
AdjustFrameSize(hCntrl, hDlg, nXDifference, nYDifference, 0);
|
AdjustFrameSize(hCntrl, hDlg, nXDifference, nYDifference, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AdjustCntrlPos(int ctrl_id, HWND hDlg, int nXDifference, int nYDifference)
|
static void AdjustCntrlPos(int ctrl_id, HWND hDlg, int nXDifference, int nYDifference)
|
||||||
{
|
{
|
||||||
AdjustFrameSize(GetDlgItem(hDlg, ctrl_id), hDlg, nXDifference, nYDifference, 0);
|
AdjustFrameSize(GetDlgItem(hDlg, ctrl_id), hDlg, nXDifference, nYDifference, 0);
|
||||||
}
|
}
|
||||||
|
@ -110,9 +113,6 @@ PerformancePageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
RECT rc;
|
RECT rc;
|
||||||
int nXDifference;
|
int nXDifference;
|
||||||
int nYDifference;
|
int nYDifference;
|
||||||
#ifdef RUN_PERF_PAGE
|
|
||||||
HANDLE hRefreshThread = NULL;
|
|
||||||
#endif
|
|
||||||
/* HDC hdc; */
|
/* HDC hdc; */
|
||||||
/* PAINTSTRUCT ps; */
|
/* PAINTSTRUCT ps; */
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ PerformancePageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
GraphCtrl_Dispose(&PerformancePageCpuUsageHistoryGraph);
|
GraphCtrl_Dispose(&PerformancePageCpuUsageHistoryGraph);
|
||||||
GraphCtrl_Dispose(&PerformancePageMemUsageHistoryGraph);
|
GraphCtrl_Dispose(&PerformancePageMemUsageHistoryGraph);
|
||||||
#ifdef RUN_PERF_PAGE
|
#ifdef RUN_PERF_PAGE
|
||||||
CloseHandle(hRefreshThread);
|
EndLocalThread(&hPerformanceThread, dwPerformanceThread);
|
||||||
#endif
|
#endif
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -192,7 +192,7 @@ PerformancePageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
GraphCtrl_SetPlotColor(&PerformancePageMemUsageHistoryGraph, 0, RGB(255, 255, 0)) ;
|
GraphCtrl_SetPlotColor(&PerformancePageMemUsageHistoryGraph, 0, RGB(255, 255, 0)) ;
|
||||||
/* Start our refresh thread */
|
/* Start our refresh thread */
|
||||||
#ifdef RUN_PERF_PAGE
|
#ifdef RUN_PERF_PAGE
|
||||||
hRefreshThread = CreateThread(NULL, 0, PerformancePageRefreshThread, NULL, 0, NULL);
|
hPerformanceThread = CreateThread(NULL, 0, PerformancePageRefreshThread, NULL, 0, &dwPerformanceThread);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -303,9 +303,11 @@ PerformancePageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
|
|
||||||
void RefreshPerformancePage(void)
|
void RefreshPerformancePage(void)
|
||||||
{
|
{
|
||||||
|
#ifdef RUN_PERF_PAGE
|
||||||
/* Signal the event so that our refresh thread */
|
/* Signal the event so that our refresh thread */
|
||||||
/* will wake up and refresh the performance page */
|
/* will wake up and refresh the performance page */
|
||||||
SetEvent(hPerformancePageEvent);
|
PostThreadMessage(dwPerformanceThread, WM_TIMER, 0, 0);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
DWORD WINAPI PerformancePageRefreshThread(void *lpParameter)
|
DWORD WINAPI PerformancePageRefreshThread(void *lpParameter)
|
||||||
|
@ -332,35 +334,21 @@ DWORD WINAPI PerformancePageRefreshThread(void *lpParameter)
|
||||||
WCHAR Text[260];
|
WCHAR Text[260];
|
||||||
WCHAR szMemUsage[256];
|
WCHAR szMemUsage[256];
|
||||||
|
|
||||||
/* Create the event */
|
MSG msg;
|
||||||
hPerformancePageEvent = CreateEventW(NULL, TRUE, TRUE, NULL);
|
|
||||||
|
|
||||||
/* If we couldn't create the event then exit the thread */
|
|
||||||
if (!hPerformancePageEvent)
|
|
||||||
return 0;
|
|
||||||
|
|
||||||
LoadStringW(hInst, IDS_STATUS_MEMUSAGE, szMemUsage, 256);
|
LoadStringW(hInst, IDS_STATUS_MEMUSAGE, szMemUsage, 256);
|
||||||
|
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
DWORD dwWaitVal;
|
|
||||||
|
|
||||||
int nBarsUsed1;
|
int nBarsUsed1;
|
||||||
int nBarsUsed2;
|
int nBarsUsed2;
|
||||||
|
|
||||||
/* Wait on the event */
|
/* Wait for an the event or application close */
|
||||||
dwWaitVal = WaitForSingleObject(hPerformancePageEvent, INFINITE);
|
if (GetMessage(&msg, NULL, 0, 0) <= 0)
|
||||||
|
|
||||||
/* If the wait failed then the event object must have been */
|
|
||||||
/* closed and the task manager is exiting so exit this thread */
|
|
||||||
if (dwWaitVal == WAIT_FAILED)
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (dwWaitVal == WAIT_OBJECT_0)
|
if (msg.message == WM_TIMER)
|
||||||
{
|
{
|
||||||
/* Reset our event */
|
|
||||||
ResetEvent(hPerformancePageEvent);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Update the commit charge info
|
* Update the commit charge info
|
||||||
*/
|
*/
|
||||||
|
@ -449,8 +437,6 @@ DWORD WINAPI PerformancePageRefreshThread(void *lpParameter)
|
||||||
PhysicalMemoryAvailable = PerfDataGetPhysicalMemoryAvailableK();
|
PhysicalMemoryAvailable = PerfDataGetPhysicalMemoryAvailableK();
|
||||||
nBarsUsed2 = PhysicalMemoryTotal ? ((PhysicalMemoryAvailable * 100) / PhysicalMemoryTotal) : 0;
|
nBarsUsed2 = PhysicalMemoryTotal ? ((PhysicalMemoryAvailable * 100) / PhysicalMemoryTotal) : 0;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
GraphCtrl_AppendPoint(&PerformancePageCpuUsageHistoryGraph, CpuUsage, CpuKernelUsage, 0.0, 0.0);
|
GraphCtrl_AppendPoint(&PerformancePageCpuUsageHistoryGraph, CpuUsage, CpuKernelUsage, 0.0, 0.0);
|
||||||
GraphCtrl_AppendPoint(&PerformancePageMemUsageHistoryGraph, nBarsUsed1, nBarsUsed2, 0.0, 0.0);
|
GraphCtrl_AppendPoint(&PerformancePageMemUsageHistoryGraph, nBarsUsed1, nBarsUsed2, 0.0, 0.0);
|
||||||
/* PerformancePageMemUsageHistoryGraph.SetRange(0.0, 100.0, 10) ; */
|
/* PerformancePageMemUsageHistoryGraph.SetRange(0.0, 100.0, 10) ; */
|
||||||
|
@ -458,7 +444,7 @@ DWORD WINAPI PerformancePageRefreshThread(void *lpParameter)
|
||||||
InvalidateRect(hPerformancePageCpuUsageHistoryGraph, NULL, FALSE);
|
InvalidateRect(hPerformancePageCpuUsageHistoryGraph, NULL, FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PerformancePage_OnViewShowKernelTimes(void)
|
void PerformancePage_OnViewShowKernelTimes(void)
|
||||||
|
|
|
@ -40,7 +40,10 @@ HWND hProcessPageShowAllProcessesButton;/* Process Show All Processes checkbox *
|
||||||
|
|
||||||
static int nProcessPageWidth;
|
static int nProcessPageWidth;
|
||||||
static int nProcessPageHeight;
|
static int nProcessPageHeight;
|
||||||
static HANDLE hProcessPageEvent = NULL; /* When this event becomes signaled then we refresh the process list */
|
#ifdef RUN_PROC_PAGE
|
||||||
|
static HANDLE hProcessThread = NULL;
|
||||||
|
static DWORD dwProcessThread;
|
||||||
|
#endif
|
||||||
|
|
||||||
int CALLBACK ProcessPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
|
int CALLBACK ProcessPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
|
||||||
void AddProcess(ULONG Index);
|
void AddProcess(ULONG Index);
|
||||||
|
@ -104,7 +107,6 @@ ProcessPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
int nXDifference;
|
int nXDifference;
|
||||||
int nYDifference;
|
int nYDifference;
|
||||||
int cx, cy;
|
int cx, cy;
|
||||||
HANDLE hRefreshThread = NULL;
|
|
||||||
|
|
||||||
switch (message) {
|
switch (message) {
|
||||||
case WM_INITDIALOG:
|
case WM_INITDIALOG:
|
||||||
|
@ -139,19 +141,19 @@ ProcessPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
*/
|
*/
|
||||||
OldProcessListWndProc = (WNDPROC)(LONG_PTR) SetWindowLongPtrW(hProcessPageListCtrl, GWL_WNDPROC, (LONG_PTR)ProcessListWndProc);
|
OldProcessListWndProc = (WNDPROC)(LONG_PTR) SetWindowLongPtrW(hProcessPageListCtrl, GWL_WNDPROC, (LONG_PTR)ProcessListWndProc);
|
||||||
|
|
||||||
|
#ifdef RUN_PROC_PAGE
|
||||||
/* Start our refresh thread */
|
/* Start our refresh thread */
|
||||||
hRefreshThread = CreateThread(NULL, 0, ProcessPageRefreshThread, NULL, 0, NULL);
|
hProcessThread = CreateThread(NULL, 0, ProcessPageRefreshThread, NULL, 0, &dwProcessThread);
|
||||||
|
#endif
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
case WM_DESTROY:
|
case WM_DESTROY:
|
||||||
/* Close the event handle, this will make the */
|
/* Close the event handle, this will make the */
|
||||||
/* refresh thread exit when the wait fails */
|
/* refresh thread exit when the wait fails */
|
||||||
CloseHandle(hProcessPageEvent);
|
#ifdef RUN_PROC_PAGE
|
||||||
CloseHandle(hRefreshThread);
|
EndLocalThread(&hProcessThread, dwProcessThread);
|
||||||
|
#endif
|
||||||
SaveColumnSettings();
|
SaveColumnSettings();
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WM_COMMAND:
|
case WM_COMMAND:
|
||||||
|
@ -194,11 +196,9 @@ ProcessPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
cy = rc.top + nYDifference;
|
cy = rc.top + nYDifference;
|
||||||
SetWindowPos(hProcessPageShowAllProcessesButton, NULL, cx, cy, 0, 0, SWP_NOACTIVATE|SWP_NOOWNERZORDER|SWP_NOSIZE|SWP_NOZORDER);
|
SetWindowPos(hProcessPageShowAllProcessesButton, NULL, cx, cy, 0, 0, SWP_NOACTIVATE|SWP_NOOWNERZORDER|SWP_NOSIZE|SWP_NOZORDER);
|
||||||
InvalidateRect(hProcessPageShowAllProcessesButton, NULL, TRUE);
|
InvalidateRect(hProcessPageShowAllProcessesButton, NULL, TRUE);
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WM_NOTIFY:
|
case WM_NOTIFY:
|
||||||
|
|
||||||
ProcessPageOnNotify(wParam, lParam);
|
ProcessPageOnNotify(wParam, lParam);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -372,9 +372,11 @@ void ProcessPageShowContextMenu(DWORD dwProcessId)
|
||||||
|
|
||||||
void RefreshProcessPage(void)
|
void RefreshProcessPage(void)
|
||||||
{
|
{
|
||||||
|
#ifdef RUN_PROC_PAGE
|
||||||
/* Signal the event so that our refresh thread */
|
/* Signal the event so that our refresh thread */
|
||||||
/* will wake up and refresh the process page */
|
/* will wake up and refresh the process page */
|
||||||
SetEvent(hProcessPageEvent);
|
PostThreadMessage(dwProcessThread, WM_TIMER, 0, 0);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
DWORD WINAPI ProcessPageRefreshThread(void *lpParameter)
|
DWORD WINAPI ProcessPageRefreshThread(void *lpParameter)
|
||||||
|
@ -382,34 +384,19 @@ DWORD WINAPI ProcessPageRefreshThread(void *lpParameter)
|
||||||
ULONG OldProcessorUsage = 0;
|
ULONG OldProcessorUsage = 0;
|
||||||
ULONG OldProcessCount = 0;
|
ULONG OldProcessCount = 0;
|
||||||
WCHAR szCpuUsage[256], szProcesses[256];
|
WCHAR szCpuUsage[256], szProcesses[256];
|
||||||
|
MSG msg;
|
||||||
/* Create the event */
|
|
||||||
hProcessPageEvent = CreateEventW(NULL, TRUE, TRUE, NULL);
|
|
||||||
|
|
||||||
/* If we couldn't create the event then exit the thread */
|
|
||||||
if (!hProcessPageEvent)
|
|
||||||
return 0;
|
|
||||||
|
|
||||||
LoadStringW(hInst, IDS_STATUS_CPUUSAGE, szCpuUsage, 256);
|
LoadStringW(hInst, IDS_STATUS_CPUUSAGE, szCpuUsage, 256);
|
||||||
LoadStringW(hInst, IDS_STATUS_PROCESSES, szProcesses, 256);
|
LoadStringW(hInst, IDS_STATUS_PROCESSES, szProcesses, 256);
|
||||||
|
|
||||||
while (1) {
|
while (1) {
|
||||||
DWORD dwWaitVal;
|
/* Wait for an the event or application close */
|
||||||
|
if (GetMessage(&msg, NULL, 0, 0) <= 0)
|
||||||
/* Wait on the event */
|
|
||||||
dwWaitVal = WaitForSingleObject(hProcessPageEvent, INFINITE);
|
|
||||||
|
|
||||||
/* If the wait failed then the event object must have been */
|
|
||||||
/* closed and the task manager is exiting so exit this thread */
|
|
||||||
if (dwWaitVal == WAIT_FAILED)
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (dwWaitVal == WAIT_OBJECT_0) {
|
if (msg.message == WM_TIMER) {
|
||||||
WCHAR text[260];
|
WCHAR text[260];
|
||||||
|
|
||||||
/* Reset our event */
|
|
||||||
ResetEvent(hProcessPageEvent);
|
|
||||||
|
|
||||||
UpdateProcesses();
|
UpdateProcesses();
|
||||||
|
|
||||||
if (IsWindowVisible(hProcessPage))
|
if (IsWindowVisible(hProcessPage))
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* ReactOS Task Manager
|
* ReactOS Task Manager
|
||||||
*
|
*
|
||||||
* TaskMgr.c : Defines the entry point for the application.
|
* taskmgr.c : Defines the entry point for the application.
|
||||||
*
|
*
|
||||||
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
||||||
* 2005 Klemens Friedl <frik85@reactos.at>
|
* 2005 Klemens Friedl <frik85@reactos.at>
|
||||||
|
@ -856,11 +856,6 @@ void TaskManager_OnViewUpdateSpeed(DWORD dwSpeed)
|
||||||
SetUpdateSpeed(hMainWnd);
|
SetUpdateSpeed(hMainWnd);
|
||||||
}
|
}
|
||||||
|
|
||||||
void TaskManager_OnViewRefresh(void)
|
|
||||||
{
|
|
||||||
PostMessageW(hMainWnd, WM_TIMER, 0, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void TaskManager_OnTabWndSelChange(void)
|
void TaskManager_OnTabWndSelChange(void)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
@ -1012,3 +1007,27 @@ LPWSTR GetLastErrorText(LPWSTR lpszBuf, DWORD dwSize)
|
||||||
}
|
}
|
||||||
return lpszBuf;
|
return lpszBuf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DWORD EndLocalThread(HANDLE *hThread, DWORD dwThread)
|
||||||
|
{
|
||||||
|
DWORD dwExitCodeThread = 0;
|
||||||
|
|
||||||
|
if (*hThread != NULL) {
|
||||||
|
PostThreadMessage(dwThread,WM_QUIT,0,0);
|
||||||
|
for (;;) {
|
||||||
|
MSG msg;
|
||||||
|
|
||||||
|
if (WAIT_OBJECT_0 == WaitForSingleObject(*hThread, 500))
|
||||||
|
break;
|
||||||
|
while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) {
|
||||||
|
TranslateMessage(&msg);
|
||||||
|
DispatchMessage(&msg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
GetExitCodeThread(*hThread, &dwExitCodeThread);
|
||||||
|
CloseHandle(*hThread);
|
||||||
|
*hThread = NULL;
|
||||||
|
}
|
||||||
|
return dwExitCodeThread;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
@ -116,9 +116,9 @@ void TaskManager_OnEnterMenuLoop(HWND hWnd);
|
||||||
void TaskManager_OnExitMenuLoop(HWND hWnd);
|
void TaskManager_OnExitMenuLoop(HWND hWnd);
|
||||||
void TaskManager_OnMenuSelect(HWND hWnd, UINT nItemID, UINT nFlags, HMENU hSysMenu);
|
void TaskManager_OnMenuSelect(HWND hWnd, UINT nItemID, UINT nFlags, HMENU hSysMenu);
|
||||||
void TaskManager_OnViewUpdateSpeed(DWORD);
|
void TaskManager_OnViewUpdateSpeed(DWORD);
|
||||||
void TaskManager_OnViewRefresh(void);
|
|
||||||
void TaskManager_OnTabWndSelChange(void);
|
void TaskManager_OnTabWndSelChange(void);
|
||||||
LPTSTR GetLastErrorText( LPTSTR lpszBuf, DWORD dwSize );
|
LPTSTR GetLastErrorText( LPTSTR lpszBuf, DWORD dwSize );
|
||||||
|
DWORD EndLocalThread(HANDLE *hThread, DWORD dwThread);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,6 +31,75 @@
|
||||||
|
|
||||||
#define SECTORSIZE 512
|
#define SECTORSIZE 512
|
||||||
|
|
||||||
|
#include <pshpack1.h>
|
||||||
|
typedef struct _FAT_BOOTSECTOR
|
||||||
|
{
|
||||||
|
UCHAR JumpBoot[3]; // Jump instruction to boot code
|
||||||
|
CHAR OemName[8]; // "MSWIN4.1" for MS formatted volumes
|
||||||
|
USHORT BytesPerSector; // Bytes per sector
|
||||||
|
UCHAR SectorsPerCluster; // Number of sectors in a cluster
|
||||||
|
USHORT ReservedSectors; // Reserved sectors, usually 1 (the bootsector)
|
||||||
|
UCHAR NumberOfFats; // Number of FAT tables
|
||||||
|
USHORT RootDirEntries; // Number of root directory entries (fat12/16)
|
||||||
|
USHORT TotalSectors; // Number of total sectors on the drive, 16-bit
|
||||||
|
UCHAR MediaDescriptor; // Media descriptor byte
|
||||||
|
USHORT SectorsPerFat; // Sectors per FAT table (fat12/16)
|
||||||
|
USHORT SectorsPerTrack; // Number of sectors in a track
|
||||||
|
USHORT NumberOfHeads; // Number of heads on the disk
|
||||||
|
ULONG HiddenSectors; // Hidden sectors (sectors before the partition start like the partition table)
|
||||||
|
ULONG TotalSectorsBig; // This field is the new 32-bit total count of sectors on the volume
|
||||||
|
UCHAR DriveNumber; // Int 0x13 drive number (e.g. 0x80)
|
||||||
|
UCHAR Reserved1; // Reserved (used by Windows NT). Code that formats FAT volumes should always set this byte to 0.
|
||||||
|
UCHAR BootSignature; // Extended boot signature (0x29). This is a signature byte that indicates that the following three fields in the boot sector are present.
|
||||||
|
ULONG VolumeSerialNumber; // Volume serial number
|
||||||
|
CHAR VolumeLabel[11]; // Volume label. This field matches the 11-byte volume label recorded in the root directory
|
||||||
|
CHAR FileSystemType[8]; // One of the strings "FAT12 ", "FAT16 ", or "FAT "
|
||||||
|
|
||||||
|
UCHAR BootCodeAndData[448]; // The remainder of the boot sector
|
||||||
|
|
||||||
|
USHORT BootSectorMagic; // 0xAA55
|
||||||
|
|
||||||
|
} FAT_BOOTSECTOR, *PFAT_BOOTSECTOR;
|
||||||
|
|
||||||
|
typedef struct _FAT32_BOOTSECTOR
|
||||||
|
{
|
||||||
|
UCHAR JumpBoot[3]; // Jump instruction to boot code
|
||||||
|
CHAR OemName[8]; // "MSWIN4.1" for MS formatted volumes
|
||||||
|
USHORT BytesPerSector; // Bytes per sector
|
||||||
|
UCHAR SectorsPerCluster; // Number of sectors in a cluster
|
||||||
|
USHORT ReservedSectors; // Reserved sectors, usually 1 (the bootsector)
|
||||||
|
UCHAR NumberOfFats; // Number of FAT tables
|
||||||
|
USHORT RootDirEntries; // Number of root directory entries (fat12/16)
|
||||||
|
USHORT TotalSectors; // Number of total sectors on the drive, 16-bit
|
||||||
|
UCHAR MediaDescriptor; // Media descriptor byte
|
||||||
|
USHORT SectorsPerFat; // Sectors per FAT table (fat12/16)
|
||||||
|
USHORT SectorsPerTrack; // Number of sectors in a track
|
||||||
|
USHORT NumberOfHeads; // Number of heads on the disk
|
||||||
|
ULONG HiddenSectors; // Hidden sectors (sectors before the partition start like the partition table)
|
||||||
|
ULONG TotalSectorsBig; // This field is the new 32-bit total count of sectors on the volume
|
||||||
|
ULONG SectorsPerFatBig; // This field is the FAT32 32-bit count of sectors occupied by ONE FAT. BPB_FATSz16 must be 0
|
||||||
|
USHORT ExtendedFlags; // Extended flags (fat32)
|
||||||
|
USHORT FileSystemVersion; // File system version (fat32)
|
||||||
|
ULONG RootDirStartCluster; // Starting cluster of the root directory (fat32)
|
||||||
|
USHORT FsInfo; // Sector number of FSINFO structure in the reserved area of the FAT32 volume. Usually 1.
|
||||||
|
USHORT BackupBootSector; // If non-zero, indicates the sector number in the reserved area of the volume of a copy of the boot record. Usually 6.
|
||||||
|
UCHAR Reserved[12]; // Reserved for future expansion
|
||||||
|
UCHAR DriveNumber; // Int 0x13 drive number (e.g. 0x80)
|
||||||
|
UCHAR Reserved1; // Reserved (used by Windows NT). Code that formats FAT volumes should always set this byte to 0.
|
||||||
|
UCHAR BootSignature; // Extended boot signature (0x29). This is a signature byte that indicates that the following three fields in the boot sector are present.
|
||||||
|
ULONG VolumeSerialNumber; // Volume serial number
|
||||||
|
CHAR VolumeLabel[11]; // Volume label. This field matches the 11-byte volume label recorded in the root directory
|
||||||
|
CHAR FileSystemType[8]; // Always set to the string "FAT32 "
|
||||||
|
|
||||||
|
UCHAR BootCodeAndData[420]; // The remainder of the boot sector
|
||||||
|
|
||||||
|
USHORT BootSectorMagic; // 0xAA55
|
||||||
|
|
||||||
|
} FAT32_BOOTSECTOR, *PFAT32_BOOTSECTOR;
|
||||||
|
#include <poppack.h>
|
||||||
|
|
||||||
|
extern PPARTLIST PartitionList;
|
||||||
|
|
||||||
/* FUNCTIONS ****************************************************************/
|
/* FUNCTIONS ****************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
@ -1094,53 +1163,53 @@ NTSTATUS
|
||||||
InstallMbrBootCodeToDisk (PWSTR SrcPath,
|
InstallMbrBootCodeToDisk (PWSTR SrcPath,
|
||||||
PWSTR RootPath)
|
PWSTR RootPath)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
IO_STATUS_BLOCK IoStatusBlock;
|
IO_STATUS_BLOCK IoStatusBlock;
|
||||||
UNICODE_STRING Name;
|
UNICODE_STRING Name;
|
||||||
HANDLE FileHandle;
|
HANDLE FileHandle;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
PPARTITION_SECTOR OrigBootSector;
|
PPARTITION_SECTOR OrigBootSector;
|
||||||
PPARTITION_SECTOR NewBootSector;
|
PPARTITION_SECTOR NewBootSector;
|
||||||
|
|
||||||
/* Allocate buffer for original bootsector */
|
/* Allocate buffer for original bootsector */
|
||||||
OrigBootSector = (PPARTITION_SECTOR)RtlAllocateHeap(ProcessHeap,
|
OrigBootSector = (PPARTITION_SECTOR)RtlAllocateHeap(ProcessHeap,
|
||||||
0,
|
0,
|
||||||
sizeof(PARTITION_SECTOR));
|
sizeof(PARTITION_SECTOR));
|
||||||
if (OrigBootSector == NULL)
|
if (OrigBootSector == NULL)
|
||||||
return(STATUS_INSUFFICIENT_RESOURCES);
|
return(STATUS_INSUFFICIENT_RESOURCES);
|
||||||
|
|
||||||
/* Read current boot sector into buffer */
|
/* Read current boot sector into buffer */
|
||||||
RtlInitUnicodeString(&Name,
|
RtlInitUnicodeString(&Name,
|
||||||
RootPath);
|
RootPath);
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&Name,
|
&Name,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
NULL,
|
NULL,
|
||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
Status = NtOpenFile(&FileHandle,
|
Status = NtOpenFile(&FileHandle,
|
||||||
GENERIC_READ,
|
GENERIC_READ,
|
||||||
&ObjectAttributes,
|
&ObjectAttributes,
|
||||||
&IoStatusBlock,
|
&IoStatusBlock,
|
||||||
0,
|
0,
|
||||||
FILE_SYNCHRONOUS_IO_NONALERT);
|
FILE_SYNCHRONOUS_IO_NONALERT);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
||||||
return(Status);
|
return(Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
Status = NtReadFile(FileHandle,
|
Status = NtReadFile(FileHandle,
|
||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
&IoStatusBlock,
|
&IoStatusBlock,
|
||||||
OrigBootSector,
|
OrigBootSector,
|
||||||
SECTORSIZE,
|
SECTORSIZE,
|
||||||
NULL,
|
NULL,
|
||||||
NULL);
|
NULL);
|
||||||
NtClose(FileHandle);
|
NtClose(FileHandle);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
||||||
|
@ -1256,11 +1325,12 @@ InstallFat16BootCodeToDisk(PWSTR SrcPath,
|
||||||
UNICODE_STRING Name;
|
UNICODE_STRING Name;
|
||||||
HANDLE FileHandle;
|
HANDLE FileHandle;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
PUCHAR OrigBootSector;
|
PFAT_BOOTSECTOR OrigBootSector;
|
||||||
PUCHAR NewBootSector;
|
PFAT_BOOTSECTOR NewBootSector;
|
||||||
|
PARTITION_INFORMATION *PartInfo;
|
||||||
|
|
||||||
/* Allocate buffer for original bootsector */
|
/* Allocate buffer for original bootsector */
|
||||||
OrigBootSector = (PUCHAR)RtlAllocateHeap(ProcessHeap,
|
OrigBootSector = RtlAllocateHeap(ProcessHeap,
|
||||||
0,
|
0,
|
||||||
SECTORSIZE);
|
SECTORSIZE);
|
||||||
if (OrigBootSector == NULL)
|
if (OrigBootSector == NULL)
|
||||||
|
@ -1306,7 +1376,7 @@ InstallFat16BootCodeToDisk(PWSTR SrcPath,
|
||||||
|
|
||||||
|
|
||||||
/* Allocate buffer for new bootsector */
|
/* Allocate buffer for new bootsector */
|
||||||
NewBootSector = (PUCHAR)RtlAllocateHeap(ProcessHeap,
|
NewBootSector = RtlAllocateHeap(ProcessHeap,
|
||||||
0,
|
0,
|
||||||
SECTORSIZE);
|
SECTORSIZE);
|
||||||
if (NewBootSector == NULL)
|
if (NewBootSector == NULL)
|
||||||
|
@ -1356,9 +1426,12 @@ InstallFat16BootCodeToDisk(PWSTR SrcPath,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Adjust bootsector (copy a part of the FAT16 BPB) */
|
/* Adjust bootsector (copy a part of the FAT16 BPB) */
|
||||||
memcpy((NewBootSector + 3),
|
memcpy(&NewBootSector->BytesPerSector,
|
||||||
(OrigBootSector + 3),
|
&OrigBootSector->BytesPerSector,
|
||||||
59); /* FAT16 BPB length*/
|
51); /* FAT16 BPB length */
|
||||||
|
|
||||||
|
PartInfo = &PartitionList->CurrentPartition->PartInfo[PartitionList->CurrentPartitionNumber];
|
||||||
|
NewBootSector->HiddenSectors = PartInfo->HiddenSectors;
|
||||||
|
|
||||||
/* Free the original boot sector */
|
/* Free the original boot sector */
|
||||||
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
||||||
|
@ -1416,13 +1489,14 @@ InstallFat32BootCodeToDisk(PWSTR SrcPath,
|
||||||
UNICODE_STRING Name;
|
UNICODE_STRING Name;
|
||||||
HANDLE FileHandle;
|
HANDLE FileHandle;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
PUCHAR OrigBootSector;
|
PFAT32_BOOTSECTOR OrigBootSector;
|
||||||
PUCHAR NewBootSector;
|
PFAT32_BOOTSECTOR NewBootSector;
|
||||||
LARGE_INTEGER FileOffset;
|
LARGE_INTEGER FileOffset;
|
||||||
USHORT BackupBootSector;
|
USHORT BackupBootSector;
|
||||||
|
PARTITION_INFORMATION *PartInfo;
|
||||||
|
|
||||||
/* Allocate buffer for original bootsector */
|
/* Allocate buffer for original bootsector */
|
||||||
OrigBootSector = (PUCHAR)RtlAllocateHeap(ProcessHeap,
|
OrigBootSector = RtlAllocateHeap(ProcessHeap,
|
||||||
0,
|
0,
|
||||||
SECTORSIZE);
|
SECTORSIZE);
|
||||||
if (OrigBootSector == NULL)
|
if (OrigBootSector == NULL)
|
||||||
|
@ -1468,7 +1542,7 @@ InstallFat32BootCodeToDisk(PWSTR SrcPath,
|
||||||
|
|
||||||
|
|
||||||
/* Allocate buffer for new bootsector (2 sectors) */
|
/* Allocate buffer for new bootsector (2 sectors) */
|
||||||
NewBootSector = (PUCHAR)RtlAllocateHeap(ProcessHeap,
|
NewBootSector = RtlAllocateHeap(ProcessHeap,
|
||||||
0,
|
0,
|
||||||
2 * SECTORSIZE);
|
2 * SECTORSIZE);
|
||||||
if (NewBootSector == NULL)
|
if (NewBootSector == NULL)
|
||||||
|
@ -1518,12 +1592,15 @@ InstallFat32BootCodeToDisk(PWSTR SrcPath,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Adjust bootsector (copy a part of the FAT32 BPB) */
|
/* Adjust bootsector (copy a part of the FAT32 BPB) */
|
||||||
memcpy((NewBootSector + 3),
|
memcpy(&NewBootSector->BytesPerSector,
|
||||||
(OrigBootSector + 3),
|
&OrigBootSector->BytesPerSector,
|
||||||
87); /* FAT32 BPB length */
|
79); /* FAT32 BPB length */
|
||||||
|
|
||||||
|
PartInfo = &PartitionList->CurrentPartition->PartInfo[PartitionList->CurrentPartitionNumber];
|
||||||
|
NewBootSector->HiddenSectors = PartInfo->HiddenSectors;
|
||||||
|
|
||||||
/* Get the location of the backup boot sector */
|
/* Get the location of the backup boot sector */
|
||||||
BackupBootSector = (OrigBootSector[0x33] << 8) + OrigBootSector[0x32];
|
BackupBootSector = OrigBootSector->BackupBootSector;
|
||||||
|
|
||||||
/* Free the original boot sector */
|
/* Free the original boot sector */
|
||||||
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
RtlFreeHeap(ProcessHeap, 0, OrigBootSector);
|
||||||
|
@ -1599,7 +1676,7 @@ InstallFat32BootCodeToDisk(PWSTR SrcPath,
|
||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL,
|
||||||
&IoStatusBlock,
|
&IoStatusBlock,
|
||||||
(NewBootSector + SECTORSIZE),
|
((PUCHAR)NewBootSector + SECTORSIZE),
|
||||||
SECTORSIZE,
|
SECTORSIZE,
|
||||||
&FileOffset,
|
&FileOffset,
|
||||||
NULL);
|
NULL);
|
||||||
|
@ -2156,6 +2233,28 @@ InstallFatBootcodeToPartition(PUNICODE_STRING SystemRootPath,
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
NTSTATUS
|
||||||
|
InstallVBRToPartition(PUNICODE_STRING SystemRootPath,
|
||||||
|
PUNICODE_STRING SourceRootPath,
|
||||||
|
PUNICODE_STRING DestinationArcPath,
|
||||||
|
UCHAR PartitionType)
|
||||||
|
{
|
||||||
|
if ((PartitionType == PARTITION_FAT_12) ||
|
||||||
|
(PartitionType == PARTITION_FAT_16) ||
|
||||||
|
(PartitionType == PARTITION_HUGE) ||
|
||||||
|
(PartitionType == PARTITION_XINT13) ||
|
||||||
|
(PartitionType == PARTITION_FAT32) ||
|
||||||
|
(PartitionType == PARTITION_FAT32_XINT13))
|
||||||
|
{
|
||||||
|
return InstallFatBootcodeToPartition(SystemRootPath,
|
||||||
|
SourceRootPath,
|
||||||
|
DestinationArcPath,
|
||||||
|
PartitionType);
|
||||||
|
}
|
||||||
|
|
||||||
|
return STATUS_UNSUCCESSFUL;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
InstallFatBootcodeToFloppy(PUNICODE_STRING SourceRootPath,
|
InstallFatBootcodeToFloppy(PUNICODE_STRING SourceRootPath,
|
||||||
|
|
|
@ -78,6 +78,12 @@ InstallFatBootcodeToPartition(PUNICODE_STRING SystemRootPath,
|
||||||
PUNICODE_STRING DestinationArcPath,
|
PUNICODE_STRING DestinationArcPath,
|
||||||
UCHAR PartitionType);
|
UCHAR PartitionType);
|
||||||
|
|
||||||
|
NTSTATUS
|
||||||
|
InstallVBRToPartition(PUNICODE_STRING SystemRootPath,
|
||||||
|
PUNICODE_STRING SourceRootPath,
|
||||||
|
PUNICODE_STRING DestinationArcPath,
|
||||||
|
UCHAR PartitionType);
|
||||||
|
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
InstallFatBootcodeToFloppy(PUNICODE_STRING SourceRootPath,
|
InstallFatBootcodeToFloppy(PUNICODE_STRING SourceRootPath,
|
||||||
PUNICODE_STRING DestinationArcPath);
|
PUNICODE_STRING DestinationArcPath);
|
||||||
|
|
|
@ -65,46 +65,6 @@ InfpFindFirstLineW(
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOL WINAPI
|
|
||||||
InfpFindNextLine(
|
|
||||||
IN PINFCONTEXT ContextIn,
|
|
||||||
OUT PINFCONTEXT ContextOut)
|
|
||||||
{
|
|
||||||
return InfFindNextLine(ContextIn, ContextOut);
|
|
||||||
}
|
|
||||||
|
|
||||||
BOOL WINAPI
|
|
||||||
InfpGetBinaryField(
|
|
||||||
IN PINFCONTEXT Context,
|
|
||||||
IN ULONG FieldIndex,
|
|
||||||
IN OUT BYTE* ReturnBuffer,
|
|
||||||
IN ULONG ReturnBufferSize,
|
|
||||||
OUT PULONG RequiredSize)
|
|
||||||
{
|
|
||||||
return InfGetBinaryField(Context, FieldIndex, ReturnBuffer, ReturnBufferSize, RequiredSize);
|
|
||||||
}
|
|
||||||
|
|
||||||
DWORD WINAPI
|
|
||||||
InfpGetFieldCount(
|
|
||||||
IN PINFCONTEXT Context)
|
|
||||||
{
|
|
||||||
return (DWORD)InfGetFieldCount(Context);
|
|
||||||
}
|
|
||||||
|
|
||||||
BOOL WINAPI
|
|
||||||
InfpGetIntField(
|
|
||||||
IN PINFCONTEXT Context,
|
|
||||||
IN DWORD FieldIndex,
|
|
||||||
OUT PINT IntegerValue)
|
|
||||||
{
|
|
||||||
LONG IntegerValueL;
|
|
||||||
BOOL ret;
|
|
||||||
|
|
||||||
ret = InfGetIntField(Context, FieldIndex, &IntegerValueL);
|
|
||||||
*IntegerValue = (INT)IntegerValueL;
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
BOOL WINAPI
|
BOOL WINAPI
|
||||||
InfpGetMultiSzFieldW(
|
InfpGetMultiSzFieldW(
|
||||||
IN PINFCONTEXT Context,
|
IN PINFCONTEXT Context,
|
||||||
|
|
|
@ -36,10 +36,10 @@
|
||||||
|
|
||||||
#define SetupCloseInfFile InfpCloseInfFile
|
#define SetupCloseInfFile InfpCloseInfFile
|
||||||
#define SetupFindFirstLineW InfpFindFirstLineW
|
#define SetupFindFirstLineW InfpFindFirstLineW
|
||||||
#define SetupFindNextLine InfpFindNextLine
|
#define SetupFindNextLine InfFindNextLine
|
||||||
#define SetupGetBinaryField InfpGetBinaryField
|
#define SetupGetBinaryField InfGetBinaryField
|
||||||
#define SetupGetFieldCount InfpGetFieldCount
|
#define SetupGetFieldCount InfGetFieldCount
|
||||||
#define SetupGetIntField InfpGetIntField
|
#define SetupGetIntField InfGetIntField
|
||||||
#define SetupGetMultiSzFieldW InfpGetMultiSzFieldW
|
#define SetupGetMultiSzFieldW InfpGetMultiSzFieldW
|
||||||
#define SetupGetStringFieldW InfpGetStringFieldW
|
#define SetupGetStringFieldW InfpGetStringFieldW
|
||||||
#define SetupOpenInfFileW InfpOpenInfFileW
|
#define SetupOpenInfFileW InfpOpenInfFileW
|
||||||
|
@ -66,29 +66,6 @@ InfpFindFirstLineW(
|
||||||
IN PCWSTR Key,
|
IN PCWSTR Key,
|
||||||
IN OUT PINFCONTEXT Context);
|
IN OUT PINFCONTEXT Context);
|
||||||
|
|
||||||
BOOL WINAPI
|
|
||||||
InfpFindNextLine(
|
|
||||||
IN PINFCONTEXT ContextIn,
|
|
||||||
OUT PINFCONTEXT ContextOut);
|
|
||||||
|
|
||||||
BOOL WINAPI
|
|
||||||
InfpGetBinaryField(
|
|
||||||
IN PINFCONTEXT Context,
|
|
||||||
IN ULONG FieldIndex,
|
|
||||||
IN OUT BYTE* ReturnBuffer,
|
|
||||||
IN ULONG ReturnBufferSize,
|
|
||||||
OUT PULONG RequiredSize);
|
|
||||||
|
|
||||||
DWORD WINAPI
|
|
||||||
InfpGetFieldCount(
|
|
||||||
IN PINFCONTEXT Context);
|
|
||||||
|
|
||||||
BOOL WINAPI
|
|
||||||
InfpGetIntField(
|
|
||||||
IN PINFCONTEXT Context,
|
|
||||||
IN DWORD FieldIndex,
|
|
||||||
OUT PINT IntegerValue);
|
|
||||||
|
|
||||||
BOOL WINAPI
|
BOOL WINAPI
|
||||||
InfpGetMultiSzFieldW(
|
InfpGetMultiSzFieldW(
|
||||||
IN PINFCONTEXT Context,
|
IN PINFCONTEXT Context,
|
||||||
|
|
|
@ -51,11 +51,10 @@ WCHAR DefaultLanguage[20];
|
||||||
WCHAR DefaultKBLayout[20];
|
WCHAR DefaultKBLayout[20];
|
||||||
BOOLEAN RepairUpdateFlag = FALSE;
|
BOOLEAN RepairUpdateFlag = FALSE;
|
||||||
HANDLE hPnpThread = INVALID_HANDLE_VALUE;
|
HANDLE hPnpThread = INVALID_HANDLE_VALUE;
|
||||||
|
PPARTLIST PartitionList = NULL;
|
||||||
|
|
||||||
/* LOCALS *******************************************************************/
|
/* LOCALS *******************************************************************/
|
||||||
|
|
||||||
static PPARTLIST PartitionList = NULL;
|
|
||||||
|
|
||||||
static PFILE_SYSTEM_LIST FileSystemList = NULL;
|
static PFILE_SYSTEM_LIST FileSystemList = NULL;
|
||||||
|
|
||||||
static UNICODE_STRING InstallPath;
|
static UNICODE_STRING InstallPath;
|
||||||
|
@ -1402,23 +1401,24 @@ LayoutSettingsPage(PINPUT_RECORD Ir)
|
||||||
static BOOL
|
static BOOL
|
||||||
IsDiskSizeValid(PPARTENTRY PartEntry)
|
IsDiskSizeValid(PPARTENTRY PartEntry)
|
||||||
{
|
{
|
||||||
ULONGLONG m;
|
ULONGLONG m1, m2;
|
||||||
|
|
||||||
/* check for unpartitioned space */
|
/* check for unpartitioned space */
|
||||||
m = PartEntry->UnpartitionedLength;
|
m1 = PartEntry->UnpartitionedLength;
|
||||||
m = (m + (1 << 19)) >> 20; /* in MBytes (rounded) */
|
m1 = (m1 + (1 << 19)) >> 20; /* in MBytes (rounded) */
|
||||||
if( m > RequiredPartitionDiskSpace)
|
|
||||||
|
if( m1 > RequiredPartitionDiskSpace)
|
||||||
{
|
{
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* check for partitioned space */
|
/* check for partitioned space */
|
||||||
m = PartEntry->PartInfo[0].PartitionLength.QuadPart;
|
m2 = PartEntry->PartInfo[0].PartitionLength.QuadPart;
|
||||||
m = (m + (1 << 19)) >> 20; /* in MBytes (rounded) */
|
m2 = (m2 + (1 << 19)) >> 20; /* in MBytes (rounded) */
|
||||||
if (m < RequiredPartitionDiskSpace)
|
if (m2 < RequiredPartitionDiskSpace)
|
||||||
{
|
{
|
||||||
/* partition is too small so ask for another partion */
|
/* partition is too small so ask for another partion */
|
||||||
DPRINT1("Partition is too small, required disk space is %lu MB\n", RequiredPartitionDiskSpace);
|
DPRINT1("Partition is too small(unpartitioned: %I64u MB, partitioned: %I64u MB), required disk space is %lu MB\n", m1, m2, RequiredPartitionDiskSpace);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -2450,29 +2450,6 @@ FormatPartitionPage(PINPUT_RECORD Ir)
|
||||||
CheckActiveBootPartition(PartitionList);
|
CheckActiveBootPartition(PartitionList);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Install MBR if necessary */
|
|
||||||
if (DiskEntry->NoMbr &&
|
|
||||||
DiskEntry->BiosDiskNumber == 0)
|
|
||||||
{
|
|
||||||
wcscpy(PathBuffer, SourceRootPath.Buffer);
|
|
||||||
wcscat(PathBuffer, L"\\loader\\dosmbr.bin");
|
|
||||||
|
|
||||||
DPRINT("Install MBR bootcode: %S ==> %S\n",
|
|
||||||
PathBuffer, DestinationRootPath.Buffer);
|
|
||||||
|
|
||||||
/* Install MBR bootcode */
|
|
||||||
Status = InstallMbrBootCodeToDisk(PathBuffer,
|
|
||||||
DestinationRootPath.Buffer);
|
|
||||||
if (!NT_SUCCESS (Status))
|
|
||||||
{
|
|
||||||
DPRINT1("InstallMbrBootCodeToDisk() failed (Status %lx)\n",
|
|
||||||
Status);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
DiskEntry->NoMbr = FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (wcscmp(FileSystemList->Selected->FileSystem, L"FAT") == 0)
|
if (wcscmp(FileSystemList->Selected->FileSystem, L"FAT") == 0)
|
||||||
{
|
{
|
||||||
/* FIXME: Install boot code. This is a hack! */
|
/* FIXME: Install boot code. This is a hack! */
|
||||||
|
@ -3503,7 +3480,7 @@ BootLoaderPage(PINPUT_RECORD Ir)
|
||||||
/* Unattended install on hdd? */
|
/* Unattended install on hdd? */
|
||||||
if (IsUnattendedSetup && UnattendMBRInstallType == 2)
|
if (IsUnattendedSetup && UnattendMBRInstallType == 2)
|
||||||
{
|
{
|
||||||
return BOOT_LOADER_HARDDISK_PAGE;
|
return BOOT_LOADER_HARDDISK_MBR_PAGE;
|
||||||
}
|
}
|
||||||
|
|
||||||
MUIDisplayPage(BOOT_LOADER_PAGE);
|
MUIDisplayPage(BOOT_LOADER_PAGE);
|
||||||
|
@ -3520,9 +3497,9 @@ BootLoaderPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
Line++;
|
Line++;
|
||||||
if (Line<12)
|
if (Line<12)
|
||||||
Line=14;
|
Line=15;
|
||||||
|
|
||||||
if (Line>14)
|
if (Line>15)
|
||||||
Line=12;
|
Line=12;
|
||||||
|
|
||||||
CONSOLE_InvertTextXY(8, Line, 60, 1);
|
CONSOLE_InvertTextXY(8, Line, 60, 1);
|
||||||
|
@ -3534,9 +3511,9 @@ BootLoaderPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
Line--;
|
Line--;
|
||||||
if (Line<12)
|
if (Line<12)
|
||||||
Line=14;
|
Line=15;
|
||||||
|
|
||||||
if (Line>14)
|
if (Line>15)
|
||||||
Line=12;
|
Line=12;
|
||||||
|
|
||||||
CONSOLE_InvertTextXY(8, Line, 60, 1);
|
CONSOLE_InvertTextXY(8, Line, 60, 1);
|
||||||
|
@ -3553,13 +3530,17 @@ BootLoaderPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
if (Line == 12)
|
if (Line == 12)
|
||||||
{
|
{
|
||||||
return BOOT_LOADER_HARDDISK_PAGE;
|
return BOOT_LOADER_HARDDISK_MBR_PAGE;
|
||||||
}
|
}
|
||||||
else if (Line == 13)
|
else if (Line == 13)
|
||||||
{
|
{
|
||||||
return BOOT_LOADER_FLOPPY_PAGE;
|
return BOOT_LOADER_HARDDISK_VBR_PAGE;
|
||||||
}
|
}
|
||||||
else if (Line == 14)
|
else if (Line == 14)
|
||||||
|
{
|
||||||
|
return BOOT_LOADER_FLOPPY_PAGE;
|
||||||
|
}
|
||||||
|
else if (Line == 15)
|
||||||
{
|
{
|
||||||
return SUCCESS_PAGE;
|
return SUCCESS_PAGE;
|
||||||
}
|
}
|
||||||
|
@ -3615,41 +3596,72 @@ BootLoaderFloppyPage(PINPUT_RECORD Ir)
|
||||||
return BOOT_LOADER_FLOPPY_PAGE;
|
return BOOT_LOADER_FLOPPY_PAGE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
BootLoaderHarddiskPage(PINPUT_RECORD Ir)
|
BootLoaderHarddiskVbrPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
UCHAR PartitionType;
|
UCHAR PartitionType;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
|
PartitionType = PartitionList->ActiveBootPartition->
|
||||||
|
PartInfo[PartitionList->ActiveBootPartitionNumber].PartitionType;
|
||||||
|
|
||||||
|
Status = InstallVBRToPartition(&SystemRootPath,
|
||||||
|
&SourceRootPath,
|
||||||
|
&DestinationArcPath,
|
||||||
|
PartitionType);
|
||||||
|
if (!NT_SUCCESS(Status))
|
||||||
|
{
|
||||||
|
MUIDisplayError(ERROR_WRITE_BOOT, Ir, POPUP_WAIT_ENTER);
|
||||||
|
return QUIT_PAGE;
|
||||||
|
}
|
||||||
|
|
||||||
|
return SUCCESS_PAGE;
|
||||||
|
}
|
||||||
|
|
||||||
|
static PAGE_NUMBER
|
||||||
|
BootLoaderHarddiskMbrPage(PINPUT_RECORD Ir)
|
||||||
|
{
|
||||||
|
UCHAR PartitionType;
|
||||||
|
NTSTATUS Status;
|
||||||
|
WCHAR DestinationDevicePathBuffer[MAX_PATH];
|
||||||
|
WCHAR SourceMbrPathBuffer[MAX_PATH];
|
||||||
|
|
||||||
|
/* Step 1: Write the VBR */
|
||||||
PartitionType = PartitionList->ActiveBootPartition->
|
PartitionType = PartitionList->ActiveBootPartition->
|
||||||
PartInfo[PartitionList->ActiveBootPartitionNumber].PartitionType;
|
PartInfo[PartitionList->ActiveBootPartitionNumber].PartitionType;
|
||||||
if ((PartitionType == PARTITION_FAT_12) ||
|
|
||||||
(PartitionType == PARTITION_FAT_16) ||
|
|
||||||
(PartitionType == PARTITION_HUGE) ||
|
|
||||||
(PartitionType == PARTITION_XINT13) ||
|
|
||||||
(PartitionType == PARTITION_FAT32) ||
|
|
||||||
(PartitionType == PARTITION_FAT32_XINT13))
|
|
||||||
{
|
|
||||||
Status = InstallFatBootcodeToPartition(&SystemRootPath,
|
|
||||||
&SourceRootPath,
|
|
||||||
&DestinationArcPath,
|
|
||||||
PartitionType);
|
|
||||||
if (!NT_SUCCESS(Status))
|
|
||||||
{
|
|
||||||
MUIDisplayError(ERROR_INSTALL_BOOTCODE, Ir, POPUP_WAIT_ENTER);
|
|
||||||
return QUIT_PAGE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return SUCCESS_PAGE;
|
Status = InstallVBRToPartition(&SystemRootPath,
|
||||||
}
|
&SourceRootPath,
|
||||||
else
|
&DestinationArcPath,
|
||||||
|
PartitionType);
|
||||||
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
MUIDisplayError(ERROR_WRITE_BOOT, Ir, POPUP_WAIT_ENTER);
|
MUIDisplayError(ERROR_WRITE_BOOT, Ir, POPUP_WAIT_ENTER);
|
||||||
return QUIT_PAGE;
|
return QUIT_PAGE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return BOOT_LOADER_HARDDISK_PAGE;
|
/* Step 2: Write the MBR */
|
||||||
|
swprintf(DestinationDevicePathBuffer,
|
||||||
|
L"\\Device\\Harddisk%d\\Partition0",
|
||||||
|
PartitionList->ActiveBootDisk->DiskNumber);
|
||||||
|
|
||||||
|
wcscpy(SourceMbrPathBuffer, SourceRootPath.Buffer);
|
||||||
|
wcscat(SourceMbrPathBuffer, L"\\loader\\dosmbr.bin");
|
||||||
|
|
||||||
|
DPRINT("Install MBR bootcode: %S ==> %S\n",
|
||||||
|
SourceMbrPathBuffer, DestinationDevicePathBuffer);
|
||||||
|
|
||||||
|
Status = InstallMbrBootCodeToDisk(SourceMbrPathBuffer,
|
||||||
|
DestinationDevicePathBuffer);
|
||||||
|
if (!NT_SUCCESS (Status))
|
||||||
|
{
|
||||||
|
DPRINT1("InstallMbrBootCodeToDisk() failed (Status %lx)\n",
|
||||||
|
Status);
|
||||||
|
MUIDisplayError(ERROR_INSTALL_BOOTCODE, Ir, POPUP_WAIT_ENTER);
|
||||||
|
return QUIT_PAGE;
|
||||||
|
}
|
||||||
|
|
||||||
|
return SUCCESS_PAGE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -3916,8 +3928,12 @@ RunUSetup(VOID)
|
||||||
Page = BootLoaderFloppyPage(&Ir);
|
Page = BootLoaderFloppyPage(&Ir);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BOOT_LOADER_HARDDISK_PAGE:
|
case BOOT_LOADER_HARDDISK_MBR_PAGE:
|
||||||
Page = BootLoaderHarddiskPage(&Ir);
|
Page = BootLoaderHarddiskMbrPage(&Ir);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case BOOT_LOADER_HARDDISK_VBR_PAGE:
|
||||||
|
Page = BootLoaderHarddiskVbrPage(&Ir);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
/* Repair pages */
|
/* Repair pages */
|
||||||
|
|
|
@ -995,18 +995,24 @@ static MUI_ENTRY bgBGBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"‘« £ ¥ § ०¤ η βΆκΰ¤¨ο ¤¨α<C2A8> (Ά MBR).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"‘« £ ¥ § ०¤ η ¤¨α<C2A8>¥β .",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"‘« £ ¥ § ०¤ ç ¤¨áª¥â .",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"„ ¥ ᥠ᫠£ § ०¤ ç.",
|
"„ ¥ ᥠ᫠£ § ०¤ ç.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -993,18 +993,24 @@ static MUI_ENTRY csCZBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Nainstalovat zavad؟ na disk (MBR).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Nainstalovat zavad؟ na disketu.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Nainstalovat zavad؟ na disketu.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"PýeskoŸit instalaci zavadØŸe.",
|
"PýeskoŸit instalaci zavadØŸe.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -578,7 +578,7 @@ static MUI_ENTRY deDEFlushPageEntries[] =
|
||||||
{
|
{
|
||||||
10,
|
10,
|
||||||
9,
|
9,
|
||||||
"Der PC wird automatisch neunstarten, wenn der Vorgang beendet ist.",
|
"Der PC wird automatisch neustarten, wenn der Vorgang beendet ist.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -986,18 +986,24 @@ static MUI_ENTRY deDEBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Boot-Loader auf der Festplatte installieren (Bootsektor).",
|
"Boot-Loader auf der Festplatte installieren (MBR und VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Boot-Loader auf einer Diskette installieren.",
|
"Boot-Loader auf der Festplatte installieren (nur VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Boot-Loader auf einer Diskette installieren.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Boot-Loader nicht installieren.",
|
"Boot-Loader nicht installieren.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -1009,18 +1009,24 @@ static MUI_ENTRY elGRBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"„š¡˜«á©«˜©ž «¦¬ bootloader ©«¦ ©¡¢ž¨æ ›å©¡¦ (MBR).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"„š¡˜«á©«˜©ž «¦¬ bootloader ©œ £ ˜ › ©¡â«˜.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"„š¡˜«á©«˜©ž «¦¬ bootloader ©œ £ ˜ › ©¡â«˜.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Œ˜ £ž šå¤œ œš¡˜«á©«˜©ž «¦¬ bootloader.",
|
"Œ˜ £ž šå¤œ œš¡˜«á©«˜©ž «¦¬ bootloader.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -985,18 +985,24 @@ static MUI_ENTRY enUSBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Install bootloader on the harddisk (bootsector).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Install bootloader on a floppy disk.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Install bootloader on a floppy disk.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Skip install bootloader.",
|
"Skip install bootloader.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -992,18 +992,24 @@ static MUI_ENTRY esESBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Instalar cargador de arranque en el disco duro (sector de boot).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Instalar cargador de inicio en un disquete.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Instalar cargador de inicio en un disquete.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Omitir la instalaci¢n del cargador de arranque.",
|
"Omitir la instalaci¢n del cargador de arranque.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -985,18 +985,24 @@ static MUI_ENTRY etEEBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Paigalda alglaadur kävakettale (MBR).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Paigalda alglaadur flopikettale.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Paigalda alglaadur flopikettale.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Žra paigalda alglaadurit.",
|
"Žra paigalda alglaadurit.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -998,18 +998,24 @@ static MUI_ENTRY frFRBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Installer le chargeur de d‚marrage sur le disque dur (MBR).",
|
"Installer le chargeur de d‚marrage sur le disque (MBR et VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Installer le chargeur de d‚marrage sur une disquette.",
|
"Installer le chargeur de d‚marrage sur le disque (VBR seulement).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Installer le chargeur de d‚marrage sur une disquette.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Ne pas installer le chargeur de d‚marrage.",
|
"Ne pas installer le chargeur de d‚marrage.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
@ -1090,7 +1096,7 @@ static MUI_ENTRY frFRLayoutSettingsEntries[] =
|
||||||
{
|
{
|
||||||
6,
|
6,
|
||||||
8,
|
8,
|
||||||
"Please select a layout to be installed by default.",
|
"Veuillez s‚lectionner une disposition … installer par d‚faut.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -1481,18 +1487,18 @@ MUI_ERROR frFRErrorEntries[] =
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
//ERROR_ADDING_KBLAYOUTS,
|
//ERROR_ADDING_KBLAYOUTS,
|
||||||
"Setup failed to add keyboard layouts to registry.\n"
|
"Setup n'a pas pu ajouter les dispositions de clavier au registre.\n"
|
||||||
"ENTER = Reboot computer"
|
"ENTER = Red‚marrer l'ordinateur"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
//ERROR_UPDATE_GEOID,
|
//ERROR_UPDATE_GEOID,
|
||||||
"Setup could not set the geo id.\n"
|
"Setup n'a pas pu d‚finir la geo id.\n"
|
||||||
"ENTER = Reboot computer"
|
"ENTER = Red‚marrer l'ordinateur"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
//ERROR_INSUFFICIENT_DISKSPACE,
|
//ERROR_INSUFFICIENT_DISKSPACE,
|
||||||
"Not enough free space in the selected partition.\n"
|
"Pas assez d'espace libre dans la partition s‚lectionn‚e.\n"
|
||||||
" * Press any key to continue.",
|
" * Appuyez sur n'importe quelle touche pour continuer.",
|
||||||
NULL
|
NULL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -1709,6 +1715,6 @@ MUI_STRING frFRStrings[] =
|
||||||
{STRING_GB,
|
{STRING_GB,
|
||||||
"Go"},
|
"Go"},
|
||||||
{STRING_ADDKBLAYOUTS,
|
{STRING_ADDKBLAYOUTS,
|
||||||
"Adding keyboard layouts"},
|
"Ajout des dispositions clavier"},
|
||||||
{0, 0}
|
{0, 0}
|
||||||
};
|
};
|
||||||
|
|
|
@ -986,18 +986,24 @@ static MUI_ENTRY itITBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Installazione del bootloader sul disco fisso (settore di avvio).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Installazione del bootloader su un disco floppy.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Installazione del bootloader su un disco floppy.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Salta l'installazione del bootloader.",
|
"Salta l'installazione del bootloader.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -986,18 +986,24 @@ static MUI_ENTRY jaJPBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"ブートローダヲ ハードディスク (ブートセクタ)ニ インストール スル。",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"ブートローダヲ フロッピー ディスクニ インストール スル。",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"ÌÞ°ÄÛ°ÀÞ¦ ÌÛ¯Ëß° ÃÞ¨½¸Æ ²Ý½Ä°Ù ½Ù¡",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"ÌÞ°ÄÛ°ÀÞÉ ²Ý½Ä°Ù¦ ½·¯Ìß ½Ù¡",
|
"ÌÞ°ÄÛ°ÀÞÉ ²Ý½Ä°Ù¦ ½·¯Ìß ½Ù¡",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -995,18 +995,24 @@ static MUI_ENTRY ltLTBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Install bootloader on the harddisk (MBR).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Install bootloader on a floppy disk.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Install bootloader on a floppy disk.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Skip install bootloader.",
|
"Skip install bootloader.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -1012,18 +1012,24 @@ static MUI_ENTRY nlNLBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Installeer de bootloader op de harde schijf (bootsector).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Installeer de bootloader op een floppy disk.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Installeer de bootloader op een floppy disk.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Installeren bootloader overslaan.",
|
"Installeren bootloader overslaan.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -994,18 +994,24 @@ static MUI_ENTRY plPLBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
" Wgraj bootloader na dysk twardy (MBR).",
|
"Wgraj bootloader na dysk twardy (MBR i VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
" Wgraj bootloader na dyskietk©.",
|
"Wgraj bootloader na dysk twardy (tylko VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
" Wgraj bootloader na dyskietk©.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
" Pomiä wgrywanie bootloadera.",
|
" Pomiä wgrywanie bootloadera.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -986,18 +986,24 @@ static MUI_ENTRY ruRUBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"“αβ ®Ά<EFBFBD> ¦¥αβ<CEB1>¨© ¤¨α<C2A8> (§ £ΰ㧮ηλ© α¥<CEB1>β®ΰ).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"“αβ ®Ά<EFBFBD> £¨΅<C2A8>¨© ¤¨α<C2A8>.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"“áâ ®¢ª £¨¡ª¨© ¤¨áª.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"<EFBFBD>¥ ãáâ ¢«¨¢ âì § £àã§ç¨ª.",
|
"<EFBFBD>¥ ãáâ ¢«¨¢ âì § £àã§ç¨ª.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -993,18 +993,24 @@ static MUI_ENTRY skSKBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Nainçtalovaś zav dzaź syst‚mu na pevně disk (zav dzacˇ sektor).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Nainçtalovaś zav dzaź syst‚mu na disketu.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Nainçtalovaœ zav dzaŸ syst‚mu na disketu.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"PreskoŸiœ inçtal ciu zav dzaŸa syst‚mu.",
|
"PreskoŸiœ inçtal ciu zav dzaŸa syst‚mu.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -986,18 +986,24 @@ static MUI_ENTRY svSEBootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"Install bootloader on the harddisk (MBR).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"Install bootloader on a floppy disk.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"Install bootloader on a floppy disk.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"Skip install bootloader.",
|
"Skip install bootloader.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -991,18 +991,24 @@ static MUI_ENTRY ukUABootLoaderEntries[] =
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
12,
|
12,
|
||||||
"‚áâ ®¢¨â¨ bootloader ¦®àá⪨© ¤¨áª (bootsector).",
|
"Install bootloader on the harddisk (MBR and VBR).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
13,
|
13,
|
||||||
"‚áâ ®¢¨â¨ bootloader ¤¨áª¥âã.",
|
"Install bootloader on the harddisk (VBR only).",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
8,
|
8,
|
||||||
14,
|
14,
|
||||||
|
"‚áâ ®¢¨â¨ bootloader ¤¨áª¥âã.",
|
||||||
|
TEXT_STYLE_NORMAL
|
||||||
|
},
|
||||||
|
{
|
||||||
|
8,
|
||||||
|
15,
|
||||||
"<EFBFBD>¥ ¢áâ ®¢«î¢ ⨠bootloader.",
|
"<EFBFBD>¥ ¢áâ ®¢«î¢ ⨠bootloader.",
|
||||||
TEXT_STYLE_NORMAL
|
TEXT_STYLE_NORMAL
|
||||||
},
|
},
|
||||||
|
|
|
@ -232,7 +232,7 @@ const MUI_LANGUAGE LanguageList[] =
|
||||||
{L"00000814", L"1252", L"850", L"10000", L"Norwegian (Nynorsk)", L"47", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, nnNOLayouts },
|
{L"00000814", L"1252", L"850", L"10000", L"Norwegian (Nynorsk)", L"47", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, nnNOLayouts },
|
||||||
{L"00000415", L"1250", L"852", L"10029", L"Polish", L"48", plPLPages, plPLErrorEntries, plPLStrings, LatinFonts, plPLLayouts },
|
{L"00000415", L"1250", L"852", L"10029", L"Polish", L"48", plPLPages, plPLErrorEntries, plPLStrings, LatinFonts, plPLLayouts },
|
||||||
{L"00000816", L"1252", L"850", L"10000", L"Portuguese (Portugal)", L"351", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, ptPTLayouts },
|
{L"00000816", L"1252", L"850", L"10000", L"Portuguese (Portugal)", L"351", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, ptPTLayouts },
|
||||||
{L"00000416", L"1252", L"850", L"10000", L"Portuguese (Brazil)", L"55", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, ptBRLayouts },
|
{L"00000416", L"1252", L"850", L"10000", L"Portuguese (Brazil)", L"55", ptBRPages, ptBRErrorEntries, ptBRStrings, LatinFonts, ptBRLayouts },
|
||||||
{L"00000446", L"0", L"1", L"2", L"Punjabi (India)", L"91", enUSPages, enUSErrorEntries, enUSStrings, UnicodeFonts, paINLayouts },
|
{L"00000446", L"0", L"1", L"2", L"Punjabi (India)", L"91", enUSPages, enUSErrorEntries, enUSStrings, UnicodeFonts, paINLayouts },
|
||||||
{L"00000418", L"1250", L"852", L"10029", L"Romanian", L"40", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, roROLayouts },
|
{L"00000418", L"1250", L"852", L"10029", L"Romanian", L"40", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, roROLayouts },
|
||||||
{L"00000417", L"1252", L"850", L"10000", L"Romansh", L"41", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, rmCHLayouts },
|
{L"00000417", L"1252", L"850", L"10000", L"Romansh", L"41", enUSPages, enUSErrorEntries, enUSStrings, LatinFonts, rmCHLayouts },
|
||||||
|
|
|
@ -701,6 +701,7 @@ AddDiskToList (HANDLE FileHandle,
|
||||||
ULONG i;
|
ULONG i;
|
||||||
PLIST_ENTRY ListEntry;
|
PLIST_ENTRY ListEntry;
|
||||||
PBIOSDISKENTRY BiosDiskEntry;
|
PBIOSDISKENTRY BiosDiskEntry;
|
||||||
|
ULONG LayoutBufferSize;
|
||||||
|
|
||||||
Status = NtDeviceIoControlFile (FileHandle,
|
Status = NtDeviceIoControlFile (FileHandle,
|
||||||
NULL,
|
NULL,
|
||||||
|
@ -870,9 +871,15 @@ AddDiskToList (HANDLE FileHandle,
|
||||||
|
|
||||||
InsertAscendingList(&List->DiskListHead, DiskEntry, DISKENTRY, ListEntry, BiosDiskNumber);
|
InsertAscendingList(&List->DiskListHead, DiskEntry, DISKENTRY, ListEntry, BiosDiskNumber);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Allocate a buffer for 26 logical drives (2 entries each == 52)
|
||||||
|
* plus the main partiton table (4 entries). Total 56 entries.
|
||||||
|
*/
|
||||||
|
LayoutBufferSize = sizeof(DRIVE_LAYOUT_INFORMATION) +
|
||||||
|
((56 - ANYSIZE_ARRAY) * sizeof(PARTITION_INFORMATION));
|
||||||
LayoutBuffer = (DRIVE_LAYOUT_INFORMATION*)RtlAllocateHeap (ProcessHeap,
|
LayoutBuffer = (DRIVE_LAYOUT_INFORMATION*)RtlAllocateHeap (ProcessHeap,
|
||||||
0,
|
0,
|
||||||
8192);
|
LayoutBufferSize);
|
||||||
if (LayoutBuffer == NULL)
|
if (LayoutBuffer == NULL)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
|
@ -887,7 +894,7 @@ AddDiskToList (HANDLE FileHandle,
|
||||||
NULL,
|
NULL,
|
||||||
0,
|
0,
|
||||||
LayoutBuffer,
|
LayoutBuffer,
|
||||||
8192);
|
LayoutBufferSize);
|
||||||
if (NT_SUCCESS (Status))
|
if (NT_SUCCESS (Status))
|
||||||
{
|
{
|
||||||
if (LayoutBuffer->PartitionCount == 0)
|
if (LayoutBuffer->PartitionCount == 0)
|
||||||
|
@ -1956,6 +1963,8 @@ CreateNewPartition (PPARTLIST List,
|
||||||
PartEntry->FormatState = Unformatted;
|
PartEntry->FormatState = Unformatted;
|
||||||
PartEntry->PartInfo[0].StartingOffset.QuadPart =
|
PartEntry->PartInfo[0].StartingOffset.QuadPart =
|
||||||
PartEntry->UnpartitionedOffset + DiskEntry->TrackSize;
|
PartEntry->UnpartitionedOffset + DiskEntry->TrackSize;
|
||||||
|
PartEntry->PartInfo[0].HiddenSectors =
|
||||||
|
PartEntry->PartInfo[0].StartingOffset.QuadPart / DiskEntry->BytesPerSector;
|
||||||
PartEntry->PartInfo[0].PartitionLength.QuadPart =
|
PartEntry->PartInfo[0].PartitionLength.QuadPart =
|
||||||
PartEntry->UnpartitionedLength - DiskEntry->TrackSize;
|
PartEntry->UnpartitionedLength - DiskEntry->TrackSize;
|
||||||
PartEntry->PartInfo[0].PartitionType = PARTITION_ENTRY_UNUSED;
|
PartEntry->PartInfo[0].PartitionType = PARTITION_ENTRY_UNUSED;
|
||||||
|
@ -1985,6 +1994,8 @@ CreateNewPartition (PPARTLIST List,
|
||||||
|
|
||||||
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
||||||
PartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
PartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
||||||
|
PrevPartEntry->PartInfo[1].HiddenSectors =
|
||||||
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart / DiskEntry->BytesPerSector;
|
||||||
|
|
||||||
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
||||||
{
|
{
|
||||||
|
@ -2011,6 +2022,8 @@ CreateNewPartition (PPARTLIST List,
|
||||||
|
|
||||||
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
||||||
PartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
PartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
||||||
|
PrevPartEntry->PartInfo[1].HiddenSectors =
|
||||||
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart / DiskEntry->BytesPerSector;
|
||||||
|
|
||||||
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
||||||
{
|
{
|
||||||
|
@ -2066,6 +2079,8 @@ CreateNewPartition (PPARTLIST List,
|
||||||
NewPartEntry->FormatState = Unformatted;
|
NewPartEntry->FormatState = Unformatted;
|
||||||
NewPartEntry->PartInfo[0].StartingOffset.QuadPart =
|
NewPartEntry->PartInfo[0].StartingOffset.QuadPart =
|
||||||
PartEntry->UnpartitionedOffset + DiskEntry->TrackSize;
|
PartEntry->UnpartitionedOffset + DiskEntry->TrackSize;
|
||||||
|
NewPartEntry->PartInfo[0].HiddenSectors =
|
||||||
|
NewPartEntry->PartInfo[0].StartingOffset.QuadPart / DiskEntry->BytesPerSector;
|
||||||
NewPartEntry->PartInfo[0].PartitionLength.QuadPart =
|
NewPartEntry->PartInfo[0].PartitionLength.QuadPart =
|
||||||
PartitionSize - DiskEntry->TrackSize;
|
PartitionSize - DiskEntry->TrackSize;
|
||||||
NewPartEntry->PartInfo[0].PartitionType = PARTITION_ENTRY_UNUSED;
|
NewPartEntry->PartInfo[0].PartitionType = PARTITION_ENTRY_UNUSED;
|
||||||
|
@ -2095,6 +2110,8 @@ CreateNewPartition (PPARTLIST List,
|
||||||
|
|
||||||
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
||||||
NewPartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
NewPartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
||||||
|
PrevPartEntry->PartInfo[1].HiddenSectors =
|
||||||
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart / DiskEntry->BytesPerSector;
|
||||||
|
|
||||||
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
||||||
{
|
{
|
||||||
|
@ -2121,6 +2138,8 @@ CreateNewPartition (PPARTLIST List,
|
||||||
|
|
||||||
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart =
|
||||||
NewPartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
NewPartEntry->PartInfo[0].StartingOffset.QuadPart - DiskEntry->TrackSize;
|
||||||
|
PrevPartEntry->PartInfo[1].HiddenSectors =
|
||||||
|
PrevPartEntry->PartInfo[1].StartingOffset.QuadPart / DiskEntry->BytesPerSector;
|
||||||
|
|
||||||
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
if (DiskEntry->PartListHead.Flink == &PrevPartEntry->ListEntry)
|
||||||
{
|
{
|
||||||
|
|
|
@ -50,6 +50,7 @@
|
||||||
/* Internal Headers */
|
/* Internal Headers */
|
||||||
#include "interface/consup.h"
|
#include "interface/consup.h"
|
||||||
#include "partlist.h"
|
#include "partlist.h"
|
||||||
|
#include "infros.h"
|
||||||
#include "inffile.h"
|
#include "inffile.h"
|
||||||
#include "inicache.h"
|
#include "inicache.h"
|
||||||
#include "progress.h"
|
#include "progress.h"
|
||||||
|
@ -107,7 +108,8 @@ typedef enum _PAGE_NUMBER
|
||||||
REGISTRY_PAGE,
|
REGISTRY_PAGE,
|
||||||
BOOT_LOADER_PAGE,
|
BOOT_LOADER_PAGE,
|
||||||
BOOT_LOADER_FLOPPY_PAGE,
|
BOOT_LOADER_FLOPPY_PAGE,
|
||||||
BOOT_LOADER_HARDDISK_PAGE,
|
BOOT_LOADER_HARDDISK_MBR_PAGE,
|
||||||
|
BOOT_LOADER_HARDDISK_VBR_PAGE,
|
||||||
|
|
||||||
REPAIR_INTRO_PAGE,
|
REPAIR_INTRO_PAGE,
|
||||||
|
|
||||||
|
|
|
@ -145,7 +145,7 @@ BEGIN
|
||||||
CONTROL "&Êîìàíäà:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
|
CONTROL "&Êîìàíäà:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
|
||||||
18,60,10
|
18,60,10
|
||||||
EDITTEXT 201,3,29,134,12,ES_AUTOHSCROLL
|
EDITTEXT 201,3,29,134,12,ES_AUTOHSCROLL
|
||||||
CONTROL "As &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
|
CONTROL "&Як Символ",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
|
||||||
45,71,12
|
45,71,12
|
||||||
DEFPUSHBUTTON "&OK",1,158,6,47,14
|
DEFPUSHBUTTON "&OK",1,158,6,47,14
|
||||||
PUSHBUTTON "&Ñêàñóâàòè",2,158,23,47,14
|
PUSHBUTTON "&Ñêàñóâàòè",2,158,23,47,14
|
||||||
|
@ -169,7 +169,7 @@ END
|
||||||
|
|
||||||
IDD_DESKBAR_DESKTOP DIALOGEX DISCARDABLE 0, 0, 212, 194
|
IDD_DESKBAR_DESKTOP DIALOGEX DISCARDABLE 0, 0, 212, 194
|
||||||
STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION
|
STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION
|
||||||
CAPTION "Властивості робочого стола"
|
CAPTION "Властивості робочого столу"
|
||||||
FONT 8, "MS Shell Dlg"
|
FONT 8, "MS Shell Dlg"
|
||||||
BEGIN
|
BEGIN
|
||||||
LTEXT "Îáåð³òü íàéá³ëüø çðó÷íèé äëÿ âàñ àëãîðèòì âèð³âíþâàííÿ çíà÷ê³â:",
|
LTEXT "Îáåð³òü íàéá³ëüø çðó÷íèé äëÿ âàñ àëãîðèòì âèð³âíþâàííÿ çíà÷ê³â:",
|
||||||
|
@ -268,11 +268,11 @@ BEGIN
|
||||||
BS_AUTORADIOBUTTON,7,62,118,10
|
BS_AUTORADIOBUTTON,7,62,118,10
|
||||||
CONTROL 170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
|
CONTROL 170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
|
||||||
CONTROL 171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
|
CONTROL 171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
|
||||||
CONTROL "Відкривати підпапки в о&кремих вікнах",
|
CONTROL "Відкривати підтеки в о&кремих вікнах",
|
||||||
IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX |
|
IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX |
|
||||||
WS_TABSTOP,7,90,135,10
|
WS_TABSTOP,7,90,135,10
|
||||||
LTEXT "Ці настройки будуть використані як значення за замовчуванням для всіх вікон провідника в майбутньому.",
|
LTEXT "Ці параметри будуть використані як значення за замовчуванням для всіх вікон провідника в майбутньому.",
|
||||||
IDC_STATIC,7,111,174,22
|
IDC_STATIC,7,109,174,24
|
||||||
DEFPUSHBUTTON "&OK",IDOK,29,136,50,14,WS_GROUP
|
DEFPUSHBUTTON "&OK",IDOK,29,136,50,14,WS_GROUP
|
||||||
PUSHBUTTON "&Ñêàñóâàòè",IDCANCEL,106,136,50,14
|
PUSHBUTTON "&Ñêàñóâàòè",IDCANCEL,106,136,50,14
|
||||||
END
|
END
|
||||||
|
|
|
@ -39,9 +39,7 @@
|
||||||
#include <windowsx.h> // for SelectBrush(), ListBox_SetSel(), SubclassWindow(), ...
|
#include <windowsx.h> // for SelectBrush(), ListBox_SetSel(), SubclassWindow(), ...
|
||||||
#include <commctrl.h>
|
#include <commctrl.h>
|
||||||
|
|
||||||
#ifndef _MSC_VER
|
|
||||||
#include <objbase.h>
|
#include <objbase.h>
|
||||||
#endif
|
|
||||||
#include <oleauto.h> // for VARIANT
|
#include <oleauto.h> // for VARIANT
|
||||||
|
|
||||||
#include <malloc.h> // for alloca()
|
#include <malloc.h> // for alloca()
|
||||||
|
|
|
@ -80,6 +80,42 @@ ScmCreateStartEvent(PHANDLE StartEvent)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
ScmWaitForLsass(VOID)
|
||||||
|
{
|
||||||
|
HANDLE hEvent;
|
||||||
|
DWORD dwError;
|
||||||
|
|
||||||
|
hEvent = CreateEventW(NULL,
|
||||||
|
TRUE,
|
||||||
|
FALSE,
|
||||||
|
L"LSA_RPC_SERVER_ACTIVE");
|
||||||
|
if (hEvent == NULL)
|
||||||
|
{
|
||||||
|
dwError = GetLastError();
|
||||||
|
DPRINT("Failed to create the notication event (Error %lu)\n", dwError);
|
||||||
|
|
||||||
|
if (dwError == ERROR_ALREADY_EXISTS)
|
||||||
|
{
|
||||||
|
hEvent = OpenEventW(SYNCHRONIZE,
|
||||||
|
FALSE,
|
||||||
|
L"LSA_RPC_SERVER_ACTIVE");
|
||||||
|
if (hEvent == NULL)
|
||||||
|
{
|
||||||
|
DPRINT1("Could not open the notification event (Error %lu)\n", GetLastError());
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
DPRINT("Wait for the LSA server!\n");
|
||||||
|
WaitForSingleObject(hEvent, INFINITE);
|
||||||
|
DPRINT("LSA server running!\n");
|
||||||
|
|
||||||
|
CloseHandle(hEvent);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOL
|
BOOL
|
||||||
ScmNamedPipeHandleRequest(PVOID Request,
|
ScmNamedPipeHandleRequest(PVOID Request,
|
||||||
DWORD RequestSize,
|
DWORD RequestSize,
|
||||||
|
@ -304,9 +340,6 @@ wWinMain(HINSTANCE hInstance,
|
||||||
|
|
||||||
DPRINT("SERVICES: Service Control Manager\n");
|
DPRINT("SERVICES: Service Control Manager\n");
|
||||||
|
|
||||||
/* Acquire privileges to load drivers */
|
|
||||||
AcquireLoadDriverPrivilege();
|
|
||||||
|
|
||||||
/* Create start event */
|
/* Create start event */
|
||||||
if (!ScmCreateStartEvent(&hScmStartEvent))
|
if (!ScmCreateStartEvent(&hScmStartEvent))
|
||||||
{
|
{
|
||||||
|
@ -346,6 +379,12 @@ wWinMain(HINSTANCE hInstance,
|
||||||
/* Register event handler (used for system shutdown) */
|
/* Register event handler (used for system shutdown) */
|
||||||
SetConsoleCtrlHandler(ShutdownHandlerRoutine, TRUE);
|
SetConsoleCtrlHandler(ShutdownHandlerRoutine, TRUE);
|
||||||
|
|
||||||
|
/* Wait for the LSA server */
|
||||||
|
ScmWaitForLsass();
|
||||||
|
|
||||||
|
/* Acquire privileges to load drivers */
|
||||||
|
AcquireLoadDriverPrivilege();
|
||||||
|
|
||||||
/* Start auto-start services */
|
/* Start auto-start services */
|
||||||
ScmAutoStartServices();
|
ScmAutoStartServices();
|
||||||
|
|
||||||
|
|
|
@ -167,7 +167,7 @@ StartLsass(VOID)
|
||||||
LPCWSTR ServiceString = L"lsass.exe";
|
LPCWSTR ServiceString = L"lsass.exe";
|
||||||
BOOL res;
|
BOOL res;
|
||||||
|
|
||||||
/* Start the service control manager (services.exe) */
|
/* Start the local security authority subsystem (lsass.exe) */
|
||||||
ZeroMemory(&StartupInfo, sizeof(STARTUPINFOW));
|
ZeroMemory(&StartupInfo, sizeof(STARTUPINFOW));
|
||||||
StartupInfo.cb = sizeof(StartupInfo);
|
StartupInfo.cb = sizeof(StartupInfo);
|
||||||
StartupInfo.lpReserved = NULL;
|
StartupInfo.lpReserved = NULL;
|
||||||
|
@ -199,6 +199,43 @@ StartLsass(VOID)
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
WaitForLsass(VOID)
|
||||||
|
{
|
||||||
|
HANDLE hEvent;
|
||||||
|
DWORD dwError;
|
||||||
|
|
||||||
|
hEvent = CreateEventW(NULL,
|
||||||
|
TRUE,
|
||||||
|
FALSE,
|
||||||
|
L"LSA_RPC_SERVER_ACTIVE");
|
||||||
|
if (hEvent == NULL)
|
||||||
|
{
|
||||||
|
dwError = GetLastError();
|
||||||
|
TRACE("WL: Failed to create the notication event (Error %lu)\n", dwError);
|
||||||
|
|
||||||
|
if (dwError == ERROR_ALREADY_EXISTS)
|
||||||
|
{
|
||||||
|
hEvent = OpenEventW(SYNCHRONIZE,
|
||||||
|
FALSE,
|
||||||
|
L"LSA_RPC_SERVER_ACTIVE");
|
||||||
|
if (hEvent == NULL)
|
||||||
|
{
|
||||||
|
ERR("WL: Could not open the notification event (Error %lu)\n", GetLastError());
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
TRACE("WL: Wait for the LSA server!\n");
|
||||||
|
WaitForSingleObject(hEvent, INFINITE);
|
||||||
|
TRACE("WL: LSA server running!\n");
|
||||||
|
|
||||||
|
CloseHandle(hEvent);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOL
|
BOOL
|
||||||
DisplayStatusMessage(
|
DisplayStatusMessage(
|
||||||
IN PWLSESSION Session,
|
IN PWLSESSION Session,
|
||||||
|
@ -348,6 +385,10 @@ WinMain(
|
||||||
|
|
||||||
DisplayStatusMessage(WLSession, WLSession->WinlogonDesktop, IDS_REACTOSISSTARTINGUP);
|
DisplayStatusMessage(WLSession, WLSession->WinlogonDesktop, IDS_REACTOSISSTARTINGUP);
|
||||||
|
|
||||||
|
|
||||||
|
/* Wait for the LSA server */
|
||||||
|
WaitForLsass();
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
/* Connect to NetLogon service (lsass.exe) */
|
/* Connect to NetLogon service (lsass.exe) */
|
||||||
/* Real winlogon uses "Winlogon" */
|
/* Real winlogon uses "Winlogon" */
|
||||||
|
@ -415,7 +456,7 @@ WinMain(
|
||||||
|
|
||||||
/* Tell kernel that CurrentControlSet is good (needed
|
/* Tell kernel that CurrentControlSet is good (needed
|
||||||
* to support Last good known configuration boot) */
|
* to support Last good known configuration boot) */
|
||||||
NtInitializeRegistry(CM_BOOT_FLAG_ACCEPTED);
|
NtInitializeRegistry(CM_BOOT_FLAG_ACCEPTED | 1);
|
||||||
|
|
||||||
/* Message loop for the SAS window */
|
/* Message loop for the SAS window */
|
||||||
while (GetMessageW(&Msg, WLSession->SASWindow, 0, 0))
|
while (GetMessageW(&Msg, WLSession->SASWindow, 0, 0))
|
||||||
|
|
|
@ -81,6 +81,7 @@ list(APPEND FREELDR_BASE_SOURCE
|
||||||
freeldr/freeldr/video/palette.c
|
freeldr/freeldr/video/palette.c
|
||||||
freeldr/freeldr/video/video.c
|
freeldr/freeldr/video/video.c
|
||||||
freeldr/freeldr/windows/conversion.c
|
freeldr/freeldr/windows/conversion.c
|
||||||
|
freeldr/freeldr/windows/headless.c
|
||||||
freeldr/freeldr/windows/peloader.c
|
freeldr/freeldr/windows/peloader.c
|
||||||
freeldr/freeldr/windows/winldr.c
|
freeldr/freeldr/windows/winldr.c
|
||||||
freeldr/freeldr/windows/wlmemory.c
|
freeldr/freeldr/windows/wlmemory.c
|
||||||
|
@ -176,6 +177,7 @@ target_link_libraries(freeldr mini_hal)
|
||||||
endif(ARCH MATCHES i386)
|
endif(ARCH MATCHES i386)
|
||||||
|
|
||||||
target_link_libraries(freeldr
|
target_link_libraries(freeldr
|
||||||
|
cportlib
|
||||||
rossym
|
rossym
|
||||||
cmlib
|
cmlib
|
||||||
rtl
|
rtl
|
||||||
|
@ -198,6 +200,7 @@ target_link_libraries(setupldr mini_hal)
|
||||||
endif(ARCH MATCHES i386)
|
endif(ARCH MATCHES i386)
|
||||||
|
|
||||||
target_link_libraries(setupldr
|
target_link_libraries(setupldr
|
||||||
|
cportlib
|
||||||
rossym
|
rossym
|
||||||
cmlib
|
cmlib
|
||||||
rtl
|
rtl
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue