diff options
Diffstat (limited to 'examples/widgets/painting/gradients/gradients.cpp')
-rw-r--r-- | examples/widgets/painting/gradients/gradients.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/widgets/painting/gradients/gradients.cpp b/examples/widgets/painting/gradients/gradients.cpp index ffca9f5560..14858b9749 100644 --- a/examples/widgets/painting/gradients/gradients.cpp +++ b/examples/widgets/painting/gradients/gradients.cpp @@ -42,6 +42,8 @@ #include "gradients.h" #include "hoverpoints.h" +#include <algorithm> + ShadeWidget::ShadeWidget(ShadeType type, QWidget *parent) : QWidget(parent), m_shade_type(type), m_alpha_gradient(QLinearGradient(0, 0, 0, 0)) { @@ -204,7 +206,7 @@ void GradientEditor::pointsUpdated() points += m_blue_shade->points(); points += m_alpha_shade->points(); - qSort(points.begin(), points.end(), x_less_than); + std::sort(points.begin(), points.end(), x_less_than); for (int i = 0; i < points.size(); ++i) { qreal x = int(points.at(i).x()); |