Commit 2210d0ed authored by Laurent Montel's avatar Laurent Montel 😁

Use Q_NULLPTR

parent 446e319b
......@@ -53,7 +53,7 @@ public:
return static_cast<KonqHistoryProvider *>(KParts::HistoryProvider::self());
}
explicit KonqHistoryProvider(QObject *parent = 0);
explicit KonqHistoryProvider(QObject *parent = Q_NULLPTR);
virtual ~KonqHistoryProvider();
/**
......
......@@ -50,7 +50,7 @@ public:
/**
* Construct a new KParts plugin.
*/
explicit AutoRefresh(QObject *parent = 0, const QVariantList &args = QVariantList());
explicit AutoRefresh(QObject *parent = Q_NULLPTR, const QVariantList &args = QVariantList());
/**
* Destructor.
......
......@@ -44,7 +44,7 @@ class FilterBar : public QWidget
Q_OBJECT
public:
explicit FilterBar(QWidget *parent = 0);
explicit FilterBar(QWidget *parent = Q_NULLPTR);
virtual ~FilterBar();
void selectAll();
......
......@@ -47,7 +47,7 @@ class SignalReceiver : public QObject
Q_OBJECT
public:
explicit SignalReceiver(QObject *parent = 0);
explicit SignalReceiver(QObject *parent = Q_NULLPTR);
virtual ~SignalReceiver();
/** returns true if any signal has been received */
......
......@@ -72,7 +72,7 @@ class FSView : public TreeMapWidget, public ScanListener
public:
enum ColorMode { None = 0, Depth, Name, Owner, Group, Mime };
explicit FSView(Inode *, QWidget *parent = 0);
explicit FSView(Inode *, QWidget *parent = Q_NULLPTR);
~FSView();
KConfig *config()
......
......@@ -156,7 +156,7 @@ ScanDir::ScanDir()
_dirty = true;
_dirsFinished = -1; /* scan not started */
_parent = 0;
_parent = Q_NULLPTR;
_manager = 0;
_listener = 0;
_data = 0;
......
......@@ -298,7 +298,7 @@ public:
Horizontal, Vertical
};
explicit TreeMapItem(TreeMapItem *parent = 0, double value = 1.0);
explicit TreeMapItem(TreeMapItem *parent = Q_NULLPTR, double value = 1.0);
TreeMapItem(TreeMapItem *parent, double value,
const QString &text1, const QString &text2 = QString(),
const QString &text3 = QString(), const QString &text4 = QString());
......@@ -496,7 +496,7 @@ public:
enum SelectionMode { Single, Multi, Extended, NoSelection };
/* The widget gets owner of the base item */
explicit TreeMapWidget(TreeMapItem *base, QWidget *parent = 0);
explicit TreeMapWidget(TreeMapItem *base, QWidget *parent = Q_NULLPTR);
~TreeMapWidget();
/**
......@@ -554,7 +554,7 @@ public:
* parent. When parent == 0, clears whole selection
* Returns true if selection changed.
*/
bool clearSelection(TreeMapItem *parent = 0);
bool clearSelection(TreeMapItem *parent = Q_NULLPTR);
/**
* Selects or unselects items in a range.
......
......@@ -47,7 +47,7 @@ public:
/**
* Constructor
*/
explicit OpenSearchManager(QObject *parent = 0);
explicit OpenSearchManager(QObject *parent = Q_NULLPTR);
virtual ~OpenSearchManager();
......
......@@ -35,7 +35,7 @@ public:
* Constructor.
* @param engineName the engine name
*/
SuggestionEngine(const QString &engineName, QObject *parent = 0);
SuggestionEngine(const QString &engineName, QObject *parent = Q_NULLPTR);
/**
* Get the request URL for the suggestion service
......
......@@ -29,7 +29,7 @@ class WebShortcutWidget : public QDialog
{
Q_OBJECT
public:
WebShortcutWidget(QWidget *parent = 0);
WebShortcutWidget(QWidget *parent = Q_NULLPTR);
void show(const QString &openSearchName, const QString &fileName);
......
......@@ -35,7 +35,7 @@ class OpenSearchEngine
public:
typedef QPair<QString, QString> Parameter;
OpenSearchEngine(QObject *parent = 0);
OpenSearchEngine(QObject *parent = Q_NULLPTR);
~OpenSearchEngine();
QString name() const;
......
......@@ -234,7 +234,7 @@ private:
class SearchBarItemDelegate : public QItemDelegate
{
public:
SearchBarItemDelegate(QObject *parent = 0);
SearchBarItemDelegate(QObject *parent = Q_NULLPTR);
virtual void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const;
};
......
......@@ -29,7 +29,7 @@ class KShellCommandDialog: public KDialog
{
Q_OBJECT
public:
KShellCommandDialog(const QString &title, const QString &command, QWidget *parent = 0, bool modal = false);
KShellCommandDialog(const QString &title, const QString &command, QWidget *parent = Q_NULLPTR, bool modal = false);
virtual ~KShellCommandDialog();
//blocking
int executeCommand();
......
......@@ -32,7 +32,7 @@ class KShellCommandExecutor: public QTextEdit
{
Q_OBJECT
public:
explicit KShellCommandExecutor(const QString &command, QWidget *parent = 0);
explicit KShellCommandExecutor(const QString &command, QWidget *parent = Q_NULLPTR);
virtual ~KShellCommandExecutor();
int exec();
Q_SIGNALS:
......
......@@ -28,7 +28,7 @@ class ClickIconLabel : public QWidget
{
Q_OBJECT
public:
ClickIconLabel(QWidget *parent = 0);
ClickIconLabel(QWidget *parent = Q_NULLPTR);
void setText(const QString &text);
void setPixmap(const QPixmap &pixmap);
......
......@@ -36,7 +36,7 @@ class ValidatorsDialog : public KPageDialog
Q_OBJECT
public:
explicit ValidatorsDialog(QWidget *parent = 0);
explicit ValidatorsDialog(QWidget *parent = Q_NULLPTR);
~ValidatorsDialog();
signals:
......
......@@ -50,7 +50,7 @@ class CSSConfig : public QWidget
public:
explicit CSSConfig(QWidget *parent = 0L, const QVariantList &list = QVariantList());
explicit CSSConfig(QWidget *parent = Q_NULLPTR, const QVariantList &list = QVariantList());
void load();
void save();
......
......@@ -36,7 +36,7 @@ class AutomaticFilterModel : public QAbstractItemModel
{
Q_OBJECT
public:
AutomaticFilterModel(QObject *parent = 0);
AutomaticFilterModel(QObject *parent = Q_NULLPTR);
void load(KConfigGroup &cg);
void save(KConfigGroup &cg);
......
......@@ -213,7 +213,7 @@ public:
* @param title title for group box
* @param parent parent widget
*/
JSPoliciesFrame(JSPolicies *policies, const QString &title, QWidget *parent = 0);
JSPoliciesFrame(JSPolicies *policies, const QString &title, QWidget *parent = Q_NULLPTR);
virtual ~JSPoliciesFrame();
......
......@@ -50,7 +50,7 @@ public:
* @param parent parent widget this belongs to
* @param name internal name
*/
explicit PolicyDialog(Policies *policies, QWidget *parent = 0, const char *name = 0);
explicit PolicyDialog(Policies *policies, QWidget *parent = Q_NULLPTR, const char *name = 0);
virtual ~PolicyDialog() {}
......
......@@ -54,7 +54,7 @@ public:
*/
KBookmarkBar(KBookmarkManager *manager,
KBookmarkOwner *owner, KToolBar *toolBar,
QObject *parent = 0);
QObject *parent = Q_NULLPTR);
virtual ~KBookmarkBar();
......
......@@ -77,8 +77,8 @@ class KonqListWidgetItem : public QListWidgetItem
public:
enum ItemType { KonqItemType = 0x1845D5CC };
KonqListWidgetItem(QListWidget *parent = 0);
KonqListWidgetItem(const QString &text, QListWidget *parent = 0);
KonqListWidgetItem(QListWidget *parent = Q_NULLPTR);
KonqListWidgetItem(const QString &text, QListWidget *parent = Q_NULLPTR);
QVariant data(int role) const;
......@@ -103,7 +103,7 @@ public:
class KonqComboLineEdit : public KLineEdit
{
public:
KonqComboLineEdit(QWidget *parent = 0);
KonqComboLineEdit(QWidget *parent = Q_NULLPTR);
void setCompletedItems(const QStringList &items, bool);
protected:
......
......@@ -50,7 +50,7 @@ class KonqCheckBox : public QCheckBox
{
//Q_OBJECT // for classname. not used, and needs a moc
public:
explicit KonqCheckBox(QWidget *parent = 0)
explicit KonqCheckBox(QWidget *parent = Q_NULLPTR)
: QCheckBox(parent) {}
protected:
void paintEvent(QPaintEvent *);
......
......@@ -41,7 +41,7 @@ class KonqFrameStatusBar : public KStatusBar
Q_OBJECT
public:
explicit KonqFrameStatusBar(KonqFrame *_parent = 0);
explicit KonqFrameStatusBar(KonqFrame *_parent = Q_NULLPTR);
virtual ~KonqFrameStatusBar();
void setMessage(const QString &msg, KonqStatusBarMessageLabel::Type type);
......
......@@ -32,7 +32,7 @@ class KonqHistoryDialog : public KDialog
Q_OBJECT
public:
KonqHistoryDialog(KonqMainWindow *parent = 0);
KonqHistoryDialog(KonqMainWindow *parent = Q_NULLPTR);
~KonqHistoryDialog();
QSize sizeHint() const;
......
......@@ -57,7 +57,7 @@ public:
return static_cast<KonqHistoryManager *>(KParts::HistoryProvider::self());
}
explicit KonqHistoryManager(KBookmarkManager *bookmarkManager, QObject *parent = 0);
explicit KonqHistoryManager(KBookmarkManager *bookmarkManager, QObject *parent = Q_NULLPTR);
~KonqHistoryManager();
/**
......
......@@ -37,7 +37,7 @@ class KonqHistoryModel : public QAbstractItemModel
Q_OBJECT
public:
explicit KonqHistoryModel(QObject *parent = 0);
explicit KonqHistoryModel(QObject *parent = Q_NULLPTR);
~KonqHistoryModel();
// reimplementations from QAbstractItemModel
......
......@@ -36,7 +36,7 @@ class KonqHistoryProxyModel : public KSortFilterProxyModel
Q_OBJECT
public:
explicit KonqHistoryProxyModel(KonqHistorySettings *settings, QObject *parent = 0);
explicit KonqHistoryProxyModel(KonqHistorySettings *settings, QObject *parent = Q_NULLPTR);
~KonqHistoryProxyModel();
virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
......
......@@ -52,7 +52,7 @@ class KonqSessionDlg::KonqSessionDlgPrivate : public QWidget,
public Ui::KonqSessionDlgBase
{
public:
KonqSessionDlgPrivate(KonqViewManager *manager, QWidget *parent = 0)
KonqSessionDlgPrivate(KonqViewManager *manager, QWidget *parent = Q_NULLPTR)
: QWidget(parent), m_pViewManager(manager), m_pParent(parent)
{
setupUi(this);
......@@ -205,7 +205,7 @@ class KonqNewSessionDlg::KonqNewSessionDlgPrivate : public QWidget,
public Ui::KonqNewSessionDlgBase
{
public:
KonqNewSessionDlgPrivate(QWidget *parent = 0)
KonqNewSessionDlgPrivate(QWidget *parent = Q_NULLPTR)
: QWidget(parent), m_pParent(parent)
{
setupUi(this);
......
......@@ -36,7 +36,7 @@ class KonqSessionDlg : public KDialog
{
Q_OBJECT
public:
explicit KonqSessionDlg(KonqViewManager *manager, QWidget *parent = 0L);
explicit KonqSessionDlg(KonqViewManager *manager, QWidget *parent = Q_NULLPTR);
~KonqSessionDlg();
protected Q_SLOTS:
......@@ -57,7 +57,7 @@ class KonqNewSessionDlg : public KDialog
{
Q_OBJECT
public:
explicit KonqNewSessionDlg(QWidget *parent = 0L, QString sessionName = QString());
explicit KonqNewSessionDlg(QWidget *parent = Q_NULLPTR, QString sessionName = QString());
~KonqNewSessionDlg();
protected Q_SLOTS:
......
......@@ -38,7 +38,7 @@ class SessionRestoreDialog : public KDialog
{
Q_OBJECT
public:
explicit SessionRestoreDialog(const QStringList &sessionFilePaths, QWidget *parent = 0);
explicit SessionRestoreDialog(const QStringList &sessionFilePaths, QWidget *parent = Q_NULLPTR);
virtual ~SessionRestoreDialog();
/**
......@@ -106,7 +106,7 @@ public:
* openTabsInsideCurrentWindow is set to true. Otherwise it won't be used.
*/
void restoreSessions(const QStringList &sessionFilePathsList, bool
openTabsInsideCurrentWindow = false, KonqMainWindow *parent = 0L);
openTabsInsideCurrentWindow = false, KonqMainWindow *parent = Q_NULLPTR);
/**
* Restore saved session(s).
......@@ -119,7 +119,7 @@ public:
* openTabsInsideCurrentWindow is set to true. Otherwise it won't be used.
*/
void restoreSessions(const QString &sessionsDir, bool
openTabsInsideCurrentWindow = false, KonqMainWindow *parent = 0L);
openTabsInsideCurrentWindow = false, KonqMainWindow *parent = Q_NULLPTR);
/**
* Restore saved session.
......@@ -130,7 +130,7 @@ public:
* openTabsInsideCurrentWindow is set to true. Otherwise it won't be used.
*/
void restoreSession(const QString &sessionFilePath, bool
openTabsInsideCurrentWindow = false, KonqMainWindow *parent = 0L);
openTabsInsideCurrentWindow = false, KonqMainWindow *parent = Q_NULLPTR);
/**
* Disable the autosave feature. It's called when a konqueror instance is
......
......@@ -40,7 +40,7 @@ class KSortFilterProxyModel
Q_OBJECT
public:
/*! Constructs a sorting filter model with the given parent. */
KSortFilterProxyModel(QObject *parent = 0);
KSortFilterProxyModel(QObject *parent = Q_NULLPTR);
/*! Destroys this sorting filter model. */
~KSortFilterProxyModel();
......
......@@ -25,7 +25,7 @@ class SCWMainWindow : public QMainWindow
{
Q_OBJECT
public:
SCWMainWindow(QWidget *parent = 0);
SCWMainWindow(QWidget *parent = Q_NULLPTR);
private slots:
void slotSwitchCentralWidget();
......
......@@ -31,7 +31,7 @@ class FeaturePermissionBar : public KMessageWidget
{
Q_OBJECT
public:
explicit FeaturePermissionBar(QWidget *parent = 0);
explicit FeaturePermissionBar(QWidget *parent = Q_NULLPTR);
~FeaturePermissionBar();
QWebEnginePage::Feature feature() const;
......
......@@ -31,7 +31,7 @@ class PasswordBar : public KMessageWidget
{
Q_OBJECT
public:
explicit PasswordBar(QWidget *parent = 0);
explicit PasswordBar(QWidget *parent = Q_NULLPTR);
~PasswordBar();
QUrl url() const;
......
......@@ -39,7 +39,7 @@ class SearchBar : public QWidget
Q_OBJECT
public:
SearchBar(QWidget *parent = 0);
SearchBar(QWidget *parent = Q_NULLPTR);
~SearchBar();
QString searchText() const;
......
......@@ -59,7 +59,7 @@ class KWEBENGINEPARTLIB_EXPORT WebEnginePart : public KParts::ReadOnlyPart
Q_OBJECT
Q_PROPERTY( bool modified READ isModified )
public:
explicit WebEnginePart(QWidget* parentWidget = 0, QObject* parent = 0,
explicit WebEnginePart(QWidget* parentWidget = 0, QObject* parent = Q_NULLPTR,
const QByteArray& cachedHistory = QByteArray(),
const QStringList& = QStringList());
~WebEnginePart();
......
......@@ -26,7 +26,7 @@
class WebHistoryInterface
{
public:
WebHistoryInterface(QObject* parent = 0);
WebHistoryInterface(QObject* parent = Q_NULLPTR);
void addHistoryEntry (const QString & url);
bool historyContains (const QString & url) const;
};
......
......@@ -43,7 +43,7 @@ class WebPage : public QWebEnginePage
{
Q_OBJECT
public:
explicit WebPage(WebEnginePart *wpart, QWidget *parent = 0);
explicit WebPage(WebEnginePart *wpart, QWidget *parent = Q_NULLPTR);
~WebPage();
/**
......@@ -140,7 +140,7 @@ class NewWindowPage : public WebPage
Q_OBJECT
public:
NewWindowPage(WebWindowType windowType, WebEnginePart* part,
QWidget* parent = 0);
QWidget* parent = Q_NULLPTR);
virtual ~NewWindowPage();
protected:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment