mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 08:47:52 -06:00
Modified rendering of DoubleSlider::Control when disabled
This commit is contained in:
parent
cf013d5ab3
commit
3fdc48452e
2 changed files with 20 additions and 15 deletions
|
@ -447,6 +447,7 @@ void Control::render()
|
||||||
// and only in a case of no-empty m_values
|
// and only in a case of no-empty m_values
|
||||||
draw_colored_band(dc);
|
draw_colored_band(dc);
|
||||||
|
|
||||||
|
if (this->IsEnabled()) {
|
||||||
// draw line
|
// draw line
|
||||||
draw_scroll_line(dc, lower_pos, higher_pos);
|
draw_scroll_line(dc, lower_pos, higher_pos);
|
||||||
|
|
||||||
|
@ -456,6 +457,7 @@ void Control::render()
|
||||||
// draw both sliders
|
// draw both sliders
|
||||||
draw_thumbs(dc, lower_pos, higher_pos);
|
draw_thumbs(dc, lower_pos, higher_pos);
|
||||||
|
|
||||||
|
|
||||||
// draw lock/unlock
|
// draw lock/unlock
|
||||||
draw_one_layer_icon(dc);
|
draw_one_layer_icon(dc);
|
||||||
|
|
||||||
|
@ -468,6 +470,7 @@ void Control::render()
|
||||||
// draw mouse position
|
// draw mouse position
|
||||||
draw_tick_on_mouse_position(dc);
|
draw_tick_on_mouse_position(dc);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void Control::draw_action_icon(wxDC& dc, const wxPoint pt_beg, const wxPoint pt_end)
|
void Control::draw_action_icon(wxDC& dc, const wxPoint pt_beg, const wxPoint pt_end)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1173,8 +1173,10 @@ void Preview::update_moves_slider()
|
||||||
|
|
||||||
void Preview::enable_moves_slider(bool enable)
|
void Preview::enable_moves_slider(bool enable)
|
||||||
{
|
{
|
||||||
if (m_moves_slider != nullptr)
|
if (m_moves_slider != nullptr && m_moves_slider->IsEnabled() != enable) {
|
||||||
m_moves_slider->Enable(enable);
|
m_moves_slider->Enable(enable);
|
||||||
|
m_moves_slider->Refresh();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
void Preview::update_double_slider_from_canvas(wxKeyEvent & event)
|
void Preview::update_double_slider_from_canvas(wxKeyEvent & event)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue