mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-23 14:44:19 -06:00
Follow-up of d54548367a
-> Reintroduce GLCanvas3D::m_old_size to avoid unneeded calls to render()
This commit is contained in:
parent
ef9004cee4
commit
2bd3e018b1
3 changed files with 25 additions and 1 deletions
|
@ -425,6 +425,10 @@ private:
|
|||
Model* m_model;
|
||||
BackgroundSlicingProcess *m_process;
|
||||
|
||||
#if ENABLE_SCROLLABLE_LEGEND
|
||||
std::array<unsigned int, 2> m_old_size{ 0, 0 };
|
||||
#endif // ENABLE_SCROLLABLE_LEGEND
|
||||
|
||||
// Screen is only refreshed from the OnIdle handler if it is dirty.
|
||||
bool m_dirty;
|
||||
bool m_initialized;
|
||||
|
@ -733,6 +737,10 @@ public:
|
|||
#endif
|
||||
}
|
||||
|
||||
#if ENABLE_SCROLLABLE_LEGEND
|
||||
void reset_old_size() { m_old_size = { 0, 0 }; }
|
||||
#endif // ENABLE_SCROLLABLE_LEGEND
|
||||
|
||||
private:
|
||||
bool _is_shown_on_screen() const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue