Commit 0a0b1a77 authored by Ahmad Samir's avatar Ahmad Samir
Browse files

More ktabwidget fixes

Summary:
Remove closeRequest() declarations as it is replaced with tabCloseRequest().

Use qCWarning() instead of kWarning().

Reviewers: dfaure, stefanocrocco

Reviewed By: dfaure

Maniphest Tasks: T11559

Differential Revision: https://phabricator.kde.org/D24789
parent 3701a34c
...@@ -34,9 +34,9 @@ ...@@ -34,9 +34,9 @@
#include <ksharedconfig.h> #include <ksharedconfig.h>
#include <kiconloader.h> #include <kiconloader.h>
#include <kstringhandler.h> #include <kstringhandler.h>
#include <kdebug.h>
#include "ktabbar.h" #include "ktabbar.h"
#include "konqdebug.h"
#include <kconfiggroup.h> #include <kconfiggroup.h>
...@@ -321,7 +321,7 @@ void KTabWidget::setTabText(int index, const QString &text) ...@@ -321,7 +321,7 @@ void KTabWidget::setTabText(int index, const QString &text)
if (index != -1) { if (index != -1) {
if (index >= d->m_tabNames.count()) { if (index >= d->m_tabNames.count()) {
kWarning(240) << "setTabText(" << index << ") called but d->m_tabNames has only" << d->m_tabNames.count() << "entries"; qCWarning(KONQUEROR_LOG) << "setTabText(" << index << ") called but d->m_tabNames has only" << d->m_tabNames.count() << "entries";
while (index >= d->m_tabNames.count()) { while (index >= d->m_tabNames.count()) {
d->m_tabNames.append(QString()); d->m_tabNames.append(QString());
} }
......
...@@ -141,12 +141,6 @@ Q_SIGNALS: ...@@ -141,12 +141,6 @@ Q_SIGNALS:
*/ */
void mouseMiddleClick(QWidget *); void mouseMiddleClick(QWidget *);
/**
* The close button of a widget's tab was clicked. This signal is
* only possible after you have called setCloseButtonEnabled( true ).
*/
void closeRequest(QWidget *);
protected: protected:
void mouseDoubleClickEvent(QMouseEvent *) override; void mouseDoubleClickEvent(QMouseEvent *) override;
void mousePressEvent(QMouseEvent *) override; void mousePressEvent(QMouseEvent *) override;
...@@ -167,7 +161,6 @@ protected Q_SLOTS: ...@@ -167,7 +161,6 @@ protected Q_SLOTS:
virtual void contextMenu(int, const QPoint &); virtual void contextMenu(int, const QPoint &);
virtual void mouseDoubleClick(int); virtual void mouseDoubleClick(int);
virtual void mouseMiddleClick(int); virtual void mouseMiddleClick(int);
virtual void closeRequest(int);
#ifndef QT_NO_WHEELEVENT #ifndef QT_NO_WHEELEVENT
virtual void wheelDelta(int); virtual void wheelDelta(int);
#endif #endif
...@@ -179,4 +172,4 @@ private: ...@@ -179,4 +172,4 @@ private:
Q_PRIVATE_SLOT(d, void slotTabMoved(int, int)) Q_PRIVATE_SLOT(d, void slotTabMoved(int, int))
}; };
#endif #endif
\ No newline at end of file
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