summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-10-10 07:16:53 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2009-10-10 07:16:53 (GMT)
commit57f493c176ce62b249595e1f18cacd854c1562c4 (patch)
tree12792c8364f8772d7e92af1c5a09e07e5b330ac9 /src
parenta9d73fb85226cc56c8089dfccef52eb22fe15585 (diff)
parente361321e156bf1123e0d670c052307dc00f6d3f4 (diff)
downloadQt-57f493c176ce62b249595e1f18cacd854c1562c4.zip
Qt-57f493c176ce62b249595e1f18cacd854c1562c4.tar.gz
Qt-57f493c176ce62b249595e1f18cacd854c1562c4.tar.bz2
Merge branch '4.6' of git:qt/qt into 4.6
Diffstat (limited to 'src')
-rw-r--r--src/gui/itemviews/qheaderview.cpp2
-rw-r--r--src/gui/styles/gtksymbols.cpp9
2 files changed, 6 insertions, 5 deletions
diff --git a/src/gui/itemviews/qheaderview.cpp b/src/gui/itemviews/qheaderview.cpp
index a754579..0045bd5 100644
--- a/src/gui/itemviews/qheaderview.cpp
+++ b/src/gui/itemviews/qheaderview.cpp
@@ -524,8 +524,6 @@ QSize QHeaderView::sizeHint() const
Q_D(const QHeaderView);
if (d->cachedSizeHint.isValid())
return d->cachedSizeHint;
- int width = 0;
- int height = 0;
const int sectionCount = count();
d->executePostedLayout();
diff --git a/src/gui/styles/gtksymbols.cpp b/src/gui/styles/gtksymbols.cpp
index d62f717..6ec5796 100644
--- a/src/gui/styles/gtksymbols.cpp
+++ b/src/gui/styles/gtksymbols.cpp
@@ -984,15 +984,18 @@ QIcon QGtk::getFilesystemIcon(const QFileInfo &info)
if (QGtk::gnome_vfs_init && QGtk::gnome_icon_lookup_sync) {
QGtk::gnome_vfs_init();
GtkIconTheme *theme = QGtk::gtk_icon_theme_get_default();
- QString fileurl = QUrl::fromLocalFile(info.absoluteFilePath()).toEncoded();
+ QByteArray fileurl = QUrl::fromLocalFile(info.absoluteFilePath()).toEncoded();
char * icon_name = QGtk::gnome_icon_lookup_sync(theme,
NULL,
- qPrintable(fileurl),
+ fileurl.data(),
NULL,
GNOME_ICON_LOOKUP_FLAGS_NONE,
NULL);
- return QIcon::fromTheme(icon_name);
+ QString iconName = QString::fromUtf8(icon_name);
g_free(icon_name);
+ if (iconName.startsWith(QLatin1Char('/')))
+ return QIcon(iconName);
+ return QIcon::fromTheme(iconName);
}
return icon;
}