From kde-commits Wed Nov 23 19:22:56 2016 From: Christian Ehrlicher Date: Wed, 23 Nov 2016 19:22:56 +0000 To: kde-commits Subject: [kcachegrind] libviews: const char* name -> const QString& name where needed, otherwise completly re Message-Id: X-MARC-Message: https://marc.info/?l=kde-commits&m=147992898614095 Git commit b80aeb816a295cfb90af13c5c4d487beb84c51c0 by Christian Ehrlicher. Committed on 23/11/2016 at 19:22. Pushed by chehrlic into branch 'master'. const char* name -> const QString& name where needed, otherwise completly r= emoved (relict from Qt3) REVIEW: 129537 M +1 -1 libviews/callgraphview.cpp M +2 -2 libviews/callgraphview.h M +1 -1 libviews/callmapview.cpp M +1 -1 libviews/callmapview.h M +1 -1 libviews/eventtypeview.cpp M +1 -1 libviews/eventtypeview.h M +1 -2 libviews/tabview.cpp M +1 -1 libviews/tabview.h https://commits.kde.org/kcachegrind/b80aeb816a295cfb90af13c5c4d487beb84c51c0 diff --git a/libviews/callgraphview.cpp b/libviews/callgraphview.cpp index 1b967d0..1df0609 100644 --- a/libviews/callgraphview.cpp +++ b/libviews/callgraphview.cpp @@ -1505,7 +1505,7 @@ void CanvasFrame::paint(QPainter* p, // CallGraphView // CallGraphView::CallGraphView(TraceItemView* parentView, QWidget* parent, - const char* name) : + const QString& name) : QGraphicsView(parent), TraceItemView(parentView) { setObjectName(name); diff --git a/libviews/callgraphview.h b/libviews/callgraphview.h index 6eb3b31..52e44f6 100644 --- a/libviews/callgraphview.h +++ b/libviews/callgraphview.h @@ -578,8 +578,8 @@ class CallGraphView : public QGraphicsView, public Trac= eItemView, public: enum ZoomPosition {TopLeft, TopRight, BottomLeft, BottomRight, Auto, H= ide}; = - explicit CallGraphView(TraceItemView* parentView, QWidget* parent=3D0, - const char* name =3D 0); + explicit CallGraphView(TraceItemView* parentView, QWidget* parent, + const QString& name); ~CallGraphView(); = void restoreOptions(const QString& prefix, const QString& postfix); diff --git a/libviews/callmapview.cpp b/libviews/callmapview.cpp index d7c7a32..1b28bc7 100644 --- a/libviews/callmapview.cpp +++ b/libviews/callmapview.cpp @@ -53,7 +53,7 @@ = = CallMapView::CallMapView(bool showCallers, TraceItemView* parentView, - QWidget* parent, const char* name) + QWidget* parent, const QString& name) : TreeMapWidget(new CallMapRootItem(), parent), TraceItemView(parentV= iew) { setObjectName(name); diff --git a/libviews/callmapview.h b/libviews/callmapview.h index f3dd83c..2bfbd2b 100644 --- a/libviews/callmapview.h +++ b/libviews/callmapview.h @@ -39,7 +39,7 @@ class CallMapView: public TreeMapWidget, public TraceItem= View public: = CallMapView(bool showCallers, TraceItemView* parentView, - QWidget* parent=3D0, const char* name=3D0); + QWidget* parent, const QString& name); = QWidget* widget() { return this; } QString whatsThis() const; diff --git a/libviews/eventtypeview.cpp b/libviews/eventtypeview.cpp index c7f46be..856830e 100644 --- a/libviews/eventtypeview.cpp +++ b/libviews/eventtypeview.cpp @@ -36,7 +36,7 @@ // = EventTypeView::EventTypeView(TraceItemView* parentView, - QWidget* parent, const char* name) + QWidget* parent, const QString& name) : QTreeWidget(parent), TraceItemView(parentView) { setObjectName(name); diff --git a/libviews/eventtypeview.h b/libviews/eventtypeview.h index 610805f..dccbdb5 100644 --- a/libviews/eventtypeview.h +++ b/libviews/eventtypeview.h @@ -34,7 +34,7 @@ class EventTypeView: public QTreeWidget, public TraceItem= View = public: explicit EventTypeView(TraceItemView* parentView, - QWidget* parent =3D 0, const char* name =3D 0); + QWidget* parent, const QString& name); = virtual QWidget* widget() { return this; } QString whatsThis() const; diff --git a/libviews/tabview.cpp b/libviews/tabview.cpp index f537fc6..1134b82 100644 --- a/libviews/tabview.cpp +++ b/libviews/tabview.cpp @@ -67,10 +67,9 @@ = // TabBar = -TabBar::TabBar(TabView* v, QTabWidget* parent, const char *name) : +TabBar::TabBar(TabView* v, QTabWidget* parent) : QTabBar(parent) { - setObjectName(name); _tabWidget =3D parent; _tabView =3D v; } diff --git a/libviews/tabview.h b/libviews/tabview.h index 9a1f007..5684252 100644 --- a/libviews/tabview.h +++ b/libviews/tabview.h @@ -49,7 +49,7 @@ class TabBar : public QTabBar Q_OBJECT = public: - TabBar(TabView*, QTabWidget* parent, const char *name =3D 0); + TabBar(TabView*, QTabWidget* parent); protected: void mousePressEvent(QMouseEvent *e); =20