text: Invalidate bitmap cache on scroll

This patch fixes scrolling text fields when filters are applied.
This commit is contained in:
Kamil Jarosz 2024-05-29 19:50:28 +02:00 committed by Nathan Adams
parent 2fd5dfde9c
commit f4a517dbd1
1 changed files with 2 additions and 1 deletions

View File

@ -1310,7 +1310,8 @@ impl<'gc> EditText<'gc> {
scroll as usize
};
let clamped = scroll_lines.clamp(1, self.maxscroll());
self.0.write(context.gc_context).scroll = clamped;
self.0.write(context.gc()).scroll = clamped;
self.invalidate_cached_bitmap(context.gc());
}
pub fn max_chars(self) -> i32 {