diff options
Diffstat (limited to 'src/widgets/widgets/qtextbrowser.cpp')
-rw-r--r-- | src/widgets/widgets/qtextbrowser.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/widgets/widgets/qtextbrowser.cpp b/src/widgets/widgets/qtextbrowser.cpp index 2c073342b0..e88e280c16 100644 --- a/src/widgets/widgets/qtextbrowser.cpp +++ b/src/widgets/widgets/qtextbrowser.cpp @@ -93,7 +93,7 @@ public: HistoryEntry createHistoryEntry() const; - void restoreHistoryEntry(const HistoryEntry entry); + void restoreHistoryEntry(const HistoryEntry &entry); QStack<HistoryEntry> stack; QStack<HistoryEntry> forwardStack; @@ -292,7 +292,7 @@ void QTextBrowserPrivate::setSource(const QUrl &url) txt = data.toString(); #endif } - if (txt.isEmpty()) + if (Q_UNLIKELY(txt.isEmpty())) qWarning("QTextBrowser: No document for %s", url.toString().toLatin1().constData()); if (q->isVisible()) { @@ -554,7 +554,7 @@ QTextBrowserPrivate::HistoryEntry QTextBrowserPrivate::createHistoryEntry() cons return entry; } -void QTextBrowserPrivate::restoreHistoryEntry(const HistoryEntry entry) +void QTextBrowserPrivate::restoreHistoryEntry(const HistoryEntry &entry) { setSource(entry.url); hbar->setValue(entry.hpos); |