wireshark/wireshark-0011-Fix-FTBFS-Qt-Color-utils-arm.patch

27 lines
1.0 KiB
Diff
Raw Normal View History

2016-01-14 10:56:55 +00:00
diff --git a/ui/qt/color_utils.cpp b/ui/qt/color_utils.cpp
index e150a14..4fcbe9d 100644
--- a/ui/qt/color_utils.cpp
+++ b/ui/qt/color_utils.cpp
@@ -99,7 +99,7 @@ const color_t ColorUtils::toColorT(const QColor color)
QRgb ColorUtils::alphaBlend(const QColor &color1, const QColor &color2, qreal alpha)
{
- alpha = qBound(0.0, alpha, 1.0);
+ alpha = qBound<qreal>(0.0, alpha, 1.0);
int r1 = color1.red() * alpha;
int g1 = color1.green() * alpha;
diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp
index 3c9a616..56dd3ea 100644
--- a/ui/qt/main_window_slots.cpp
+++ b/ui/qt/main_window_slots.cpp
@@ -2226,7 +2226,7 @@ void MainWindow::zoomText()
mono_font_ = QFont(wsApp->monospaceFont());
qreal zoom_size = wsApp->monospaceFont().pointSize() * 2 * qPow(1.1, recent.gui_zoom_level);
zoom_size = qRound(zoom_size) / 2.0;
- zoom_size = qMax(zoom_size, 1.0);
+ zoom_size = qMax<qreal>(zoom_size, 1.0);
mono_font_.setPointSizeF(zoom_size);
emit monospaceFontChanged(mono_font_);
}