Fix window refreshing
This commit is contained in:
parent
0269a8699b
commit
4900e04ff3
2 changed files with 6 additions and 0 deletions
|
@ -1985,6 +1985,9 @@ impl AppContext {
|
||||||
for window_id in window_ids {
|
for window_id in window_ids {
|
||||||
self.update_window(window_id, |cx| {
|
self.update_window(window_id, |cx| {
|
||||||
let mut invalidation = cx.window.invalidation.take().unwrap_or_default();
|
let mut invalidation = cx.window.invalidation.take().unwrap_or_default();
|
||||||
|
invalidation
|
||||||
|
.updated
|
||||||
|
.extend(cx.window.rendered_views.keys().copied());
|
||||||
cx.invalidate(&mut invalidation, cx.window.platform_window.appearance());
|
cx.invalidate(&mut invalidation, cx.window.platform_window.appearance());
|
||||||
cx.refreshing = true;
|
cx.refreshing = true;
|
||||||
let scene = cx.build_scene();
|
let scene = cx.build_scene();
|
||||||
|
|
|
@ -738,6 +738,9 @@ impl<'a: 'b, 'b> WindowContext<'a, 'b> {
|
||||||
RectF::from_points(Vector2F::zero(), window_size),
|
RectF::from_points(Vector2F::zero(), window_size),
|
||||||
self,
|
self,
|
||||||
);
|
);
|
||||||
|
self.window
|
||||||
|
.rendered_views
|
||||||
|
.insert(root_view_id, rendered_root);
|
||||||
|
|
||||||
self.window.text_layout_cache.finish_frame();
|
self.window.text_layout_cache.finish_frame();
|
||||||
let scene = scene_builder.build();
|
let scene = scene_builder.build();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue