qmimedata.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/corelib/kernel/qmimedata.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5static inline QString textUriListLiteral() { return
executed 28 times by 3 tests: return ([]() -> QString { enum { Size = sizeof(u"" "text/uri-list")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/uri-list" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
([]() -> QString { enum { Size = sizeof(u"" "text/uri-list")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/uri-list" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 28 times by 3 tests: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
qstring_literal_temp;
executed 28 times by 3 tests: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
}());
executed 28 times by 3 tests: return ([]() -> QString { enum { Size = sizeof(u"" "text/uri-list")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/uri-list" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
}
28
6static inline QString textHtmlLiteral() { return
executed 34 times by 3 tests: return ([]() -> QString { enum { Size = sizeof(u"" "text/html")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/html" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
([]() -> QString { enum { Size = sizeof(u"" "text/html")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/html" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 34 times by 3 tests: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
qstring_literal_temp;
executed 34 times by 3 tests: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
}());
executed 34 times by 3 tests: return ([]() -> QString { enum { Size = sizeof(u"" "text/html")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/html" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
}
34
7static inline QString textPlainLiteral() { return
executed 141 times by 9 tests: return ([]() -> QString { enum { Size = sizeof(u"" "text/plain")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/plain" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
([]() -> QString { enum { Size = sizeof(u"" "text/plain")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/plain" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 141 times by 9 tests: return qstring_literal_temp;
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
qstring_literal_temp;
executed 141 times by 9 tests: return qstring_literal_temp;
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
}());
executed 141 times by 9 tests: return ([]() -> QString { enum { Size = sizeof(u"" "text/plain")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "text/plain" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
}
141
8static inline QString applicationXColorLiteral() { return
executed 11 times by 1 test: return ([]() -> QString { enum { Size = sizeof(u"" "application/x-color")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "application/x-color" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
([]() -> QString { enum { Size = sizeof(u"" "application/x-color")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "application/x-color" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 11 times by 1 test: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
qstring_literal_temp;
executed 11 times by 1 test: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
}());
executed 11 times by 1 test: return ([]() -> QString { enum { Size = sizeof(u"" "application/x-color")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "application/x-color" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
}
11
9static inline QString applicationXQtImageLiteral() { return
executed 10 times by 1 test: return ([]() -> QString { enum { Size = sizeof(u"" "application/x-qt-image")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "application/x-qt-image" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
([]() -> QString { enum { Size = sizeof(u"" "application/x-qt-image")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "application/x-qt-image" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 10 times by 1 test: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
qstring_literal_temp;
executed 10 times by 1 test: return qstring_literal_temp;
Executed by:
  • tst_QMimeData
}());
executed 10 times by 1 test: return ([]() -> QString { enum { Size = sizeof(u"" "application/x-qt-image")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "application/x-qt-image" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return qstring_literal_temp; }());
Executed by:
  • tst_QMimeData
}
10
10-
11struct QMimeDataStruct-
12{-
13 QString format;-
14 QVariant data;-
15};-
16template<> class QTypeInfo<QMimeDataStruct > { public: enum { isComplex = (((Q_MOVABLE_TYPE) & Q_PRIMITIVE_TYPE) == 0), isStatic = (((Q_MOVABLE_TYPE) & (Q_MOVABLE_TYPE | Q_PRIMITIVE_TYPE)) == 0), isRelocatable = !isStatic || ((Q_MOVABLE_TYPE) & Q_RELOCATABLE_TYPE), isLarge = (sizeof(QMimeDataStruct)>sizeof(void*)), isPointer = false, isIntegral = QtPrivate::is_integral< QMimeDataStruct >::value, isDummy = (((Q_MOVABLE_TYPE) & Q_DUMMY_TYPE) != 0), sizeOf = sizeof(QMimeDataStruct) }; static inline const char *name() { return "QMimeDataStruct"; } };-
17-
18class QMimeDataPrivate : public QObjectPrivate-
19{-
20 inline QMimeData* q_func() { return static_cast<QMimeData *>(q_ptr); } inline const QMimeData* q_func() const { return static_cast<const QMimeData *>(q_ptr); } friend class QMimeData;-
21public:-
22 void removeData(const QString &format);-
23 void setData(const QString &format, const QVariant &data);-
24 QVariant getData(const QString &format) const;-
25-
26 QVariant retrieveTypedData(const QString &format, QVariant::Type type) const;-
27-
28 QVector<QMimeDataStruct> dataList;-
29};-
30-
31void QMimeDataPrivate::removeData(const QString &format)-
32{-
33 for (int i=0; i<dataList.size()
i<dataList.size()Description
TRUEevaluated 43 times by 4 tests
Evaluated by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTextEdit
FALSEevaluated 118 times by 12 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
; i++) {
43-118
34 if (dataList.at(i).format == format
dataList.at(i)...rmat == formatDescription
TRUEevaluated 8 times by 2 tests
Evaluated by:
  • tst_QMimeData
  • tst_QTextEdit
FALSEevaluated 35 times by 4 tests
Evaluated by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTextEdit
) {
8-35
35 dataList.removeAt(i);-
36 return;
executed 8 times by 2 tests: return;
Executed by:
  • tst_QMimeData
  • tst_QTextEdit
8
37 }-
38 }
executed 35 times by 4 tests: end of block
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTextEdit
35
39}
executed 118 times by 12 tests: end of block
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
118
40-
41void QMimeDataPrivate::setData(const QString &format, const QVariant &data)-
42{-
43-
44 removeData(format);-
45 QMimeDataStruct mimeData;-
46 mimeData.format = format;-
47 mimeData.data = data;-
48 dataList += mimeData;-
49}
executed 124 times by 12 tests: end of block
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
124
50-
51-
52QVariant QMimeDataPrivate::getData(const QString &format) const-
53{-
54 QVariant data;-
55 for (int i=0; i<dataList.size()
i<dataList.size()Description
TRUEevaluated 173 times by 16 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
FALSEevaluated 9 times by 1 test
Evaluated by:
  • tst_QMimeData
; i++) {
9-173
56 if (dataList.at(i).format == format
dataList.at(i)...rmat == formatDescription
TRUEevaluated 128 times by 16 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
FALSEevaluated 45 times by 6 tests
Evaluated by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTextEdit
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
) {
45-128
57 data = dataList.at(i).data;-
58 break;
executed 128 times by 16 tests: break;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
128
59 }-
60 }
executed 45 times by 6 tests: end of block
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTextEdit
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
45
61 return
executed 137 times by 16 tests: return data;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
data;
executed 137 times by 16 tests: return data;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
137
62}-
63-
64QVariant QMimeDataPrivate::retrieveTypedData(const QString &format, QVariant::Type type) const-
65{-
66 const QMimeData * const q = q_func();-
67-
68 QVariant data = q->retrieveData(format, type);-
69-
70-
71 if (format == QLatin1String("text/plain")
format == QLat...("text/plain")Description
TRUEevaluated 90 times by 13 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
FALSEevaluated 47 times by 8 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QListWidget
  • tst_QMimeData
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
&& !data.isValid()
!data.isValid()Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 86 times by 13 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
) {
4-90
72 data = retrieveTypedData(textUriListLiteral(), QVariant::List);-
73 if (data.type() == QVariant::Url
data.type() == QVariant::UrlDescription
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_QMimeData
) {
0-4
74 data = QVariant(data.toUrl().toDisplayString());-
75 }
never executed: end of block
else if (data.type() == QVariant::List
data.type() == QVariant::ListDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
) {
0-2
76 QString text;-
77 int numUrls = 0;-
78 const QList<QVariant> list = data.toList();-
79 for (int i = 0; i < list.size()
i < list.size()Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
; ++i) {
2-3
80 if (list.at(i).type() == QVariant::Url
list.at(i).typ... QVariant::UrlDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEnever evaluated
) {
0-3
81 text.append(list.at(i).toUrl().toDisplayString() + QLatin1Char('\n'));-
82 ++numUrls;-
83 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QMimeData
3
84 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QMimeData
3
85 if (numUrls == 1
numUrls == 1Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
)
1
86 text.chop(1);
executed 1 time by 1 test: text.chop(1);
Executed by:
  • tst_QMimeData
1
87 data = QVariant(text);-
88 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
89 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_QMimeData
4
90-
91 if (data.type() == type
data.type() == typeDescription
TRUEevaluated 99 times by 15 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QStyleSheetStyle
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
FALSEevaluated 38 times by 8 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
|| !data.isValid()
!data.isValid()Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 31 times by 8 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
)
7-99
92 return
executed 106 times by 15 tests: return data;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QStyleSheetStyle
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
data;
executed 106 times by 15 tests: return data;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QStyleSheetStyle
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
106
93-
94-
95-
96-
97 if ((type == QVariant::Url
type == QVariant::UrlDescription
TRUEnever evaluated
FALSEevaluated 31 times by 8 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
&& data.type() == QVariant::List
data.type() == QVariant::ListDescription
TRUEnever evaluated
FALSEnever evaluated
)
0-31
98 || (type == QVariant::List
type == QVariant::ListDescription
TRUEnever evaluated
FALSEevaluated 31 times by 8 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
&& data.type() == QVariant::Url
data.type() == QVariant::UrlDescription
TRUEnever evaluated
FALSEnever evaluated
))
0-31
99 return
never executed: return data;
data;
never executed: return data;
0
100-
101-
102 if ((type == QVariant::Pixmap
type == QVariant::PixmapDescription
TRUEnever evaluated
FALSEevaluated 31 times by 8 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
&& data.type() == QVariant::Image
data.type() == QVariant::ImageDescription
TRUEnever evaluated
FALSEnever evaluated
)
0-31
103 || (type == QVariant::Image
type == QVariant::ImageDescription
TRUEnever evaluated
FALSEevaluated 31 times by 8 tests
Evaluated by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
&& data.type() == QVariant::Pixmap
data.type() ==...ariant::PixmapDescription
TRUEnever evaluated
FALSEnever evaluated
))
0-31
104 return
never executed: return data;
data;
never executed: return data;
0
105-
106 if (data.type() == QVariant::ByteArray
data.type() ==...ant::ByteArrayDescription
TRUEevaluated 8 times by 3 tests
Evaluated by:
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
FALSEevaluated 23 times by 6 tests
Evaluated by:
  • tst_QApplication
  • tst_QMimeData
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
) {
8-23
107-
108 switch(type) {-
109-
110 case
executed 8 times by 3 tests: case QVariant::String:
Executed by:
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
QVariant::String:
executed 8 times by 3 tests: case QVariant::String:
Executed by:
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
{
8
111 const QByteArray ba = data.toByteArray();-
112 QTextCodec *codec = QTextCodec::codecForName("utf-8");-
113 if (format == QLatin1String("text/html")
format == QLat...g("text/html")Description
TRUEevaluated 5 times by 2 tests
Evaluated by:
  • tst_QMimeData
  • tst_QTextEdit
FALSEevaluated 3 times by 1 test
Evaluated by:
  • tst_QClipboard
)
3-5
114 codec = QTextCodec::codecForHtml(ba, codec);
executed 5 times by 2 tests: codec = QTextCodec::codecForHtml(ba, codec);
Executed by:
  • tst_QMimeData
  • tst_QTextEdit
5
115 return
executed 8 times by 3 tests: return codec->toUnicode(ba);
Executed by:
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
codec->toUnicode(ba);
executed 8 times by 3 tests: return codec->toUnicode(ba);
Executed by:
  • tst_QClipboard
  • tst_QMimeData
  • tst_QTextEdit
8
116 }-
117-
118 case
never executed: case QVariant::Color:
QVariant::Color:
never executed: case QVariant::Color:
{
0
119 QVariant newData = data;-
120 newData.convert(QVariant::Color);-
121 return
never executed: return newData;
newData;
never executed: return newData;
0
122 }-
123 case
never executed: case QVariant::List:
QVariant::List:
never executed: case QVariant::List:
{
0
124 if (format != QLatin1String("text/uri-list")
format != QLat...ext/uri-list")Description
TRUEnever evaluated
FALSEnever evaluated
)
0
125 break;
never executed: break;
0
126-
127 }-
128 case
never executed: case QVariant::Url:
QVariant::Url:
never executed: case QVariant::Url:
code before this statement never executed: case QVariant::Url:
{
0
129 QByteArray ba = data.toByteArray();-
130-
131-
132-
133 if (ba.endsWith('\0')
ba.endsWith('\0')Description
TRUEnever evaluated
FALSEnever evaluated
)
0
134 ba.chop(1);
never executed: ba.chop(1);
0
135-
136 QList<QByteArray> urls = ba.split('\n');-
137 QList<QVariant> list;-
138 for (int i = 0; i < urls.size()
i < urls.size()Description
TRUEnever evaluated
FALSEnever evaluated
; ++i) {
0
139 QByteArray ba = urls.at(i).trimmed();-
140 if (!ba.isEmpty()
!ba.isEmpty()Description
TRUEnever evaluated
FALSEnever evaluated
)
0
141 list.append(QUrl::fromEncoded(ba));
never executed: list.append(QUrl::fromEncoded(ba));
0
142 }
never executed: end of block
0
143 return
never executed: return list;
list;
never executed: return list;
0
144 }-
145 default
never executed: default:
:
never executed: default:
0
146 break;
never executed: break;
0
147 }-
148-
149 } else if (type == QVariant::ByteArray
type == QVariant::ByteArrayDescription
TRUEevaluated 23 times by 6 tests
Evaluated by:
  • tst_QApplication
  • tst_QMimeData
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
FALSEnever evaluated
) {
0-23
150-
151-
152 switch(data.type()) {-
153 case
never executed: case QVariant::ByteArray:
QVariant::ByteArray:
never executed: case QVariant::ByteArray:
0
154 case
never executed: case QVariant::Color:
QVariant::Color:
never executed: case QVariant::Color:
0
155 return
never executed: return data.toByteArray();
data.toByteArray();
never executed: return data.toByteArray();
0
156 case
executed 22 times by 6 tests: case QVariant::String:
Executed by:
  • tst_QApplication
  • tst_QMimeData
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
QVariant::String:
executed 22 times by 6 tests: case QVariant::String:
Executed by:
  • tst_QApplication
  • tst_QMimeData
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
22
157 return
executed 22 times by 6 tests: return data.toString().toUtf8();
Executed by:
  • tst_QApplication
  • tst_QMimeData
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
data.toString().toUtf8();
executed 22 times by 6 tests: return data.toString().toUtf8();
Executed by:
  • tst_QApplication
  • tst_QMimeData
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
22
158 case
never executed: case QVariant::Url:
QVariant::Url:
never executed: case QVariant::Url:
0
159 return
never executed: return data.toUrl().toEncoded();
data.toUrl().toEncoded();
never executed: return data.toUrl().toEncoded();
0
160 case
executed 1 time by 1 test: case QVariant::List:
Executed by:
  • tst_QMimeData
QVariant::List:
executed 1 time by 1 test: case QVariant::List:
Executed by:
  • tst_QMimeData
{
1
161-
162 QByteArray result;-
163 QList<QVariant> list = data.toList();-
164 for (int i = 0; i < list.size()
i < list.size()Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
; ++i) {
1-2
165 if (list.at(i).type() == QVariant::Url
list.at(i).typ... QVariant::UrlDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEnever evaluated
) {
0-2
166 result += list.at(i).toUrl().toEncoded();-
167 result += "\r\n";-
168 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
169 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
170 if (!result.isEmpty()
!result.isEmpty()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
FALSEnever evaluated
)
0-1
171 return
executed 1 time by 1 test: return result;
Executed by:
  • tst_QMimeData
result;
executed 1 time by 1 test: return result;
Executed by:
  • tst_QMimeData
1
172 break;
never executed: break;
0
173 }-
174 default
never executed: default:
:
never executed: default:
0
175 break;
never executed: break;
0
176 }-
177 }-
178 return
never executed: return data;
data;
never executed: return data;
0
179}-
180QMimeData::QMimeData()-
181 : QObject(*new QMimeDataPrivate, 0)-
182{-
183}
executed 237 times by 19 tests: end of block
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QDrag
  • tst_QGraphicsProxyWidget
  • tst_QGraphicsScene
  • tst_QGuiApplication
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QStyleSheetStyle
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qapplication - unknown status
  • tst_qprocess - unknown status
  • tst_selftests - unknown status
237
184-
185-
186-
187-
188QMimeData::~QMimeData()-
189{-
190}-
191QList<QUrl> QMimeData::urls() const-
192{-
193 const QMimeDataPrivate * const d = d_func();-
194 QVariant data = d->retrieveTypedData(textUriListLiteral(), QVariant::List);-
195 QList<QUrl> urls;-
196 if (data.type() == QVariant::Url
data.type() == QVariant::UrlDescription
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
)
0-2
197 urls.append(data.toUrl());
never executed: urls.append(data.toUrl());
0
198 else if (data.type() == QVariant::List
data.type() == QVariant::ListDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEnever evaluated
) {
0-2
199 QList<QVariant> list = data.toList();-
200 for (int i = 0; i < list.size()
i < list.size()Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
; ++i) {
2-3
201 if (list.at(i).type() == QVariant::Url
list.at(i).typ... QVariant::UrlDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEnever evaluated
)
0-3
202 urls.append(list.at(i).toUrl());
executed 3 times by 1 test: urls.append(list.at(i).toUrl());
Executed by:
  • tst_QMimeData
3
203 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QMimeData
3
204 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
205 return
executed 2 times by 1 test: return urls;
Executed by:
  • tst_QMimeData
urls;
executed 2 times by 1 test: return urls;
Executed by:
  • tst_QMimeData
2
206}-
207void QMimeData::setUrls(const QList<QUrl> &urls)-
208{-
209 QMimeDataPrivate * const d = d_func();-
210 QList<QVariant> list;-
211 const int numUrls = urls.size();-
212 list.reserve(numUrls);-
213 for (int i = 0; i < numUrls
i < numUrlsDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
; ++i)
2-3
214 list.append(urls.at(i));
executed 3 times by 1 test: list.append(urls.at(i));
Executed by:
  • tst_QMimeData
3
215-
216 d->setData(textUriListLiteral(), list);-
217}
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
218bool QMimeData::hasUrls() const-
219{-
220 return
executed 20 times by 3 tests: return hasFormat(textUriListLiteral());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
hasFormat(textUriListLiteral());
executed 20 times by 3 tests: return hasFormat(textUriListLiteral());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
20
221}-
222QString QMimeData::text() const-
223{-
224 const QMimeDataPrivate * const d = d_func();-
225 QVariant data = d->retrieveTypedData(textPlainLiteral(), QVariant::String);-
226 return
executed 66 times by 9 tests: return data.toString();
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
data.toString();
executed 66 times by 9 tests: return data.toString();
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStyleSheetStyle
  • tst_QTextEdit
  • tst_QWidget_window
66
227}-
228-
229-
230-
231-
232-
233-
234-
235void QMimeData::setText(const QString &text)-
236{-
237 QMimeDataPrivate * const d = d_func();-
238 d->setData(textPlainLiteral(), text);-
239}
executed 45 times by 8 tests: end of block
Executed by:
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
  • tst_QWidget_window
45
240-
241-
242-
243-
244-
245-
246-
247bool QMimeData::hasText() const-
248{-
249 return
executed 30 times by 3 tests: return hasFormat(textPlainLiteral()) || hasUrls();
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
hasFormat(textPlainLiteral()) || hasUrls();
executed 30 times by 3 tests: return hasFormat(textPlainLiteral()) || hasUrls();
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
30
250}-
251-
252-
253-
254-
255-
256-
257-
258QString QMimeData::html() const-
259{-
260 const QMimeDataPrivate * const d = d_func();-
261 QVariant data = d->retrieveTypedData(textHtmlLiteral(), QVariant::String);-
262 return
executed 7 times by 2 tests: return data.toString();
Executed by:
  • tst_QMimeData
  • tst_QTextEdit
data.toString();
executed 7 times by 2 tests: return data.toString();
Executed by:
  • tst_QMimeData
  • tst_QTextEdit
7
263}-
264-
265-
266-
267-
268-
269-
270-
271void QMimeData::setHtml(const QString &html)-
272{-
273 QMimeDataPrivate * const d = d_func();-
274 d->setData(textHtmlLiteral(), html);-
275}
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
276-
277-
278-
279-
280-
281-
282-
283bool QMimeData::hasHtml() const-
284{-
285 return
executed 25 times by 3 tests: return hasFormat(textHtmlLiteral());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
hasFormat(textHtmlLiteral());
executed 25 times by 3 tests: return hasFormat(textHtmlLiteral());
Executed by:
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QTextEdit
25
286}-
287QVariant QMimeData::imageData() const-
288{-
289 const QMimeDataPrivate * const d = d_func();-
290 return
executed 3 times by 1 test: return d->retrieveTypedData(applicationXQtImageLiteral(), QVariant::Image);
Executed by:
  • tst_QMimeData
d->retrieveTypedData(applicationXQtImageLiteral(), QVariant::Image);
executed 3 times by 1 test: return d->retrieveTypedData(applicationXQtImageLiteral(), QVariant::Image);
Executed by:
  • tst_QMimeData
3
291}-
292void QMimeData::setImageData(const QVariant &image)-
293{-
294 QMimeDataPrivate * const d = d_func();-
295 d->setData(applicationXQtImageLiteral(), image);-
296}
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
297-
298-
299-
300-
301-
302-
303-
304bool QMimeData::hasImage() const-
305{-
306 return
executed 5 times by 1 test: return hasFormat(applicationXQtImageLiteral());
Executed by:
  • tst_QMimeData
hasFormat(applicationXQtImageLiteral());
executed 5 times by 1 test: return hasFormat(applicationXQtImageLiteral());
Executed by:
  • tst_QMimeData
5
307}-
308QVariant QMimeData::colorData() const-
309{-
310 const QMimeDataPrivate * const d = d_func();-
311 return
executed 2 times by 1 test: return d->retrieveTypedData(applicationXColorLiteral(), QVariant::Color);
Executed by:
  • tst_QMimeData
d->retrieveTypedData(applicationXColorLiteral(), QVariant::Color);
executed 2 times by 1 test: return d->retrieveTypedData(applicationXColorLiteral(), QVariant::Color);
Executed by:
  • tst_QMimeData
2
312}-
313void QMimeData::setColorData(const QVariant &color)-
314{-
315 QMimeDataPrivate * const d = d_func();-
316 d->setData(applicationXColorLiteral(), color);-
317}
executed 3 times by 1 test: end of block
Executed by:
  • tst_QMimeData
3
318bool QMimeData::hasColor() const-
319{-
320 return
executed 6 times by 1 test: return hasFormat(applicationXColorLiteral());
Executed by:
  • tst_QMimeData
hasFormat(applicationXColorLiteral());
executed 6 times by 1 test: return hasFormat(applicationXColorLiteral());
Executed by:
  • tst_QMimeData
6
321}-
322-
323-
324-
325-
326-
327QByteArray QMimeData::data(const QString &mimeType) const-
328{-
329 const QMimeDataPrivate * const d = d_func();-
330 QVariant data = d->retrieveTypedData(mimeType, QVariant::ByteArray);-
331 return
executed 53 times by 11 tests: return data.toByteArray();
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QListWidget
  • tst_QMimeData
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
data.toByteArray();
executed 53 times by 11 tests: return data.toByteArray();
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QListWidget
  • tst_QMimeData
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
53
332}-
333void QMimeData::setData(const QString &mimeType, const QByteArray &data)-
334{-
335 QMimeDataPrivate * const d = d_func();-
336-
337 if (mimeType == QLatin1String("text/uri-list")
mimeType == QL...ext/uri-list")Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 69 times by 8 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QClipboard
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
) {
1-69
338 QByteArray ba = data;-
339 if (ba.endsWith('\0')
ba.endsWith('\0')Description
TRUEnever evaluated
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
)
0-1
340 ba.chop(1);
never executed: ba.chop(1);
0
341 QList<QByteArray> urls = ba.split('\n');-
342 QList<QVariant> list;-
343 for (int i = 0; i < urls.size()
i < urls.size()Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
; ++i) {
1-3
344 QByteArray ba = urls.at(i).trimmed();-
345 if (!ba.isEmpty()
!ba.isEmpty()Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QMimeData
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QMimeData
)
1-2
346 list.append(QUrl::fromEncoded(ba));
executed 2 times by 1 test: list.append(QUrl::fromEncoded(ba));
Executed by:
  • tst_QMimeData
2
347 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QMimeData
3
348 d->setData(mimeType, list);-
349 }
executed 1 time by 1 test: end of block
Executed by:
  • tst_QMimeData
else {
1
350 d->setData(mimeType, QVariant(data));-
351 }
executed 69 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemModel
  • tst_QClipboard
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
69
352}-
353bool QMimeData::hasFormat(const QString &mimeType) const-
354{-
355 return
executed 126 times by 13 tests: return formats().contains(mimeType);
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
formats().contains(mimeType);
executed 126 times by 13 tests: return formats().contains(mimeType);
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
126
356}-
357QStringList QMimeData::formats() const-
358{-
359 const QMimeDataPrivate * const d = d_func();-
360 QStringList list;-
361 const int size = d->dataList.size();-
362 list.reserve(size);-
363 for (int i = 0; i < size
i < sizeDescription
TRUEevaluated 152 times by 13 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
FALSEevaluated 124 times by 13 tests
Evaluated by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
; ++i)
124-152
364 list += d->dataList.at(i).format;
executed 152 times by 13 tests: list += d->dataList.at(i).format;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
152
365 return
executed 124 times by 13 tests: return list;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
list;
executed 124 times by 13 tests: return list;
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QGraphicsProxyWidget
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
124
366}-
367QVariant QMimeData::retrieveData(const QString &mimeType, QVariant::Type type) const-
368{-
369 (void)type;;-
370 const QMimeDataPrivate * const d = d_func();-
371 return
executed 137 times by 16 tests: return d->getData(mimeType);
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
d->getData(mimeType);
executed 137 times by 16 tests: return d->getData(mimeType);
Executed by:
  • tst_QAbstractItemModel
  • tst_QApplication
  • tst_QClipboard
  • tst_QGraphicsProxyWidget
  • tst_QLineEdit
  • tst_QListWidget
  • tst_QMimeData
  • tst_QPlainTextEdit
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTextEdit
  • tst_QWidget_window
  • tst_qclipboard - unknown status
  • tst_qlineedit - unknown status
  • tst_qplaintextedit - unknown status
  • tst_qtextedit - unknown status
137
372}-
373-
374-
375-
376-
377void QMimeData::clear()-
378{-
379 QMimeDataPrivate * const d = d_func();-
380 d->dataList.clear();-
381}
executed 12 times by 2 tests: end of block
Executed by:
  • tst_QClipboard
  • tst_QMimeData
12
382-
383-
384-
385-
386-
387-
388void QMimeData::removeFormat(const QString &mimeType)-
389{-
390 QMimeDataPrivate * const d = d_func();-
391 d->removeData(mimeType);-
392}
executed 2 times by 1 test: end of block
Executed by:
  • tst_QMimeData
2
393-
394-
Switch to Source codePreprocessed file

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