mirror of
https://github.com/aseprite/aseprite.git
synced 2025-04-01 10:21:04 +00:00
[msvc] Fix problem using invalid min/max bounds in std::clamp
There is an assert() in the std::clamp() impl on MSVC that checks if the min/max values are valid.
This commit is contained in:
parent
b7d5d4a2c9
commit
6d30f274f4
@ -4253,7 +4253,10 @@ void Timeline::setLayerCollapsedFlag(const layer_t l, const bool state)
|
||||
|
||||
int Timeline::separatorX() const
|
||||
{
|
||||
return std::clamp(m_separator_x, headerBoxWidth(), bounds().w-guiscale());
|
||||
return std::clamp(m_separator_x,
|
||||
headerBoxWidth(),
|
||||
std::max(bounds().w-guiscale(),
|
||||
headerBoxWidth()));
|
||||
}
|
||||
|
||||
void Timeline::setSeparatorX(int newValue)
|
||||
|
Loading…
x
Reference in New Issue
Block a user