mirror of
https://github.com/acidanthera/OpenCorePkg.git
synced 2025-12-08 19:25:01 +00:00
OpenCanopy: Do not crop draw requests for always-on-screen elements
This commit is contained in:
parent
9733d3ce96
commit
06a0374352
@ -466,7 +466,6 @@ GuiDrawToBuffer (
|
||||
}
|
||||
}
|
||||
|
||||
STATIC
|
||||
VOID
|
||||
GuiRequestDraw (
|
||||
IN UINT32 PosX,
|
||||
@ -604,26 +603,6 @@ GuiRequestDrawCrop (
|
||||
GuiRequestDraw (PosX, PosY, (UINT32) EffWidth, (UINT32) EffHeight);
|
||||
}
|
||||
|
||||
VOID
|
||||
GuiRedrawObject (
|
||||
IN OUT GUI_OBJ *This,
|
||||
IN OUT GUI_DRAWING_CONTEXT *DrawContext,
|
||||
IN INT64 BaseX,
|
||||
IN INT64 BaseY
|
||||
)
|
||||
{
|
||||
ASSERT (This != NULL);
|
||||
ASSERT (DrawContext != NULL);
|
||||
|
||||
GuiRequestDrawCrop (
|
||||
DrawContext,
|
||||
BaseX,
|
||||
BaseY,
|
||||
This->Width,
|
||||
This->Height
|
||||
);
|
||||
}
|
||||
|
||||
VOID
|
||||
GuiOverlayPointer (
|
||||
IN OUT GUI_DRAWING_CONTEXT *DrawContext
|
||||
|
||||
@ -217,6 +217,14 @@ GuiDrawToBufferFill (
|
||||
IN UINT32 Height
|
||||
);
|
||||
|
||||
VOID
|
||||
GuiRequestDraw (
|
||||
IN UINT32 PosX,
|
||||
IN UINT32 PosY,
|
||||
IN UINT32 Width,
|
||||
IN UINT32 Height
|
||||
);
|
||||
|
||||
VOID
|
||||
GuiRequestDrawCrop (
|
||||
IN OUT GUI_DRAWING_CONTEXT *DrawContext,
|
||||
@ -226,14 +234,6 @@ GuiRequestDrawCrop (
|
||||
IN UINT32 Height
|
||||
);
|
||||
|
||||
VOID
|
||||
GuiRedrawObject (
|
||||
IN OUT GUI_OBJ *Obj,
|
||||
IN OUT GUI_DRAWING_CONTEXT *DrawContext,
|
||||
IN INT64 BaseX,
|
||||
IN INT64 BaseY
|
||||
);
|
||||
|
||||
VOID
|
||||
GuiViewInitialize (
|
||||
OUT GUI_DRAWING_CONTEXT *DrawContext,
|
||||
|
||||
@ -344,11 +344,15 @@ InternalBootPickerScroll (
|
||||
ASSERT (ScrollY >= BaseY);
|
||||
ASSERT (ScrollY + mBootPickerRightScroll.Hdr.Obj.Height <= BaseY + This->Hdr.Obj.Height);
|
||||
DEBUG_CODE_END ();
|
||||
//
|
||||
// The container is constructed such that it is always fully visible.
|
||||
//
|
||||
ASSERT (This->Hdr.Obj.Height <= mBootPickerContainer.Obj.Height);
|
||||
ASSERT (BaseY + This->Hdr.Obj.Height <= DrawContext->Screen->Height);
|
||||
|
||||
GuiRequestDrawCrop (
|
||||
DrawContext,
|
||||
GuiRequestDraw (
|
||||
0,
|
||||
BaseY,
|
||||
(UINT32) BaseY,
|
||||
DrawContext->Screen->Width,
|
||||
This->Hdr.Obj.Height
|
||||
);
|
||||
@ -885,7 +889,14 @@ InternalBootPickerSelectorPtrEvent (
|
||||
|
||||
if (Clickable->CurrentImage != ButtonImage) {
|
||||
Clickable->CurrentImage = ButtonImage;
|
||||
GuiRedrawObject (This, DrawContext, BaseX, BaseY);
|
||||
//
|
||||
// The view is constructed such that the selector is always fully visible.
|
||||
//
|
||||
ASSERT (BaseX >= 0);
|
||||
ASSERT (BaseY >= 0);
|
||||
ASSERT (BaseX + This->Width <= DrawContext->Screen->Width);
|
||||
ASSERT (BaseY + This->Height <= DrawContext->Screen->Height);
|
||||
GuiRequestDraw ((UINT32) BaseX, (UINT32) BaseY, This->Width, This->Height);
|
||||
}
|
||||
|
||||
return This;
|
||||
@ -983,7 +994,15 @@ InternalBootPickerLeftScrollPtrEvent (
|
||||
|
||||
if (Clickable->CurrentImage != ButtonImage) {
|
||||
Clickable->CurrentImage = ButtonImage;
|
||||
GuiRedrawObject (This, DrawContext, BaseX, BaseY);
|
||||
//
|
||||
// The view is constructed such that the scroll buttons are always fully
|
||||
// visible.
|
||||
//
|
||||
ASSERT (BaseX >= 0);
|
||||
ASSERT (BaseY >= 0);
|
||||
ASSERT (BaseX + This->Width <= DrawContext->Screen->Width);
|
||||
ASSERT (BaseY + This->Height <= DrawContext->Screen->Height);
|
||||
GuiRequestDraw ((UINT32) BaseX, (UINT32) BaseY, This->Width, This->Height);
|
||||
}
|
||||
|
||||
return This;
|
||||
@ -1079,7 +1098,15 @@ InternalBootPickerRightScrollPtrEvent (
|
||||
|
||||
if (Clickable->CurrentImage != ButtonImage) {
|
||||
Clickable->CurrentImage = ButtonImage;
|
||||
GuiRedrawObject (This, DrawContext, BaseX, BaseY);
|
||||
//
|
||||
// The view is constructed such that the scroll buttons are always fully
|
||||
// visible.
|
||||
//
|
||||
ASSERT (BaseX >= 0);
|
||||
ASSERT (BaseY >= 0);
|
||||
ASSERT (BaseX + This->Width <= DrawContext->Screen->Width);
|
||||
ASSERT (BaseY + This->Height <= DrawContext->Screen->Height);
|
||||
GuiRequestDraw ((UINT32) BaseX, (UINT32) BaseY, This->Width, This->Height);
|
||||
}
|
||||
|
||||
return This;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user