various: moved more to core lib

This commit is contained in:
itsmattkc
2023-01-19 16:01:31 -08:00
parent dd9c52ab59
commit c1c6893713
92 changed files with 448 additions and 1558 deletions
+1 -1
View File
@@ -153,7 +153,7 @@ void TimeBasedWidget::UpdateMaximumScroll()
rational length = (viewer_node_) ? viewer_node_->GetLength() : 0;
if (auto_max_scrollbar_) {
scrollbar_->setMaximum(qMax(0, qCeil(TimeToScene(length)) - width()));
scrollbar_->setMaximum(std::max(0, int(std::ceil(TimeToScene(length)) - width())));
}
foreach (TimeBasedView* base, timeline_views_) {
+1 -2
View File
@@ -24,7 +24,6 @@
#include <QtMath>
#include "audio/audiovisualwaveform.h"
#include "common/clamp.h"
namespace olive {
@@ -124,7 +123,7 @@ void TimeScaledObject::SetScale(const double& scale)
{
Q_ASSERT(scale > 0);
scale_ = clamp(scale, min_scale_, max_scale_);
scale_ = std::clamp(scale, min_scale_, max_scale_);
ScaleChangedEvent(scale_);
}