mirror of
https://github.com/penpot/penpot.git
synced 2026-08-01 19:06:18 +00:00
🐛 Fix shape fill flickering from color picker (#10273)
This commit is contained in:
parent
0afa108804
commit
80abc3fe3d
@ -2271,7 +2271,11 @@ impl RenderState {
|
|||||||
if sync_render {
|
if sync_render {
|
||||||
frame_type = self.render_shape_tree_sync(base_object, tree, timestamp)?;
|
frame_type = self.render_shape_tree_sync(base_object, tree, timestamp)?;
|
||||||
} else {
|
} else {
|
||||||
frame_type = self.continue_render_loop(base_object, tree, timestamp)?;
|
// Keep progressive yielding, except for a localized shape edit on a
|
||||||
|
// stable viewbox (e.g. recoloring) which renders in one frame.
|
||||||
|
let allow_stop =
|
||||||
|
!preserve_target || self.zoom_changed() || self.options.is_interactive_transform();
|
||||||
|
frame_type = self.continue_render_loop(base_object, tree, timestamp, allow_stop)?;
|
||||||
|
|
||||||
// This is an option to debug frames.
|
// This is an option to debug frames.
|
||||||
if self.options.capture_frames > 0 {
|
if self.options.capture_frames > 0 {
|
||||||
@ -2331,9 +2335,11 @@ impl RenderState {
|
|||||||
base_object: Option<&Uuid>,
|
base_object: Option<&Uuid>,
|
||||||
tree: ShapesPoolRef,
|
tree: ShapesPoolRef,
|
||||||
timestamp: i32,
|
timestamp: i32,
|
||||||
|
allow_stop: bool,
|
||||||
) -> Result<FrameType> {
|
) -> Result<FrameType> {
|
||||||
performance::begin_measure!("continue_render_loop");
|
performance::begin_measure!("continue_render_loop");
|
||||||
let frame_type = self.render_shape_tree_partial(base_object, tree, timestamp, true)?;
|
let frame_type =
|
||||||
|
self.render_shape_tree_partial(base_object, tree, timestamp, allow_stop)?;
|
||||||
|
|
||||||
if !self.options.is_interactive_transform() {
|
if !self.options.is_interactive_transform() {
|
||||||
self.surfaces.draw_tile_atlas_to_backbuffer(
|
self.surfaces.draw_tile_atlas_to_backbuffer(
|
||||||
|
|||||||
@ -115,7 +115,8 @@ impl State {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub fn continue_render_loop(&mut self, timestamp: i32) -> Result<FrameType> {
|
pub fn continue_render_loop(&mut self, timestamp: i32) -> Result<FrameType> {
|
||||||
get_render_state().continue_render_loop(None, &self.shapes, timestamp)
|
let allow_stop = true;
|
||||||
|
get_render_state().continue_render_loop(None, &self.shapes, timestamp, allow_stop)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn clear_focus_mode(&mut self) {
|
pub fn clear_focus_mode(&mut self) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user