mirror of
https://git.mirrors.martin98.com/https://github.com/bambulab/BambuStudio.git
synced 2025-08-06 08:36:08 +08:00
FIX:Reduce unnecessary refreshes
jira: STUDIO-11645 Change-Id: I08d3f989982852217939aca5437dbc4cb4211171
This commit is contained in:
parent
51142db51c
commit
5d9ff4923c
@ -368,7 +368,7 @@ void BBLTopbar::OnRedo(wxAuiToolBarEvent& event)
|
||||
|
||||
void BBLTopbar::EnableSaveItem(bool enable)
|
||||
{
|
||||
if (m_save_item) {
|
||||
if (m_save_item && GetToolEnabled(m_save_item->GetId()) != enable) {
|
||||
this->EnableTool(m_save_item->GetId(), enable);
|
||||
Refresh();
|
||||
}
|
||||
@ -376,7 +376,7 @@ void BBLTopbar::EnableSaveItem(bool enable)
|
||||
|
||||
void BBLTopbar::EnableUndoItem(bool enable)
|
||||
{
|
||||
if (m_undo_item) {
|
||||
if (m_undo_item && GetToolEnabled(m_undo_item->GetId()) != enable) {
|
||||
this->EnableTool(m_undo_item->GetId(), enable);
|
||||
Refresh();
|
||||
}
|
||||
@ -384,7 +384,7 @@ void BBLTopbar::EnableUndoItem(bool enable)
|
||||
|
||||
void BBLTopbar::EnableRedoItem(bool enable)
|
||||
{
|
||||
if (m_redo_item) {
|
||||
if (m_redo_item && GetToolEnabled(m_redo_item->GetId()) != enable) {
|
||||
this->EnableTool(m_redo_item->GetId(), enable);
|
||||
Refresh();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user