mirror of
https://github.com/reactos/reactos.git
synced 2024-06-22 05:51:29 +00:00
[0.4.13][PARPORT] Fix I/O port length check, [REACTOS] Logging & formatting, e.g. CORE-14388 CORE-19105
Ports back a real fix: 0.4.15-dev-1173-gba09834c5e
[PARPORT] Fix I/O port length check Ports back logging and formatting: 0.4.15-dev-6794-g4eace8d762
[IPHLPAPI] Silence obsolete FIXME in GetAdaptersAddresses (#5834) CORE-14388 0.4.15-dev-6438-gb12ab486d8
[MUP] Mute DPRINT1's that slow down shared folder accesses (#5545) CORE-19105 And mutes some other loggings as well for stuff, that I either never want to port back, e.g. the IMM-implementations, or which is not really helpful in the older branches: fixme:(win32ss/user/user32/misc/imm.c:446) WINNLSEnableIME is UNIMPLEMENTED! fixme:(../dll/win32/iphlpapi/address.c:290) GetAdaptersAddresses - Semi Stub: Family 2, Flags 0x0000002e, Reserved 00000000, pAdapterAddress 00000000, pOutBufLen 0143EBD4. (dll/ntdll/ldr/ldrinit.c:1649) LdrpInitializeProcessCompat: Not applying automatic fix for winver 0xa00 due to policy (win32ss/gdi/gdi32/objects/text.c:543) GdiBCExtTextOut nothing when browsing the startmenu: fixme:(dll/win32/comctl32/toolbar.c:394) [00080086] TBSTYLE_REGISTERDROP not implemented fixme:(dll/win32/comctl32/toolbar.c:5636) [00080086] response 2045774661 not handled to NM_CUSTOMDRAW (CDDS_PREERASE) fixme:(dll/win32/comctl32/toolbar.c:5673) [00080086] response 3225142 not handled to NM_CUSTOMDRAW (CDDS_POSTERASE) fixme:(dll/win32/comctl32/toolbar.c:5636) [000200BA] response 9 not handled to NM_CUSTOMDRAW (CDDS_PREERASE) fixme:(dll/win32/comctl32/toolbar.c:5636) [00080086] response 2288892 not handled to NM_CUSTOMDRAW (CDDS_PREERASE) fixme:(dll/win32/comctl32/toolbar.c:5673) [00080086] response 3291448 not handled to NM_CUSTOMDRAW (CDDS_POSTERASE) and a bigger block regarding the parallel port during booting: (drivers/parallel/parport/parport.c:127) Parport DriverEntry (drivers/parallel/parport/fdo.c:391) AddDevice(B0B50548 B0FED980) (drivers/parallel/parport/fdo.c:25) AddDeviceInternal() (drivers/parallel/parport/fdo.c:513) FdoPnp() (drivers/parallel/parport/fdo.c:582) IRP_MJ_PNP / IRP_MN_FILTER_RESOURCE_REQUIREMENTS (drivers/parallel/parport/fdo.c:513) FdoPnp() (drivers/parallel/parport/fdo.c:546) IRP_MJ_PNP / IRP_MN_START_DEVICE (drivers/parallel/parport/misc.c:42) Calling lower device B0FED980 (drivers/parallel/parport/fdo.c:116) FdoStartDevice () (drivers/parallel/parport/fdo.c:160) Port: BaseAddress 0x378 Length 8 (drivers/parallel/parport/fdo.c:160) Port: BaseAddress 0x778 Length 8 (drivers/parallel/parport/fdo.c:174) Interrupt: Level 20 Vector 55 (drivers/parallel/parport/fdo.c:195) New LPT port: Base 0x378 (drivers/parallel/parport/fdo.c:513) FdoPnp() (drivers/parallel/parport/fdo.c:586) Unknown minor function 0x9 (drivers/parallel/parport/fdo.c:513) FdoPnp() (drivers/parallel/parport/fdo.c:586) Unknown minor function 0x14 (drivers/parallel/parport/fdo.c:513) FdoPnp() (drivers/parallel/parport/fdo.c:564) IRP_MJ_PNP / IRP_MN_QUERY_DEVICE_RELATIONS / BusRelations (drivers/parallel/parport/fdo.c:351) FdoQueryBusRelations() (drivers/parallel/parport/fdo.c:233) FdoCreateRawParallelPdo() (drivers/parallel/parport/fdo.c:378) Done (drivers/parallel/parport/pdo.c:165) PdoPnp()
This commit is contained in:
parent
92487c8097
commit
ea05d36496
|
@ -1646,7 +1646,7 @@ LdrpInitializeProcessCompat(PVOID pProcessActctx, PVOID* pOldShimData)
|
||||||
{
|
{
|
||||||
if (LdrpDisableProcessCompatGuidDetection())
|
if (LdrpDisableProcessCompatGuidDetection())
|
||||||
{
|
{
|
||||||
DPRINT1("LdrpInitializeProcessCompat: Not applying automatic fix for winver 0x%x due to policy\n", KnownCompatGuids[cur].Version);
|
DPRINT("LdrpInitializeProcessCompat: Not applying automatic fix for winver 0x%x due to policy\n", KnownCompatGuids[cur].Version);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1899,12 +1899,9 @@ LdrpInitializeProcess(IN PCONTEXT Context,
|
||||||
&CommandLine);
|
&CommandLine);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* If the timeout is too long */
|
/* If the CS timeout is longer than 1 hour, disable it */
|
||||||
if (RtlpTimeout.QuadPart < Int32x32To64(3600, -10000000))
|
if (RtlpTimeout.QuadPart < Int32x32To64(3600, -10000000))
|
||||||
{
|
|
||||||
/* Then disable CS Timeout */
|
|
||||||
RtlpTimeoutDisable = TRUE;
|
RtlpTimeoutDisable = TRUE;
|
||||||
}
|
|
||||||
|
|
||||||
/* Initialize Critical Section Data */
|
/* Initialize Critical Section Data */
|
||||||
RtlpInitDeferedCriticalSection();
|
RtlpInitDeferedCriticalSection();
|
||||||
|
|
|
@ -300,14 +300,6 @@ TOOLBAR_GetText(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *btnPtr)
|
||||||
return lpText;
|
return lpText;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
TOOLBAR_DumpTBButton(const TBBUTTON *tbb, BOOL fUnicode)
|
|
||||||
{
|
|
||||||
TRACE("TBBUTTON: id %d, bitmap=%d, state=%02x, style=%02x, data=%p, stringid=%p (%s)\n", tbb->idCommand,
|
|
||||||
tbb->iBitmap, tbb->fsState, tbb->fsStyle, (void *)tbb->dwData, (void *)tbb->iString,
|
|
||||||
tbb->iString != -1 ? (fUnicode ? debugstr_w((LPWSTR)tbb->iString) : debugstr_a((LPSTR)tbb->iString)) : "");
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
TOOLBAR_DumpButton(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *bP, INT btn_num)
|
TOOLBAR_DumpButton(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *bP, INT btn_num)
|
||||||
{
|
{
|
||||||
|
@ -377,24 +369,8 @@ static void set_stringT( TBUTTON_INFO *btn, const WCHAR *str, BOOL unicode )
|
||||||
static void free_string( TBUTTON_INFO *btn )
|
static void free_string( TBUTTON_INFO *btn )
|
||||||
{
|
{
|
||||||
set_string_index( btn, 0, TRUE );
|
set_string_index( btn, 0, TRUE );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* TOOLBAR_CheckStyle
|
|
||||||
*
|
|
||||||
* This function validates that the styles set are implemented and
|
|
||||||
* issues FIXMEs warning of possible problems. In a perfect world this
|
|
||||||
* function should be null.
|
|
||||||
*/
|
|
||||||
static void
|
|
||||||
TOOLBAR_CheckStyle (const TOOLBAR_INFO *infoPtr)
|
|
||||||
{
|
|
||||||
if (infoPtr->dwStyle & TBSTYLE_REGISTERDROP)
|
|
||||||
FIXME("[%p] TBSTYLE_REGISTERDROP not implemented\n", infoPtr->hwndSelf);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
static INT
|
static INT
|
||||||
TOOLBAR_SendNotify (NMHDR *nmhdr, const TOOLBAR_INFO *infoPtr, UINT code)
|
TOOLBAR_SendNotify (NMHDR *nmhdr, const TOOLBAR_INFO *infoPtr, UINT code)
|
||||||
{
|
{
|
||||||
|
@ -2018,8 +1994,6 @@ TOOLBAR_InternalInsertButtonsT(TOOLBAR_INFO *infoPtr, INT iIndex, UINT nAddButto
|
||||||
TBUTTON_INFO *btnPtr = &infoPtr->buttons[iIndex + iButton];
|
TBUTTON_INFO *btnPtr = &infoPtr->buttons[iIndex + iButton];
|
||||||
INT_PTR str;
|
INT_PTR str;
|
||||||
|
|
||||||
TOOLBAR_DumpTBButton(lpTbb + iButton, fUnicode);
|
|
||||||
|
|
||||||
ZeroMemory(btnPtr, sizeof(*btnPtr));
|
ZeroMemory(btnPtr, sizeof(*btnPtr));
|
||||||
|
|
||||||
btnPtr->iBitmap = lpTbb[iButton].iBitmap;
|
btnPtr->iBitmap = lpTbb[iButton].iBitmap;
|
||||||
|
@ -5267,7 +5241,6 @@ TOOLBAR_SetStyle (TOOLBAR_INFO *infoPtr, DWORD style)
|
||||||
infoPtr->dwDTFlags = DT_CENTER | DT_END_ELLIPSIS;
|
infoPtr->dwDTFlags = DT_CENTER | DT_END_ELLIPSIS;
|
||||||
|
|
||||||
infoPtr->dwStyle = style;
|
infoPtr->dwStyle = style;
|
||||||
TOOLBAR_CheckStyle(infoPtr);
|
|
||||||
|
|
||||||
if ((dwOldStyle ^ style) & TBSTYLE_WRAPABLE)
|
if ((dwOldStyle ^ style) & TBSTYLE_WRAPABLE)
|
||||||
{
|
{
|
||||||
|
@ -5552,8 +5525,6 @@ TOOLBAR_Create (HWND hwnd, const CREATESTRUCTW *lpcs)
|
||||||
OpenThemeData (hwnd, themeClass);
|
OpenThemeData (hwnd, themeClass);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
TOOLBAR_CheckStyle (infoPtr);
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5632,9 +5603,6 @@ TOOLBAR_EraseBackground (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam)
|
||||||
break;
|
break;
|
||||||
case CDRF_SKIPDEFAULT:
|
case CDRF_SKIPDEFAULT:
|
||||||
return TRUE;
|
return TRUE;
|
||||||
default:
|
|
||||||
FIXME("[%p] response %d not handled to NM_CUSTOMDRAW (CDDS_PREERASE)\n",
|
|
||||||
infoPtr->hwndSelf, ntfret);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5669,9 +5637,6 @@ TOOLBAR_EraseBackground (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam)
|
||||||
break;
|
break;
|
||||||
case CDRF_SKIPDEFAULT:
|
case CDRF_SKIPDEFAULT:
|
||||||
return TRUE;
|
return TRUE;
|
||||||
default:
|
|
||||||
FIXME("[%p] response %d not handled to NM_CUSTOMDRAW (CDDS_POSTERASE)\n",
|
|
||||||
infoPtr->hwndSelf, ntfret);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ret;
|
return ret;
|
||||||
|
|
|
@ -331,7 +331,7 @@ GetAdaptersAddresses(
|
||||||
DWORD MIN_SIZE = 15 * 1024;
|
DWORD MIN_SIZE = 15 * 1024;
|
||||||
PIP_ADAPTER_ADDRESSES PreviousAA = NULL;
|
PIP_ADAPTER_ADDRESSES PreviousAA = NULL;
|
||||||
|
|
||||||
FIXME("GetAdaptersAddresses - Semi Stub: Family %u, Flags 0x%08x, Reserved %p, pAdapterAddress %p, pOutBufLen %p.\n",
|
TRACE("Family %u, Flags 0x%08x, Reserved %p, pAdapterAddress %p, pOutBufLen %p\n",
|
||||||
Family, Flags, Reserved, pAdapterAddresses, pOutBufLen);
|
Family, Flags, Reserved, pAdapterAddresses, pOutBufLen);
|
||||||
|
|
||||||
if (!pOutBufLen)
|
if (!pOutBufLen)
|
||||||
|
|
|
@ -1332,7 +1332,7 @@ MupRerouteOpen(PFILE_OBJECT FileObject,
|
||||||
PWSTR FullPath;
|
PWSTR FullPath;
|
||||||
ULONG TotalLength;
|
ULONG TotalLength;
|
||||||
|
|
||||||
DPRINT1("Rerouting %wZ with %wZ\n", &FileObject->FileName, &UncProvider->DeviceName);
|
DPRINT("Rerouting %wZ with %wZ\n", &FileObject->FileName, &UncProvider->DeviceName);
|
||||||
|
|
||||||
/* Get the full path name (device name first, and requested file name appended) */
|
/* Get the full path name (device name first, and requested file name appended) */
|
||||||
TotalLength = UncProvider->DeviceName.Length + FileObject->FileName.Length;
|
TotalLength = UncProvider->DeviceName.Length + FileObject->FileName.Length;
|
||||||
|
@ -1804,7 +1804,7 @@ QueryPathCompletionRoutine(PDEVICE_OBJECT DeviceObject,
|
||||||
Prefix->ExternalAlloc = TRUE;
|
Prefix->ExternalAlloc = TRUE;
|
||||||
|
|
||||||
/* Insert the accepted prefix in the table of known prefixes */
|
/* Insert the accepted prefix in the table of known prefixes */
|
||||||
DPRINT1("%wZ accepted %wZ\n", &Prefix->UncProvider->DeviceName, &Prefix->AcceptedPrefix);
|
DPRINT("%wZ accepted %wZ\n", &Prefix->UncProvider->DeviceName, &Prefix->AcceptedPrefix);
|
||||||
ExAcquireResourceExclusiveLite(&MupPrefixTableLock, TRUE);
|
ExAcquireResourceExclusiveLite(&MupPrefixTableLock, TRUE);
|
||||||
if (RtlInsertUnicodePrefix(&MupPrefixTable, &Prefix->AcceptedPrefix, &Prefix->PrefixTableEntry))
|
if (RtlInsertUnicodePrefix(&MupPrefixTable, &Prefix->AcceptedPrefix, &Prefix->PrefixTableEntry))
|
||||||
{
|
{
|
||||||
|
@ -1923,7 +1923,7 @@ CreateRedirectedFile(PIRP Irp,
|
||||||
return STATUS_INVALID_DEVICE_REQUEST;
|
return STATUS_INVALID_DEVICE_REQUEST;
|
||||||
}
|
}
|
||||||
|
|
||||||
DPRINT1("Request for opening: %wZ\n", &FileObject->FileName);
|
DPRINT("Request for opening: %wZ\n", &FileObject->FileName);
|
||||||
|
|
||||||
Referenced = FALSE;
|
Referenced = FALSE;
|
||||||
BreakOnFirst = TRUE;
|
BreakOnFirst = TRUE;
|
||||||
|
@ -2130,7 +2130,7 @@ CreateRedirectedFile(PIRP Irp,
|
||||||
ExReleaseResourceLite(&MasterQueryContext->QueryPathListLock);
|
ExReleaseResourceLite(&MasterQueryContext->QueryPathListLock);
|
||||||
|
|
||||||
/* Query the provider !*/
|
/* Query the provider !*/
|
||||||
DPRINT1("Requesting UNC provider: %wZ\n", &UncProvider->DeviceName);
|
DPRINT("Requesting UNC provider: %wZ\n", &UncProvider->DeviceName);
|
||||||
DPRINT("Calling: %wZ\n", &UncProvider->DeviceObject->DriverObject->DriverName);
|
DPRINT("Calling: %wZ\n", &UncProvider->DeviceObject->DriverObject->DriverName);
|
||||||
Status = IoCallDriver(UncProvider->DeviceObject, QueryIrp);
|
Status = IoCallDriver(UncProvider->DeviceObject, QueryIrp);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: Parallel Port Function Driver
|
* PROJECT: Parallel Port Function Driver
|
||||||
* FILE: drivers/parallel/parport/fdo.c
|
|
||||||
* PURPOSE: FDO functions
|
* PURPOSE: FDO functions
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -22,8 +21,6 @@ AddDeviceInternal(IN PDRIVER_OBJECT DriverObject,
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
DPRINT("AddDeviceInternal()\n");
|
|
||||||
|
|
||||||
ASSERT(DriverObject);
|
ASSERT(DriverObject);
|
||||||
ASSERT(Pdo);
|
ASSERT(Pdo);
|
||||||
|
|
||||||
|
@ -107,13 +104,6 @@ FdoStartDevice(IN PDEVICE_OBJECT DeviceObject,
|
||||||
{
|
{
|
||||||
PFDO_DEVICE_EXTENSION DeviceExtension;
|
PFDO_DEVICE_EXTENSION DeviceExtension;
|
||||||
ULONG i;
|
ULONG i;
|
||||||
// ULONG Vector = 0;
|
|
||||||
// KIRQL Dirql = 0;
|
|
||||||
// KAFFINITY Affinity = 0;
|
|
||||||
// KINTERRUPT_MODE InterruptMode = Latched;
|
|
||||||
// BOOLEAN ShareInterrupt = TRUE;
|
|
||||||
|
|
||||||
DPRINT("FdoStartDevice ()\n");
|
|
||||||
|
|
||||||
DeviceExtension = (PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
DeviceExtension = (PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
||||||
|
|
||||||
|
@ -150,18 +140,13 @@ FdoStartDevice(IN PDEVICE_OBJECT DeviceObject,
|
||||||
for (i = 0; i < ResourceList->List[0].PartialResourceList.Count; i++)
|
for (i = 0; i < ResourceList->List[0].PartialResourceList.Count; i++)
|
||||||
{
|
{
|
||||||
PCM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptor = &ResourceList->List[0].PartialResourceList.PartialDescriptors[i];
|
PCM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptor = &ResourceList->List[0].PartialResourceList.PartialDescriptors[i];
|
||||||
PCM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptorTranslated = &ResourceListTranslated->List[0].PartialResourceList.PartialDescriptors[i];
|
|
||||||
|
|
||||||
switch (PartialDescriptor->Type)
|
switch (PartialDescriptor->Type)
|
||||||
{
|
{
|
||||||
case CmResourceTypePort:
|
case CmResourceTypePort:
|
||||||
DPRINT("Port: BaseAddress 0x%lx Length %lu\n",
|
|
||||||
PartialDescriptor->u.Port.Start.u.LowPart,
|
|
||||||
PartialDescriptor->u.Port.Length);
|
|
||||||
|
|
||||||
if (DeviceExtension->BaseAddress == 0)
|
if (DeviceExtension->BaseAddress == 0)
|
||||||
{
|
{
|
||||||
if (PartialDescriptor->u.Port.Length < 4)
|
if (PartialDescriptor->u.Port.Length < 3)
|
||||||
return STATUS_INSUFFICIENT_RESOURCES;
|
return STATUS_INSUFFICIENT_RESOURCES;
|
||||||
|
|
||||||
DeviceExtension->BaseAddress = PartialDescriptor->u.Port.Start.u.LowPart;
|
DeviceExtension->BaseAddress = PartialDescriptor->u.Port.Start.u.LowPart;
|
||||||
|
@ -169,31 +154,13 @@ FdoStartDevice(IN PDEVICE_OBJECT DeviceObject,
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CmResourceTypeInterrupt:
|
case CmResourceTypeInterrupt:
|
||||||
DPRINT("Interrupt: Level %lu Vector %lu\n",
|
|
||||||
PartialDescriptorTranslated->u.Interrupt.Level,
|
|
||||||
PartialDescriptorTranslated->u.Interrupt.Vector);
|
|
||||||
|
|
||||||
// Dirql = (KIRQL)PartialDescriptorTranslated->u.Interrupt.Level;
|
|
||||||
// Vector = PartialDescriptorTranslated->u.Interrupt.Vector;
|
|
||||||
// Affinity = PartialDescriptorTranslated->u.Interrupt.Affinity;
|
|
||||||
|
|
||||||
// if (PartialDescriptorTranslated->Flags & CM_RESOURCE_INTERRUPT_LATCHED)
|
|
||||||
// InterruptMode = Latched;
|
|
||||||
// else
|
|
||||||
// InterruptMode = LevelSensitive;
|
|
||||||
|
|
||||||
// ShareInterrupt = (PartialDescriptorTranslated->ShareDisposition == CmResourceShareShared);
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
DPRINT1("Other resource: \n");
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
DPRINT("New LPT port: Base 0x%lx\n",
|
|
||||||
DeviceExtension->BaseAddress);
|
|
||||||
|
|
||||||
if (!DeviceExtension->BaseAddress)
|
if (!DeviceExtension->BaseAddress)
|
||||||
return STATUS_INSUFFICIENT_RESOURCES;
|
return STATUS_INSUFFICIENT_RESOURCES;
|
||||||
|
|
||||||
|
@ -230,8 +197,6 @@ FdoCreateRawParallelPdo(
|
||||||
HANDLE KeyHandle;
|
HANDLE KeyHandle;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
DPRINT("FdoCreateRawParallelPdo()\n");
|
|
||||||
|
|
||||||
FdoDeviceExtension = (PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
FdoDeviceExtension = (PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
||||||
|
|
||||||
/* Create new device object */
|
/* Create new device object */
|
||||||
|
@ -348,8 +313,6 @@ FdoQueryBusRelations(
|
||||||
|
|
||||||
UNREFERENCED_PARAMETER(IrpSp);
|
UNREFERENCED_PARAMETER(IrpSp);
|
||||||
|
|
||||||
DPRINT("FdoQueryBusRelations()\n");
|
|
||||||
|
|
||||||
DeviceExtension = (PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
DeviceExtension = (PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
||||||
ASSERT(DeviceExtension->Common.IsFDO);
|
ASSERT(DeviceExtension->Common.IsFDO);
|
||||||
|
|
||||||
|
@ -375,8 +338,6 @@ FdoQueryBusRelations(
|
||||||
|
|
||||||
Irp->IoStatus.Information = (ULONG_PTR)DeviceRelations;
|
Irp->IoStatus.Information = (ULONG_PTR)DeviceRelations;
|
||||||
|
|
||||||
DPRINT("Done\n");
|
|
||||||
|
|
||||||
return STATUS_SUCCESS;
|
return STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -388,8 +349,6 @@ NTAPI
|
||||||
AddDevice(IN PDRIVER_OBJECT DriverObject,
|
AddDevice(IN PDRIVER_OBJECT DriverObject,
|
||||||
IN PDEVICE_OBJECT Pdo)
|
IN PDEVICE_OBJECT Pdo)
|
||||||
{
|
{
|
||||||
DPRINT("AddDevice(%p %p)\n", DriverObject, Pdo);
|
|
||||||
|
|
||||||
/* Serial.sys is a legacy driver. AddDevice is called once
|
/* Serial.sys is a legacy driver. AddDevice is called once
|
||||||
* with a NULL Pdo just after the driver initialization.
|
* with a NULL Pdo just after the driver initialization.
|
||||||
* Detect this case and return success.
|
* Detect this case and return success.
|
||||||
|
@ -510,8 +469,6 @@ FdoPnp(IN PDEVICE_OBJECT DeviceObject,
|
||||||
ULONG_PTR Information = 0;
|
ULONG_PTR Information = 0;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
DPRINT("FdoPnp()\n");
|
|
||||||
|
|
||||||
Stack = IoGetCurrentIrpStackLocation(Irp);
|
Stack = IoGetCurrentIrpStackLocation(Irp);
|
||||||
MinorFunction = Stack->MinorFunction;
|
MinorFunction = Stack->MinorFunction;
|
||||||
|
|
||||||
|
@ -543,8 +500,6 @@ FdoPnp(IN PDEVICE_OBJECT DeviceObject,
|
||||||
IRP_MN_SURPRISE_REMOVAL 0x17
|
IRP_MN_SURPRISE_REMOVAL 0x17
|
||||||
*/
|
*/
|
||||||
case IRP_MN_START_DEVICE: /* 0x0 */
|
case IRP_MN_START_DEVICE: /* 0x0 */
|
||||||
DPRINT("IRP_MJ_PNP / IRP_MN_START_DEVICE\n");
|
|
||||||
|
|
||||||
ASSERT(((PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->Common.PnpState == dsStopped);
|
ASSERT(((PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->Common.PnpState == dsStopped);
|
||||||
|
|
||||||
/* Call lower driver */
|
/* Call lower driver */
|
||||||
|
@ -561,7 +516,6 @@ FdoPnp(IN PDEVICE_OBJECT DeviceObject,
|
||||||
switch (Stack->Parameters.QueryDeviceRelations.Type)
|
switch (Stack->Parameters.QueryDeviceRelations.Type)
|
||||||
{
|
{
|
||||||
case BusRelations:
|
case BusRelations:
|
||||||
DPRINT("IRP_MJ_PNP / IRP_MN_QUERY_DEVICE_RELATIONS / BusRelations\n");
|
|
||||||
Status = FdoQueryBusRelations(DeviceObject, Irp, Stack);
|
Status = FdoQueryBusRelations(DeviceObject, Irp, Stack);
|
||||||
Irp->IoStatus.Status = Status;
|
Irp->IoStatus.Status = Status;
|
||||||
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
||||||
|
@ -579,11 +533,9 @@ FdoPnp(IN PDEVICE_OBJECT DeviceObject,
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case IRP_MN_FILTER_RESOURCE_REQUIREMENTS: /* (optional) 0xd */
|
case IRP_MN_FILTER_RESOURCE_REQUIREMENTS: /* (optional) 0xd */
|
||||||
DPRINT("IRP_MJ_PNP / IRP_MN_FILTER_RESOURCE_REQUIREMENTS\n");
|
|
||||||
return ForwardIrpAndForget(DeviceObject, Irp);
|
return ForwardIrpAndForget(DeviceObject, Irp);
|
||||||
|
|
||||||
default:
|
default:
|
||||||
DPRINT("Unknown minor function 0x%x\n", MinorFunction);
|
|
||||||
return ForwardIrpAndForget(DeviceObject, Irp);
|
return ForwardIrpAndForget(DeviceObject, Irp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -602,8 +554,6 @@ FdoPower(IN PDEVICE_OBJECT DeviceObject,
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT LowerDevice;
|
PDEVICE_OBJECT LowerDevice;
|
||||||
|
|
||||||
DPRINT("FdoPower()\n");
|
|
||||||
|
|
||||||
LowerDevice = ((PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->LowerDevice;
|
LowerDevice = ((PFDO_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->LowerDevice;
|
||||||
PoStartNextPowerIrp(Irp);
|
PoStartNextPowerIrp(Irp);
|
||||||
IoSkipCurrentIrpStackLocation(Irp);
|
IoSkipCurrentIrpStackLocation(Irp);
|
||||||
|
|
|
@ -39,7 +39,6 @@ ForwardIrpAndWait(IN PDEVICE_OBJECT DeviceObject,
|
||||||
KeInitializeEvent(&Event, NotificationEvent, FALSE);
|
KeInitializeEvent(&Event, NotificationEvent, FALSE);
|
||||||
IoCopyCurrentIrpStackLocationToNext(Irp);
|
IoCopyCurrentIrpStackLocationToNext(Irp);
|
||||||
|
|
||||||
DPRINT("Calling lower device %p\n", LowerDevice);
|
|
||||||
IoSetCompletionRoutine(Irp, ForwardIrpAndWaitCompletion, &Event, TRUE, TRUE, TRUE);
|
IoSetCompletionRoutine(Irp, ForwardIrpAndWaitCompletion, &Event, TRUE, TRUE, TRUE);
|
||||||
|
|
||||||
Status = IoCallDriver(LowerDevice, Irp);
|
Status = IoCallDriver(LowerDevice, Irp);
|
||||||
|
|
|
@ -124,8 +124,6 @@ DriverEntry(IN PDRIVER_OBJECT DriverObject,
|
||||||
{
|
{
|
||||||
ULONG i;
|
ULONG i;
|
||||||
|
|
||||||
DPRINT("Parport DriverEntry\n");
|
|
||||||
|
|
||||||
DriverObject->DriverUnload = DriverUnload;
|
DriverObject->DriverUnload = DriverUnload;
|
||||||
DriverObject->DriverExtension->AddDevice = AddDevice;
|
DriverObject->DriverExtension->AddDevice = AddDevice;
|
||||||
|
|
||||||
|
|
|
@ -162,7 +162,6 @@ PdoPnp(IN PDEVICE_OBJECT DeviceObject,
|
||||||
IN PIRP Irp)
|
IN PIRP Irp)
|
||||||
{
|
{
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
DPRINT("PdoPnp()\n");
|
|
||||||
|
|
||||||
Status = Irp->IoStatus.Status;
|
Status = Irp->IoStatus.Status;
|
||||||
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
||||||
|
@ -178,8 +177,6 @@ PdoPower(IN PDEVICE_OBJECT DeviceObject,
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
PIO_STACK_LOCATION IoStack;
|
PIO_STACK_LOCATION IoStack;
|
||||||
|
|
||||||
DPRINT("PdoPower()\n");
|
|
||||||
|
|
||||||
IoStack = IoGetCurrentIrpStackLocation(Irp);
|
IoStack = IoGetCurrentIrpStackLocation(Irp);
|
||||||
|
|
||||||
switch (IoStack->MinorFunction)
|
switch (IoStack->MinorFunction)
|
||||||
|
|
|
@ -33,7 +33,8 @@ SYSTEM_POWER_CAPABILITIES PopCapabilities;
|
||||||
static
|
static
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
NTAPI
|
NTAPI
|
||||||
PopRequestPowerIrpCompletion(IN PDEVICE_OBJECT DeviceObject,
|
PopRequestPowerIrpCompletion(
|
||||||
|
IN PDEVICE_OBJECT DeviceObject,
|
||||||
IN PIRP Irp,
|
IN PIRP Irp,
|
||||||
IN PVOID Context)
|
IN PVOID Context)
|
||||||
{
|
{
|
||||||
|
@ -306,8 +307,7 @@ PoInitSystem(IN ULONG BootPhase)
|
||||||
IoRegisterPlugPlayNotification(EventCategoryDeviceInterfaceChange,
|
IoRegisterPlugPlayNotification(EventCategoryDeviceInterfaceChange,
|
||||||
PNPNOTIFY_DEVICE_INTERFACE_INCLUDE_EXISTING_INTERFACES,
|
PNPNOTIFY_DEVICE_INTERFACE_INCLUDE_EXISTING_INTERFACES,
|
||||||
(PVOID)&GUID_DEVICE_SYS_BUTTON,
|
(PVOID)&GUID_DEVICE_SYS_BUTTON,
|
||||||
IopRootDeviceNode->
|
IopRootDeviceNode->PhysicalDeviceObject->DriverObject,
|
||||||
PhysicalDeviceObject->DriverObject,
|
|
||||||
PopAddRemoveSysCapsCallback,
|
PopAddRemoveSysCapsCallback,
|
||||||
NULL,
|
NULL,
|
||||||
&NotificationEntry);
|
&NotificationEntry);
|
||||||
|
@ -316,8 +316,7 @@ PoInitSystem(IN ULONG BootPhase)
|
||||||
IoRegisterPlugPlayNotification(EventCategoryDeviceInterfaceChange,
|
IoRegisterPlugPlayNotification(EventCategoryDeviceInterfaceChange,
|
||||||
PNPNOTIFY_DEVICE_INTERFACE_INCLUDE_EXISTING_INTERFACES,
|
PNPNOTIFY_DEVICE_INTERFACE_INCLUDE_EXISTING_INTERFACES,
|
||||||
(PVOID)&GUID_DEVICE_LID,
|
(PVOID)&GUID_DEVICE_LID,
|
||||||
IopRootDeviceNode->
|
IopRootDeviceNode->PhysicalDeviceObject->DriverObject,
|
||||||
PhysicalDeviceObject->DriverObject,
|
|
||||||
PopAddRemoveSysCapsCallback,
|
PopAddRemoveSysCapsCallback,
|
||||||
NULL,
|
NULL,
|
||||||
&NotificationEntry);
|
&NotificationEntry);
|
||||||
|
@ -482,7 +481,8 @@ PoSetHiberRange(IN PVOID HiberContext,
|
||||||
*/
|
*/
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
NTAPI
|
NTAPI
|
||||||
PoCallDriver(IN PDEVICE_OBJECT DeviceObject,
|
PoCallDriver(
|
||||||
|
IN PDEVICE_OBJECT DeviceObject,
|
||||||
IN OUT PIRP Irp)
|
IN OUT PIRP Irp)
|
||||||
{
|
{
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
@ -490,7 +490,6 @@ PoCallDriver(IN PDEVICE_OBJECT DeviceObject,
|
||||||
/* Forward to Io -- FIXME! */
|
/* Forward to Io -- FIXME! */
|
||||||
Status = IoCallDriver(DeviceObject, Irp);
|
Status = IoCallDriver(DeviceObject, Irp);
|
||||||
|
|
||||||
/* Return status */
|
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -525,7 +524,8 @@ PoRegisterSystemState(IN PVOID StateHandle,
|
||||||
*/
|
*/
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
NTAPI
|
NTAPI
|
||||||
PoRequestPowerIrp(IN PDEVICE_OBJECT DeviceObject,
|
PoRequestPowerIrp(
|
||||||
|
IN PDEVICE_OBJECT DeviceObject,
|
||||||
IN UCHAR MinorFunction,
|
IN UCHAR MinorFunction,
|
||||||
IN POWER_STATE PowerState,
|
IN POWER_STATE PowerState,
|
||||||
IN PREQUEST_POWER_COMPLETE CompletionFunction,
|
IN PREQUEST_POWER_COMPLETE CompletionFunction,
|
||||||
|
@ -625,7 +625,6 @@ VOID
|
||||||
NTAPI
|
NTAPI
|
||||||
PoStartNextPowerIrp(IN PIRP Irp)
|
PoStartNextPowerIrp(IN PIRP Irp)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED_ONCE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -999,7 +998,6 @@ NtSetSystemPowerState(IN POWER_ACTION SystemAction,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* You should not have made it this far */
|
/* You should not have made it this far */
|
||||||
// ASSERTMSG("System is still up and running?!\n", FALSE);
|
|
||||||
DPRINT1("System is still up and running, you may not have chosen a yet supported power option: %u\n", PopAction.Action);
|
DPRINT1("System is still up and running, you may not have chosen a yet supported power option: %u\n", PopAction.Action);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,6 +13,7 @@ static BOOLEAN CMAPI
|
||||||
HvpWriteLog(
|
HvpWriteLog(
|
||||||
PHHIVE RegistryHive)
|
PHHIVE RegistryHive)
|
||||||
{
|
{
|
||||||
|
#if 0 // UNIMPLEMENTED
|
||||||
ULONG FileOffset;
|
ULONG FileOffset;
|
||||||
UINT32 BufferSize;
|
UINT32 BufferSize;
|
||||||
UINT32 BitmapSize;
|
UINT32 BitmapSize;
|
||||||
|
@ -22,13 +23,6 @@ HvpWriteLog(
|
||||||
ULONG LastIndex;
|
ULONG LastIndex;
|
||||||
PVOID BlockPtr;
|
PVOID BlockPtr;
|
||||||
BOOLEAN Success;
|
BOOLEAN Success;
|
||||||
static ULONG PrintCount = 0;
|
|
||||||
|
|
||||||
if (PrintCount++ == 0)
|
|
||||||
{
|
|
||||||
UNIMPLEMENTED;
|
|
||||||
}
|
|
||||||
return TRUE;
|
|
||||||
|
|
||||||
ASSERT(RegistryHive->ReadOnly == FALSE);
|
ASSERT(RegistryHive->ReadOnly == FALSE);
|
||||||
ASSERT(RegistryHive->BaseBlock->Length ==
|
ASSERT(RegistryHive->BaseBlock->Length ==
|
||||||
|
@ -139,7 +133,7 @@ HvpWriteLog(
|
||||||
{
|
{
|
||||||
DPRINT("FileFlush failed\n");
|
DPRINT("FileFlush failed\n");
|
||||||
}
|
}
|
||||||
|
#endif // UNIMPLEMENTED
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -277,7 +271,6 @@ CMAPI
|
||||||
HvHiveWillShrink(IN PHHIVE RegistryHive)
|
HvHiveWillShrink(IN PHHIVE RegistryHive)
|
||||||
{
|
{
|
||||||
/* No shrinking yet */
|
/* No shrinking yet */
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -540,7 +540,7 @@ ExtTextOutW(
|
||||||
}
|
}
|
||||||
else // Do nothing, old explorer pops this off.
|
else // Do nothing, old explorer pops this off.
|
||||||
{
|
{
|
||||||
DPRINT1("GdiBCExtTextOut nothing\n");
|
DPRINT("GdiBCExtTextOut nothing\n");
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
} // Max 580 wchars, if offset 0
|
} // Max 580 wchars, if offset 0
|
||||||
|
|
|
@ -1,11 +1,8 @@
|
||||||
/*
|
/*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS user32.dll
|
* PROJECT: ReactOS user32.dll
|
||||||
* FILE: win32ss/user/user32/misc/imm.c
|
|
||||||
* PURPOSE: User32.dll Imm functions
|
* PURPOSE: User32.dll Imm functions
|
||||||
* PROGRAMMER: Dmitry Chapyshev (dmitry@reactos.org)
|
* PROGRAMMER: Dmitry Chapyshev (dmitry@reactos.org)
|
||||||
* UPDATE HISTORY:
|
|
||||||
* 01/27/2009 Created
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <user32.h>
|
#include <user32.h>
|
||||||
|
@ -17,13 +14,11 @@ WINE_DEFAULT_DEBUG_CHANNEL(user32);
|
||||||
|
|
||||||
#define IMM_INIT_MAGIC 0x19650412
|
#define IMM_INIT_MAGIC 0x19650412
|
||||||
|
|
||||||
|
|
||||||
Imm32ApiTable gImmApiEntries = {0};
|
Imm32ApiTable gImmApiEntries = {0};
|
||||||
HINSTANCE ghImm32 = NULL;
|
HINSTANCE ghImm32 = NULL;
|
||||||
BOOL bImmInitializing = FALSE;
|
BOOL bImmInitializing = FALSE;
|
||||||
BOOL ImmApiTableZero = TRUE;
|
BOOL ImmApiTableZero = TRUE;
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This function should not be implemented, it is used,
|
* This function should not be implemented, it is used,
|
||||||
* if you can not load function from imm32.dll
|
* if you can not load function from imm32.dll
|
||||||
|
@ -58,34 +53,26 @@ HRESULT WINAPI GetImmFileName(PWSTR lpBuffer, UINT uSize)
|
||||||
return StringCchCopyW(Safe, uSize, L"imm32.dll");
|
return StringCchCopyW(Safe, uSize, L"imm32.dll");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
// @unimplemented
|
||||||
* @unimplemented
|
|
||||||
*/
|
|
||||||
BOOL WINAPI IntInitializeImmEntryTable(VOID)
|
BOOL WINAPI IntInitializeImmEntryTable(VOID)
|
||||||
{
|
{
|
||||||
WCHAR ImmFile[MAX_PATH];
|
WCHAR ImmFile[MAX_PATH];
|
||||||
HMODULE imm32 = ghImm32;
|
HMODULE imm32 = ghImm32;
|
||||||
|
|
||||||
if (gImmApiEntries.pImmIsIME != 0)
|
if (gImmApiEntries.pImmIsIME != 0)
|
||||||
{
|
|
||||||
ERR("Imm Api Table Init 1\n");
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
|
||||||
|
|
||||||
GetImmFileName(ImmFile, sizeof(ImmFile));
|
GetImmFileName(ImmFile, sizeof(ImmFile));
|
||||||
TRACE("File %ws\n",ImmFile);
|
|
||||||
|
|
||||||
if (imm32 == NULL)
|
if (imm32 == NULL)
|
||||||
{
|
|
||||||
imm32 = GetModuleHandleW(ImmFile);
|
imm32 = GetModuleHandleW(ImmFile);
|
||||||
}
|
|
||||||
|
|
||||||
if (imm32 == NULL)
|
if (imm32 == NULL)
|
||||||
{
|
{
|
||||||
imm32 = ghImm32 = LoadLibraryW(ImmFile);
|
imm32 = ghImm32 = LoadLibraryW(ImmFile);
|
||||||
if (imm32 == NULL)
|
if (imm32 == NULL)
|
||||||
{
|
{
|
||||||
ERR("Did not load!\n");
|
ERR("Did not load\n");
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
@ -161,13 +148,11 @@ BOOL WINAPI IntInitializeImmEntryTable(VOID)
|
||||||
if (!gImmApiEntries.pImmNotifyIME)
|
if (!gImmApiEntries.pImmNotifyIME)
|
||||||
gImmApiEntries.pImmNotifyIME = IMM_ImmNotifyIME;
|
gImmApiEntries.pImmNotifyIME = IMM_ImmNotifyIME;
|
||||||
|
|
||||||
/*
|
// TODO: Load more functions from imm32.dll
|
||||||
* TODO: Load more functions from imm32.dll
|
// Function like IMPSetIMEW, IMPQueryIMEW etc. call functions
|
||||||
* Function like IMPSetIMEW, IMPQueryIMEW etc. call functions
|
// from imm32.dll through pointers in the structure gImmApiEntries.
|
||||||
* from imm32.dll through pointers in the structure gImmApiEntries.
|
// I do not know whether it is necessary to initialize a table
|
||||||
* I do not know whether it is necessary to initialize a table
|
// of functions to load user32 (DLL_PROCESS_ATTACH)
|
||||||
* of functions to load user32 (DLL_PROCESS_ATTACH)
|
|
||||||
*/
|
|
||||||
|
|
||||||
gImmApiEntries.pImmRegisterClient = (BOOL (WINAPI*)(PVOID, HINSTANCE)) GetProcAddress(imm32, "ImmRegisterClient");
|
gImmApiEntries.pImmRegisterClient = (BOOL (WINAPI*)(PVOID, HINSTANCE)) GetProcAddress(imm32, "ImmRegisterClient");
|
||||||
if (!gImmApiEntries.pImmRegisterClient)
|
if (!gImmApiEntries.pImmRegisterClient)
|
||||||
|
@ -188,16 +173,11 @@ BOOL WINAPI InitializeImmEntryTable(VOID)
|
||||||
|
|
||||||
BOOL WINAPI User32InitializeImmEntryTable(DWORD magic)
|
BOOL WINAPI User32InitializeImmEntryTable(DWORD magic)
|
||||||
{
|
{
|
||||||
TRACE("Imm (%x)\n", magic);
|
|
||||||
|
|
||||||
if (magic != IMM_INIT_MAGIC)
|
if (magic != IMM_INIT_MAGIC)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
if (gImmApiEntries.pImmIsIME != 0)
|
if (gImmApiEntries.pImmIsIME != 0)
|
||||||
{
|
|
||||||
ERR("Imm Api Table Init 2\n");
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
|
||||||
|
|
||||||
IntInitializeImmEntryTable();
|
IntInitializeImmEntryTable();
|
||||||
|
|
||||||
|
@ -208,15 +188,13 @@ BOOL WINAPI User32InitializeImmEntryTable(DWORD magic)
|
||||||
ghImm32 = LoadLibraryW(ImmFile);
|
ghImm32 = LoadLibraryW(ImmFile);
|
||||||
if (ghImm32 == NULL)
|
if (ghImm32 == NULL)
|
||||||
{
|
{
|
||||||
ERR("Did not load! 2\n");
|
ERR("Did not load\n");
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#if 0 // For real Imm32.dll testing!!!!
|
#if 0 // For real Imm32.dll testing
|
||||||
if (ghImm32 && !gImmApiEntries.pImmRegisterClient(&gSharedInfo, ghImm32))
|
if (ghImm32 && !gImmApiEntries.pImmRegisterClient(&gSharedInfo, ghImm32))
|
||||||
{
|
ERR("Wine is stubed\n");
|
||||||
ERR("Wine is stubed!\n");
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
@ -245,13 +223,13 @@ LRESULT WINAPI ImeWndProc_common( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPa
|
||||||
{
|
{
|
||||||
if (pWnd->fnid != FNID_IME)
|
if (pWnd->fnid != FNID_IME)
|
||||||
{
|
{
|
||||||
ERR("Wrong window class for Ime! fnId 0x%x\n",pWnd->fnid);
|
ERR("Wrong window class for Ime\n");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
pimeui = ((PIMEWND)pWnd)->pimeui;
|
pimeui = ((PIMEWND)pWnd)->pimeui;
|
||||||
if (pimeui == NULL)
|
if (pimeui == NULL)
|
||||||
{
|
{
|
||||||
ERR("Window is not set to IME!\n");
|
ERR("Window is not set to IME\n");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -282,9 +260,7 @@ LRESULT WINAPI ImeWndProcW( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam )
|
||||||
return ImeWndProc_common(hwnd, msg, wParam, lParam, TRUE);
|
return ImeWndProc_common(hwnd, msg, wParam, lParam, TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOL
|
BOOL WINAPI UpdatePerUserImmEnabling(VOID)
|
||||||
WINAPI
|
|
||||||
UpdatePerUserImmEnabling(VOID)
|
|
||||||
{
|
{
|
||||||
BOOL Ret = NtUserCallNoParam(NOPARAM_ROUTINE_UPDATEPERUSERIMMENABLING);
|
BOOL Ret = NtUserCallNoParam(NOPARAM_ROUTINE_UPDATEPERUSERIMMENABLING);
|
||||||
if (Ret)
|
if (Ret)
|
||||||
|
@ -297,7 +273,7 @@ UpdatePerUserImmEnabling(VOID)
|
||||||
imm32 = LoadLibraryW(L"imm32.dll");
|
imm32 = LoadLibraryW(L"imm32.dll");
|
||||||
if (!imm32)
|
if (!imm32)
|
||||||
{
|
{
|
||||||
ERR("UPUIE: Imm32 not installed!\n");
|
ERR("Imm32 not installed\n");
|
||||||
Ret = FALSE;
|
Ret = FALSE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -306,8 +282,6 @@ UpdatePerUserImmEnabling(VOID)
|
||||||
return Ret;
|
return Ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static const WCHAR imeW[] = {'I','M','E',0};
|
|
||||||
|
|
||||||
BOOL
|
BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
RegisterIMEClass(VOID)
|
RegisterIMEClass(VOID)
|
||||||
|
@ -318,24 +292,19 @@ RegisterIMEClass(VOID)
|
||||||
ZeroMemory(&WndClass, sizeof(WndClass));
|
ZeroMemory(&WndClass, sizeof(WndClass));
|
||||||
|
|
||||||
WndClass.cbSize = sizeof(WndClass);
|
WndClass.cbSize = sizeof(WndClass);
|
||||||
WndClass.lpszClassName = imeW;
|
WndClass.lpszClassName = L"IME";
|
||||||
WndClass.style = CS_GLOBALCLASS;
|
WndClass.style = CS_GLOBALCLASS;
|
||||||
WndClass.lpfnWndProc = ImeWndProcW;
|
WndClass.lpfnWndProc = ImeWndProcW;
|
||||||
WndClass.cbWndExtra = sizeof(LONG_PTR);
|
WndClass.cbWndExtra = sizeof(LONG_PTR);
|
||||||
WndClass.hCursor = LoadCursorW(NULL, IDC_ARROW);
|
WndClass.hCursor = LoadCursorW(NULL, IDC_ARROW);
|
||||||
|
|
||||||
atom = RegisterClassExWOWW( &WndClass,
|
atom = RegisterClassExWOWW(&WndClass, 0, FNID_IME, 0, FALSE);
|
||||||
0,
|
|
||||||
FNID_IME,
|
|
||||||
0,
|
|
||||||
FALSE);
|
|
||||||
if (atom)
|
if (atom)
|
||||||
{
|
{
|
||||||
RegisterDefaultClasses |= ICLASS_TO_MASK(ICLS_IME);
|
RegisterDefaultClasses |= ICLASS_TO_MASK(ICLS_IME);
|
||||||
TRACE("Register IME Class!\n");
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
ERR("Failed to register IME Class!\n");
|
ERR("Failed to register IME Class\n");
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -344,7 +313,6 @@ RegisterIMEClass(VOID)
|
||||||
*/
|
*/
|
||||||
BOOL WINAPI CliImmSetHotKey(DWORD dwID, UINT uModifiers, UINT uVirtualKey, HKL hKl)
|
BOOL WINAPI CliImmSetHotKey(DWORD dwID, UINT uModifiers, UINT uVirtualKey, HKL hKl)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -355,7 +323,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
IMPSetIMEW(HWND hwnd, LPIMEPROW ime)
|
IMPSetIMEW(HWND hwnd, LPIMEPROW ime)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -366,7 +333,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
IMPQueryIMEW(LPIMEPROW ime)
|
IMPQueryIMEW(LPIMEPROW ime)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -377,7 +343,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
IMPGetIMEW(HWND hwnd, LPIMEPROW ime)
|
IMPGetIMEW(HWND hwnd, LPIMEPROW ime)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -388,7 +353,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
IMPSetIMEA(HWND hwnd, LPIMEPROA ime)
|
IMPSetIMEA(HWND hwnd, LPIMEPROA ime)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -399,7 +363,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
IMPQueryIMEA(LPIMEPROA ime)
|
IMPQueryIMEA(LPIMEPROA ime)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -410,7 +373,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
IMPGetIMEA(HWND hwnd, LPIMEPROA ime)
|
IMPGetIMEA(HWND hwnd, LPIMEPROA ime)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -421,7 +383,6 @@ LRESULT
|
||||||
WINAPI
|
WINAPI
|
||||||
SendIMEMessageExW(HWND hwnd, LPARAM lparam)
|
SendIMEMessageExW(HWND hwnd, LPARAM lparam)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -432,7 +393,6 @@ LRESULT
|
||||||
WINAPI
|
WINAPI
|
||||||
SendIMEMessageExA(HWND hwnd, LPARAM lparam)
|
SendIMEMessageExA(HWND hwnd, LPARAM lparam)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -443,7 +403,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
WINNLSEnableIME(HWND hwnd, BOOL enable)
|
WINNLSEnableIME(HWND hwnd, BOOL enable)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -454,7 +413,6 @@ BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
WINNLSGetEnableStatus(HWND hwnd)
|
WINNLSGetEnableStatus(HWND hwnd)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue