mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 08:47:52 -06:00
Merge remote-tracking branch 'origin/master' into ys_new_features
This commit is contained in:
commit
e4d8c5410c
10 changed files with 84 additions and 51 deletions
|
@ -2225,6 +2225,9 @@ void DoubleSlider::draw_thumbs(wxDC& dc, const wxCoord& lower_pos, const wxCoord
|
|||
|
||||
void DoubleSlider::draw_ticks(wxDC& dc)
|
||||
{
|
||||
if (!m_is_enabled_tick_manipulation)
|
||||
return;
|
||||
|
||||
dc.SetPen(m_is_enabled_tick_manipulation ? DARK_GREY_PEN : LIGHT_GREY_PEN );
|
||||
int height, width;
|
||||
get_size(&width, &height);
|
||||
|
@ -2242,6 +2245,9 @@ void DoubleSlider::draw_ticks(wxDC& dc)
|
|||
|
||||
void DoubleSlider::draw_colored_band(wxDC& dc)
|
||||
{
|
||||
if (!m_is_enabled_tick_manipulation)
|
||||
return;
|
||||
|
||||
int height, width;
|
||||
get_size(&width, &height);
|
||||
|
||||
|
@ -2311,7 +2317,7 @@ void DoubleSlider::draw_one_layer_icon(wxDC& dc)
|
|||
|
||||
void DoubleSlider::draw_revert_icon(wxDC& dc)
|
||||
{
|
||||
if (m_ticks.empty())
|
||||
if (m_ticks.empty() || !m_is_enabled_tick_manipulation)
|
||||
return;
|
||||
|
||||
int width, height;
|
||||
|
@ -2416,7 +2422,7 @@ void DoubleSlider::OnLeftDown(wxMouseEvent& event)
|
|||
m_selection == ssLower ? correct_lower_value() : correct_higher_value();
|
||||
if (!m_selection) m_selection = ssHigher;
|
||||
}
|
||||
else if (is_point_in_rect(pos, m_rect_revert_icon)) {
|
||||
else if (is_point_in_rect(pos, m_rect_revert_icon) && m_is_enabled_tick_manipulation) {
|
||||
// discard all color changes
|
||||
SetLowerValue(m_min_value);
|
||||
SetHigherValue(m_max_value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue