mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
[VIDEOPRT] Implement VideoPortCreateSecondaryDisplay
This commit is contained in:
parent
545352c655
commit
e9b5b22a8c
1 changed files with 38 additions and 2 deletions
|
@ -1350,8 +1350,44 @@ VideoPortCreateSecondaryDisplay(
|
|||
IN OUT PVOID *SecondaryDeviceExtension,
|
||||
IN ULONG Flag)
|
||||
{
|
||||
UNIMPLEMENTED;
|
||||
return ERROR_DEV_NOT_EXIST;
|
||||
PDEVICE_OBJECT DeviceObject;
|
||||
PVIDEO_PORT_DEVICE_EXTENSION FirstDeviceExtension, DeviceExtension;
|
||||
NTSTATUS Status;
|
||||
|
||||
ASSERT(SecondaryDeviceExtension);
|
||||
|
||||
if (Flag != 0)
|
||||
{
|
||||
UNIMPLEMENTED;
|
||||
}
|
||||
|
||||
FirstDeviceExtension = VIDEO_PORT_GET_DEVICE_EXTENSION(HwDeviceExtension);
|
||||
|
||||
if (FirstDeviceExtension->DisplayNumber != 0)
|
||||
{
|
||||
DPRINT1("Calling VideoPortCreateSecondaryDisplay for InstanceId %lu\n",
|
||||
FirstDeviceExtension->DisplayNumber);
|
||||
}
|
||||
|
||||
Status = IntVideoPortCreateAdapterDeviceObject(FirstDeviceExtension->DriverObject,
|
||||
FirstDeviceExtension->DriverExtension,
|
||||
FirstDeviceExtension->PhysicalDeviceObject,
|
||||
FirstDeviceExtension->AdapterNumber,
|
||||
FirstDeviceExtension->NumberOfSecondaryDisplays + 1,
|
||||
&DeviceObject);
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("IntVideoPortCreateAdapterDeviceObject() failed with status 0x%08x\n", Status);
|
||||
return ERROR_DEV_NOT_EXIST;
|
||||
}
|
||||
|
||||
DeviceExtension = DeviceObject->DeviceExtension;
|
||||
|
||||
/* Increment secondary display count */
|
||||
FirstDeviceExtension->NumberOfSecondaryDisplays++;
|
||||
|
||||
*SecondaryDeviceExtension = DeviceExtension->MiniPortDeviceExtension;
|
||||
return NO_ERROR;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in a new issue