diff --git a/src/app/ui/status_bar.cpp b/src/app/ui/status_bar.cpp index 76c09803c..502aca06d 100644 --- a/src/app/ui/status_bar.cpp +++ b/src/app/ui/status_bar.cpp @@ -941,8 +941,12 @@ void StatusBar::onActiveSiteChange(const Site& site) showSnapToGridWarning(docPref.grid.snap()); // Current frame - m_currentFrame->setTextf( - "%d", site.frame()+docPref.timeline.firstFrame()); + { + std::string newText = + fmt::format("{}", site.frame()+docPref.timeline.firstFrame()); + if (m_currentFrame->text() != newText) + m_currentFrame->setText(newText); + } // Zoom level if (current_editor) @@ -952,7 +956,6 @@ void StatusBar::onActiveSiteChange(const Site& site) m_docControls->setVisible(false); showSnapToGridWarning(false); } - layout(); } void StatusBar::onPixelFormatChanged(DocEvent& ev) diff --git a/src/app/ui/zoom_entry.cpp b/src/app/ui/zoom_entry.cpp index e0111e5f9..1552fba83 100644 --- a/src/app/ui/zoom_entry.cpp +++ b/src/app/ui/zoom_entry.cpp @@ -1,4 +1,5 @@ // Aseprite +// Copyright (C) 2021 Igara Studio S.A. // Copyright (C) 2001-2017 David Capello // // This program is distributed under the terms of @@ -47,7 +48,9 @@ void ZoomEntry::setZoom(const render::Zoom& zoom) if (m_locked) return; - setText(onGetTextFromValue(zoom.linearScale())); + std::string newText = onGetTextFromValue(zoom.linearScale()); + if (newText != text()) + setText(newText); } void ZoomEntry::onValueChange()