Don't trigger full relayout if DateTimeView doesn't change
Right now, when an update is triggered, DateTimeView will trigger a full relayout of its parents because it always calls setText, even if it doesn't change the contents (later down the line, TextView will call requestLayout() for wrap_content, even if size didn't change). Checking if the content actually changed avoids that extra layout pass which avoids needless relayouts in e.g. SystemUI Notifications. Bug:220712538 Test: atest DateTimeView (new test failed before fix / passes after fix) Change-Id: Ib391d6715136b64b98f0bda3b3d4a3f991809c89
Loading
Please register or sign in to comment