reduce the occurance of a ui glitch in the files view

@dinhviethoa, this does not fix https://github.com/dart-lang/chromedeveditor/issues/3084 but does make is occur less often. It seems like I can repro it more frequently by scrolling with a mouse wheel. Happy to not land this if you see a better solution.


`const` maybe?