diff options
author | Andy Shaw <andy.shaw@digia.com> | 2012-12-04 13:25:36 (GMT) |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-01-14 08:09:22 (GMT) |
commit | 22c7167904a813b4e2179719b071e5846e130e47 (patch) | |
tree | 4f16b87f84570e080ee009cb368b0d5a040b526a /src/gui/styles | |
parent | e5735c9b31651c7ddc6599a29dde055d62e3f10c (diff) | |
download | Qt-22c7167904a813b4e2179719b071e5846e130e47.zip Qt-22c7167904a813b4e2179719b071e5846e130e47.tar.gz Qt-22c7167904a813b4e2179719b071e5846e130e47.tar.bz2 |
Check for gtk_adjustment_configure as this is not always implemented
Some implementations seem to not have the gtk_adjustment_configure
function implemented so we check for this so that there is no problem
when it tries to use it.
Task-number: QTBUG-23569
QTBUG-25760
Change-Id: I777ce09268f86907f3da3cede408c9a41be566cf
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Reviewed-by: Karim Pinter <karim.pinter@digia.com>
(cherry picked from qtbase/7fcf1cf674d09d9dd1d41e2913252017f1d599ca)
Diffstat (limited to 'src/gui/styles')
-rw-r--r-- | src/gui/styles/qgtkstyle.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/styles/qgtkstyle.cpp b/src/gui/styles/qgtkstyle.cpp index f6be1b7..97756ca6 100644 --- a/src/gui/styles/qgtkstyle.cpp +++ b/src/gui/styles/qgtkstyle.cpp @@ -1708,8 +1708,10 @@ void QGtkStyle::drawComplexControl(ComplexControl control, const QStyleOptionCom GtkRange *range = (GtkRange*)(horizontal ? gtkHScrollBar : gtkVScrollBar); - GtkAdjustment *adjustment = d->gtk_range_get_adjustment(range); + GtkAdjustment *adjustment = 0; + if (d->gtk_adjustment_configure) + adjustment = d->gtk_range_get_adjustment(range); if (adjustment) { d->gtk_adjustment_configure(adjustment, fakePos, 0, maximum, 0, 0, 0); } else { |