The layout checks the target view now if the layout invalidation has been disabled in the view.
This commit is contained in:
parent
57a2ea0d54
commit
31f768577e
|
@ -554,6 +554,7 @@ public:
|
||||||
|
|
||||||
void EnableLayoutInvalidation();
|
void EnableLayoutInvalidation();
|
||||||
void DisableLayoutInvalidation();
|
void DisableLayoutInvalidation();
|
||||||
|
bool IsLayoutInvalidationDisabled();
|
||||||
bool IsLayoutValid() const;
|
bool IsLayoutValid() const;
|
||||||
void ResetLayoutInvalidation();
|
void ResetLayoutInvalidation();
|
||||||
|
|
||||||
|
|
|
@ -301,6 +301,8 @@ BLayout::InvalidateLayout(bool children)
|
||||||
// printf("BLayout(%p)::InvalidateLayout(%i) : state %x, disabled %li\n",
|
// printf("BLayout(%p)::InvalidateLayout(%i) : state %x, disabled %li\n",
|
||||||
// this, children, (unsigned int)fState, fInvalidationDisabled);
|
// this, children, (unsigned int)fState, fInvalidationDisabled);
|
||||||
|
|
||||||
|
if (fTarget && fTarget->IsLayoutInvalidationDisabled())
|
||||||
|
return;
|
||||||
if (fInvalidationDisabled > 0
|
if (fInvalidationDisabled > 0
|
||||||
|| (fState & B_LAYOUT_INVALIDATION_ILLEGAL) != 0) {
|
|| (fState & B_LAYOUT_INVALIDATION_ILLEGAL) != 0) {
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -4744,6 +4744,15 @@ BView::DisableLayoutInvalidation()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool
|
||||||
|
BView::IsLayoutInvalidationDisabled()
|
||||||
|
{
|
||||||
|
if (fLayoutData->fLayoutInvalidationDisabled > 0)
|
||||||
|
return true;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
bool
|
bool
|
||||||
BView::IsLayoutValid() const
|
BView::IsLayoutValid() const
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue