BControlLook: remove broken intersection check
When using BAffineTransform, the update rect is not in the same coordinate space as the drawing rectangle. Hence, testing them for intersection does not work, and leads to not drawing buttons which are in fact visible. Moreover, the code in BControlLook does not perform only drawing, it is also expected to update the drawing rect, so other functions may reuse it later (for example, drawing a button border also computes the rectangle for the button background). Because of this, it is not possible to skip the drawing completely, or we could break the layout of the client. Fixes #13664
This commit is contained in:
parent
dd582ff9d5
commit
0d1bb791fc
@ -2228,7 +2228,7 @@ BControlLook::_DrawButtonFrame(BView* view, BRect& rect,
|
||||
const rgb_color& background, float contrast, float brightness,
|
||||
uint32 flags, uint32 borders)
|
||||
{
|
||||
if (!rect.IsValid() || !rect.Intersects(updateRect))
|
||||
if (!rect.IsValid())
|
||||
return;
|
||||
|
||||
// save the clipping constraints of the view
|
||||
@ -2510,7 +2510,7 @@ BControlLook::_DrawButtonBackground(BView* view, BRect& rect,
|
||||
float leftBottomRadius, float rightBottomRadius, const rgb_color& base,
|
||||
bool popupIndicator, uint32 flags, uint32 borders, orientation orientation)
|
||||
{
|
||||
if (!rect.IsValid() || !rect.Intersects(updateRect))
|
||||
if (!rect.IsValid())
|
||||
return;
|
||||
|
||||
// save the clipping constraints of the view
|
||||
|
Loading…
x
Reference in New Issue
Block a user