qstackedwidget.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/widgets/widgets/qstackedwidget.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7class QStackedWidgetPrivate : public QFramePrivate-
8{-
9 inline QStackedWidget* q_func() { return static_cast<QStackedWidget *>(q_ptr); } inline const QStackedWidget* q_func() const { return static_cast<const QStackedWidget *>(q_ptr); } friend class QStackedWidget;-
10public:-
11 QStackedWidgetPrivate():layout(0){}
never executed: end of block
0
12 QStackedLayout *layout;-
13 bool blockChildAdd;-
14};-
15QStackedWidget::QStackedWidget(QWidget *parent)-
16 : QFrame(*new QStackedWidgetPrivate, parent)-
17{-
18 QStackedWidgetPrivate * const d = d_func();-
19 d->layout = new QStackedLayout(this);-
20 connect(d->layout, qFlagLocation("2""widgetRemoved(int)" "\0" __FILE__ ":" "140"), this, qFlagLocation("2""widgetRemoved(int)" "\0" __FILE__ ":" "140"));-
21 connect(d->layout, qFlagLocation("2""currentChanged(int)" "\0" __FILE__ ":" "141"), this, qFlagLocation("2""currentChanged(int)" "\0" __FILE__ ":" "141"));-
22}
never executed: end of block
0
23-
24-
25-
26-
27QStackedWidget::~QStackedWidget()-
28{-
29}-
30int QStackedWidget::addWidget(QWidget *widget)-
31{-
32 return
never executed: return d_func()->layout->addWidget(widget);
d_func()->layout->addWidget(widget);
never executed: return d_func()->layout->addWidget(widget);
0
33}-
34int QStackedWidget::insertWidget(int index, QWidget *widget)-
35{-
36 return
never executed: return d_func()->layout->insertWidget(index, widget);
d_func()->layout->insertWidget(index, widget);
never executed: return d_func()->layout->insertWidget(index, widget);
0
37}-
38void QStackedWidget::removeWidget(QWidget *widget)-
39{-
40 d_func()->layout->removeWidget(widget);-
41}
never executed: end of block
0
42void QStackedWidget::setCurrentIndex(int index)-
43{-
44 d_func()->layout->setCurrentIndex(index);-
45}
never executed: end of block
0
46-
47int QStackedWidget::currentIndex() const-
48{-
49 return
never executed: return d_func()->layout->currentIndex();
d_func()->layout->currentIndex();
never executed: return d_func()->layout->currentIndex();
0
50}-
51-
52-
53-
54-
55-
56-
57QWidget *QStackedWidget::currentWidget() const-
58{-
59 return
never executed: return d_func()->layout->currentWidget();
d_func()->layout->currentWidget();
never executed: return d_func()->layout->currentWidget();
0
60}-
61void QStackedWidget::setCurrentWidget(QWidget *widget)-
62{-
63 QStackedWidgetPrivate * const d = d_func();-
64 if (__builtin_expect(!!(d->layout->indexOf(widget) == -1), false)
__builtin_expe...== -1), false)Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
65 QMessageLogger(__FILE__, 247, __PRETTY_FUNCTION__).warning("QStackedWidget::setCurrentWidget: widget %p not contained in stack", widget);-
66 return;
never executed: return;
0
67 }-
68 d->layout->setCurrentWidget(widget);-
69}
never executed: end of block
0
70-
71-
72-
73-
74-
75-
76-
77int QStackedWidget::indexOf(QWidget *widget) const-
78{-
79 return
never executed: return d_func()->layout->indexOf(widget);
d_func()->layout->indexOf(widget);
never executed: return d_func()->layout->indexOf(widget);
0
80}-
81-
82-
83-
84-
85-
86-
87-
88QWidget *QStackedWidget::widget(int index) const-
89{-
90 return
never executed: return d_func()->layout->widget(index);
d_func()->layout->widget(index);
never executed: return d_func()->layout->widget(index);
0
91}-
92int QStackedWidget::count() const-
93{-
94 return
never executed: return d_func()->layout->count();
d_func()->layout->count();
never executed: return d_func()->layout->count();
0
95}-
96-
97-
98bool QStackedWidget::event(QEvent *e)-
99{-
100 return
never executed: return QFrame::event(e);
QFrame::event(e);
never executed: return QFrame::event(e);
0
101}-
102-
103-
104-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9