From 4a552ead9ff84e77e9bbdb107b97432777a648d8 Mon Sep 17 00:00:00 2001 From: hjk Date: Tue, 9 Dec 2008 15:25:01 +0100 Subject: use QTC_ASSERT instead of Q_ASSERT --- src/plugins/help/helpfindsupport.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/plugins/help/helpfindsupport.cpp') diff --git a/src/plugins/help/helpfindsupport.cpp b/src/plugins/help/helpfindsupport.cpp index 83ec2d1570..a26032ec2f 100644 --- a/src/plugins/help/helpfindsupport.cpp +++ b/src/plugins/help/helpfindsupport.cpp @@ -34,6 +34,8 @@ #include "helpfindsupport.h" #include "helpviewer.h" +#include + using namespace Help::Internal; HelpFindSupport::HelpFindSupport(CentralWidget *centralWidget) @@ -52,8 +54,8 @@ bool HelpFindSupport::isEnabled() const QString HelpFindSupport::currentFindString() const { - Q_ASSERT(m_centralWidget); - HelpViewer* viewer = m_centralWidget->currentHelpViewer(); + QTC_ASSERT(m_centralWidget, return QString()); + HelpViewer *viewer = m_centralWidget->currentHelpViewer(); if (!viewer) return QString(); #if !defined(QT_NO_WEBKIT) @@ -70,13 +72,13 @@ QString HelpFindSupport::completedFindString() const bool HelpFindSupport::findIncremental(const QString &txt, QTextDocument::FindFlags findFlags) { - Q_ASSERT(m_centralWidget); + QTC_ASSERT(m_centralWidget, return false); findFlags &= ~QTextDocument::FindBackward; return m_centralWidget->find(txt, findFlags, true); } bool HelpFindSupport::findStep(const QString &txt, QTextDocument::FindFlags findFlags) { - Q_ASSERT(m_centralWidget); + QTC_ASSERT(m_centralWidget, return false); return m_centralWidget->find(txt, findFlags, false); } -- cgit v1.2.1