summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorThierry Bastian <thierry.bastian@nokia.com>2010-12-07 00:00:11 (GMT)
committerThierry Bastian <thierry.bastian@nokia.com>2010-12-07 00:00:11 (GMT)
commitef2dc6d122a03a94da273cbbf09e8f7aec2b4f6e (patch)
treea962d5fcf9d73c952c02586aeb79fbd346befe2e /src/gui
parent3905cdb7424997f08774401e06d67d295fecb2b5 (diff)
parent54aa97bf265bfa581bb64b5968e92ce943c63802 (diff)
downloadQt-ef2dc6d122a03a94da273cbbf09e8f7aec2b4f6e.zip
Qt-ef2dc6d122a03a94da273cbbf09e8f7aec2b4f6e.tar.gz
Qt-ef2dc6d122a03a94da273cbbf09e8f7aec2b4f6e.tar.bz2
Merge branch 'master-upstream' into master-water
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/styles/qgtkstyle.cpp8
-rw-r--r--src/gui/styles/qgtkstyle_p.cpp6
-rw-r--r--src/gui/styles/qgtkstyle_p.h6
3 files changed, 5 insertions, 15 deletions
diff --git a/src/gui/styles/qgtkstyle.cpp b/src/gui/styles/qgtkstyle.cpp
index f3ec746..323639a 100644
--- a/src/gui/styles/qgtkstyle.cpp
+++ b/src/gui/styles/qgtkstyle.cpp
@@ -3017,13 +3017,7 @@ void QGtkStyle::drawControl(ControlElement element,
else if (bar->progress > bar->minimum)
fakePos = maximum - 1;
- GtkAdjustment *adjustment = d->gtk_progress_get_adjustment((GtkProgress*)gtkProgressBar);
- if (adjustment) {
- d->gtk_adjustment_configure(adjustment, fakePos, 0, maximum, 0, 0, 0);
- } else {
- adjustment = (GtkAdjustment*)d->gtk_adjustment_new(fakePos, 0, maximum, 0, 0, 0);
- d->gtk_progress_set_adjustment((GtkProgress*)(gtkProgressBar), adjustment);
- }
+ d->gtk_progress_configure((GtkProgress*)gtkProgressBar, fakePos, 0, maximum);
QRect progressBar;
diff --git a/src/gui/styles/qgtkstyle_p.cpp b/src/gui/styles/qgtkstyle_p.cpp
index dd20253..aa56baa 100644
--- a/src/gui/styles/qgtkstyle_p.cpp
+++ b/src/gui/styles/qgtkstyle_p.cpp
@@ -121,8 +121,7 @@ Ptr_gtk_combo_box_entry_new QGtkStylePrivate::gtk_combo_box_entry_new = 0;
Ptr_gtk_progress_bar_new QGtkStylePrivate::gtk_progress_bar_new = 0;
Ptr_gtk_container_add QGtkStylePrivate::gtk_container_add = 0;
Ptr_gtk_menu_shell_append QGtkStylePrivate::gtk_menu_shell_append = 0;
-Ptr_gtk_progress_get_adjustment QGtkStylePrivate::gtk_progress_get_adjustment = 0;
-Ptr_gtk_progress_set_adjustment QGtkStylePrivate::gtk_progress_set_adjustment = 0;
+Ptr_gtk_progress_configure QGtkStylePrivate::gtk_progress_configure = 0;
Ptr_gtk_range_get_adjustment QGtkStylePrivate::gtk_range_get_adjustment = 0;
Ptr_gtk_range_set_adjustment QGtkStylePrivate::gtk_range_set_adjustment = 0;
Ptr_gtk_range_set_inverted QGtkStylePrivate::gtk_range_set_inverted = 0;
@@ -379,8 +378,7 @@ void QGtkStylePrivate::resolveGtk() const
gtk_entry_new = (Ptr_gtk_entry_new)libgtk.resolve("gtk_entry_new");
gtk_tree_view_new = (Ptr_gtk_tree_view_new)libgtk.resolve("gtk_tree_view_new");
gtk_combo_box_new = (Ptr_gtk_combo_box_new)libgtk.resolve("gtk_combo_box_new");
- gtk_progress_get_adjustment = (Ptr_gtk_progress_get_adjustment)libgtk.resolve("gtk_progress_get_adjustment");
- gtk_progress_set_adjustment = (Ptr_gtk_progress_set_adjustment)libgtk.resolve("gtk_progress_set_adjustment");
+ gtk_progress_configure = (Ptr_gtk_progress_configure)libgtk.resolve("gtk_progress_configure");
gtk_range_get_adjustment = (Ptr_gtk_range_get_adjustment)libgtk.resolve("gtk_range_get_adjustment");
gtk_range_set_adjustment = (Ptr_gtk_range_set_adjustment)libgtk.resolve("gtk_range_set_adjustment");
gtk_range_set_inverted = (Ptr_gtk_range_set_inverted)libgtk.resolve("gtk_range_set_inverted");
diff --git a/src/gui/styles/qgtkstyle_p.h b/src/gui/styles/qgtkstyle_p.h
index 57fa2fc..16ceb3a 100644
--- a/src/gui/styles/qgtkstyle_p.h
+++ b/src/gui/styles/qgtkstyle_p.h
@@ -176,8 +176,7 @@ typedef GtkWidget* (*Ptr_gtk_statusbar_new)(void);
typedef GtkSettings* (*Ptr_gtk_settings_get_default)(void);
typedef GtkAdjustment* (*Ptr_gtk_range_get_adjustment)(GtkRange *);
typedef void (*Ptr_gtk_range_set_adjustment)(GtkRange *, GtkAdjustment *);
-typedef GtkAdjustment* (*Ptr_gtk_progress_get_adjustment)(GtkProgress *);
-typedef void (*Ptr_gtk_progress_set_adjustment)(GtkProgress *, GtkAdjustment *);
+typedef void (*Ptr_gtk_progress_configure)(GtkProgress *, double, double, double);
typedef void (*Ptr_gtk_range_set_inverted)(GtkRange*, bool);
typedef void (*Ptr_gtk_container_add)(GtkContainer *container, GtkWidget *widget);
typedef GtkIconSet* (*Ptr_gtk_icon_factory_lookup_default) (const gchar*);
@@ -396,8 +395,7 @@ public:
static Ptr_gtk_progress_bar_new gtk_progress_bar_new;
static Ptr_gtk_container_add gtk_container_add;
static Ptr_gtk_menu_shell_append gtk_menu_shell_append;
- static Ptr_gtk_progress_get_adjustment gtk_progress_get_adjustment;
- static Ptr_gtk_progress_set_adjustment gtk_progress_set_adjustment;
+ static Ptr_gtk_progress_configure gtk_progress_configure;
static Ptr_gtk_range_get_adjustment gtk_range_get_adjustment;
static Ptr_gtk_range_set_adjustment gtk_range_set_adjustment;
static Ptr_gtk_range_set_inverted gtk_range_set_inverted;