| Line | Source Code | Coverage |
|---|
| 1 | | - |
| 2 | | - |
| 3 | | - |
| 4 | QPlatformDialogHelper::QPlatformDialogHelper() | - |
| 5 | { | - |
| 6 | } | - |
| 7 | | - |
| 8 | QPlatformDialogHelper::~QPlatformDialogHelper() | - |
| 9 | { | - |
| 10 | } | - |
| 11 | | - |
| 12 | QVariant QPlatformDialogHelper::styleHint(StyleHint hint) const | - |
| 13 | { | - |
| 14 | return QPlatformDialogHelper::defaultStyleHint(hint); never executed: return QPlatformDialogHelper::defaultStyleHint(hint); | 0 |
| 15 | } | - |
| 16 | | - |
| 17 | QVariant QPlatformDialogHelper::defaultStyleHint(QPlatformDialogHelper::StyleHint hint) | - |
| 18 | { | - |
| 19 | switch (hint) { | - |
| 20 | case QPlatformDialogHelper::SnapToDefaultButton: | - |
| 21 | return QVariant(false); never executed: return QVariant(false); | 0 |
| 22 | } | - |
| 23 | return QVariant(); never executed: return QVariant(); | 0 |
| 24 | } | - |
| 25 | | - |
| 26 | | - |
| 27 | | - |
| 28 | class QFontDialogOptionsPrivate : public QSharedData | - |
| 29 | { | - |
| 30 | public: | - |
| 31 | QFontDialogOptionsPrivate() : options(0) {} executed: }Execution Count:3 | 3 |
| 32 | | - |
| 33 | QFontDialogOptions::FontDialogOptions options; | - |
| 34 | QString windowTitle; | - |
| 35 | }; | - |
| 36 | | - |
| 37 | QFontDialogOptions::QFontDialogOptions() : d(new QFontDialogOptionsPrivate) | - |
| 38 | { | - |
| 39 | } executed: }Execution Count:3 | 3 |
| 40 | | - |
| 41 | QFontDialogOptions::QFontDialogOptions(const QFontDialogOptions &rhs) : d(rhs.d) | - |
| 42 | { | - |
| 43 | } | 0 |
| 44 | | - |
| 45 | QFontDialogOptions &QFontDialogOptions::operator=(const QFontDialogOptions &rhs) | - |
| 46 | { | - |
| 47 | if (this != &rhs) never evaluated: this != &rhs | 0 |
| 48 | d = rhs.d; never executed: d = rhs.d; | 0 |
| 49 | return *this; never executed: return *this; | 0 |
| 50 | } | - |
| 51 | | - |
| 52 | QFontDialogOptions::~QFontDialogOptions() | - |
| 53 | { | - |
| 54 | } | - |
| 55 | | - |
| 56 | QString QFontDialogOptions::windowTitle() const | - |
| 57 | { | - |
| 58 | return d->windowTitle; never executed: return d->windowTitle; | 0 |
| 59 | } | - |
| 60 | | - |
| 61 | void QFontDialogOptions::setWindowTitle(const QString &title) | - |
| 62 | { | - |
| 63 | d->windowTitle = title; | - |
| 64 | } | 0 |
| 65 | | - |
| 66 | void QFontDialogOptions::setOption(QFontDialogOptions::FontDialogOption option, bool on) | - |
| 67 | { | - |
| 68 | if (!(d->options & option) != !on) never evaluated: !(d->options & option) != !on | 0 |
| 69 | setOptions(d->options ^ option); never executed: setOptions(d->options ^ option); | 0 |
| 70 | } | 0 |
| 71 | | - |
| 72 | bool QFontDialogOptions::testOption(QFontDialogOptions::FontDialogOption option) const | - |
| 73 | { | - |
| 74 | return d->options & option; never executed: return d->options & option; | 0 |
| 75 | } | - |
| 76 | | - |
| 77 | void QFontDialogOptions::setOptions(FontDialogOptions options) | - |
| 78 | { | - |
| 79 | if (options != d->options) partially evaluated: options != d->options| yes Evaluation Count:1 | no Evaluation Count:0 |
| 0-1 |
| 80 | d->options = options; executed: d->options = options;Execution Count:1 | 1 |
| 81 | } executed: }Execution Count:1 | 1 |
| 82 | | - |
| 83 | QFontDialogOptions::FontDialogOptions QFontDialogOptions::options() const | - |
| 84 | { | - |
| 85 | return d->options; executed: return d->options;Execution Count:103 | 103 |
| 86 | } | - |
| 87 | const QSharedPointer<QFontDialogOptions> &QPlatformFontDialogHelper::options() const | - |
| 88 | { | - |
| 89 | return m_options; never executed: return m_options; | 0 |
| 90 | } | - |
| 91 | | - |
| 92 | void QPlatformFontDialogHelper::setOptions(const QSharedPointer<QFontDialogOptions> &options) | - |
| 93 | { | - |
| 94 | m_options = options; | - |
| 95 | } | 0 |
| 96 | | - |
| 97 | | - |
| 98 | | - |
| 99 | class QColorDialogStaticData | - |
| 100 | { | - |
| 101 | public: | - |
| 102 | enum { CustomColorCount = 16, StandardColorCount = 6 * 8 }; | - |
| 103 | | - |
| 104 | QColorDialogStaticData(); | - |
| 105 | inline void readSettings(); | - |
| 106 | inline void writeSettings() const; | - |
| 107 | | - |
| 108 | QRgb customRgb[CustomColorCount]; | - |
| 109 | QRgb standardRgb[StandardColorCount]; | - |
| 110 | bool customSet; | - |
| 111 | }; | - |
| 112 | | - |
| 113 | QColorDialogStaticData::QColorDialogStaticData() : customSet(false) | - |
| 114 | { | - |
| 115 | int i = 0; | - |
| 116 | for (int g = 0; g < 4; ++g) evaluated: g < 4| yes Evaluation Count:4 | yes Evaluation Count:1 |
| 1-4 |
| 117 | for (int r = 0; r < 4; ++r) evaluated: r < 4| yes Evaluation Count:16 | yes Evaluation Count:4 |
| 4-16 |
| 118 | for (int b = 0; b < 3; ++b) evaluated: b < 3| yes Evaluation Count:48 | yes Evaluation Count:16 |
| 16-48 |
| 119 | standardRgb[i++] = qRgb(r * 255 / 3, g * 255 / 3, b * 255 / 2); executed: standardRgb[i++] = qRgb(r * 255 / 3, g * 255 / 3, b * 255 / 2);Execution Count:48 | 48 |
| 120 | qFill(customRgb, customRgb + CustomColorCount, 0xffffffff); | - |
| 121 | readSettings(); | - |
| 122 | } executed: }Execution Count:1 | 1 |
| 123 | | - |
| 124 | void QColorDialogStaticData::readSettings() | - |
| 125 | { | - |
| 126 | | - |
| 127 | const QSettings settings(QSettings::UserScope, QString::fromUtf8("" "QtProject" "", sizeof("QtProject") - 1)); | - |
| 128 | for (int i = 0; i < int(CustomColorCount); ++i) { evaluated: i < int(CustomColorCount)| yes Evaluation Count:16 | yes Evaluation Count:1 |
| 1-16 |
| 129 | const QVariant v = settings.value(QString::fromUtf8("" "Qt/customColors/" "", sizeof("Qt/customColors/") - 1) + QString::number(i)); | - |
| 130 | if (v.isValid()) partially evaluated: v.isValid()| yes Evaluation Count:16 | no Evaluation Count:0 |
| 0-16 |
| 131 | customRgb[i] = v.toUInt(); executed: customRgb[i] = v.toUInt();Execution Count:16 | 16 |
| 132 | } executed: }Execution Count:16 | 16 |
| 133 | | - |
| 134 | } executed: }Execution Count:1 | 1 |
| 135 | | - |
| 136 | void QColorDialogStaticData::writeSettings() const | - |
| 137 | { | - |
| 138 | | - |
| 139 | if (!customSet) { partially evaluated: !customSet| yes Evaluation Count:3 | no Evaluation Count:0 |
| 0-3 |
| 140 | QSettings settings(QSettings::UserScope, QString::fromUtf8("" "QtProject" "", sizeof("QtProject") - 1)); | - |
| 141 | for (int i = 0; i < int(CustomColorCount); ++i) evaluated: i < int(CustomColorCount)| yes Evaluation Count:48 | yes Evaluation Count:3 |
| 3-48 |
| 142 | settings.setValue(QString::fromUtf8("" "Qt/customColors/" "", sizeof("Qt/customColors/") - 1) + QString::number(i), customRgb[i]); executed: settings.setValue(QString::fromUtf8("" "Qt/customColors/" "", sizeof("Qt/customColors/") - 1) + QString::number(i), customRgb[i]);Execution Count:48 | 48 |
| 143 | } executed: }Execution Count:3 | 3 |
| 144 | | - |
| 145 | } executed: }Execution Count:3 | 3 |
| 146 | | - |
| 147 | static QColorDialogStaticData *qColorDialogStaticData() { static QGlobalStatic<QColorDialogStaticData > thisGlobalStatic = { { (0) }, false }; if (!thisGlobalStatic.pointer.load() && !thisGlobalStatic.destroyed) { QColorDialogStaticData *x = new QColorDialogStaticData; if (!thisGlobalStatic.pointer.testAndSetOrdered(0, x)) delete x; else static QGlobalStaticDeleter<QColorDialogStaticData > cleanup(thisGlobalStatic); } return thisGlobalStatic.pointer.load(); } partially evaluated: !thisGlobalStatic.pointer.testAndSetOrdered(0, x)| no Evaluation Count:0 | yes Evaluation Count:1 |
evaluated: !thisGlobalStatic.pointer.load()| yes Evaluation Count:1 | yes Evaluation Count:22 |
partially evaluated: !thisGlobalStatic.destroyed| yes Evaluation Count:1 | no Evaluation Count:0 |
never executed: delete x; executed: return thisGlobalStatic.pointer.load();Execution Count:23 | 0-23 |
| 148 | | - |
| 149 | class QColorDialogOptionsPrivate : public QSharedData | - |
| 150 | { | - |
| 151 | public: | - |
| 152 | QColorDialogOptionsPrivate() : options(0) {} executed: }Execution Count:3 | 3 |
| 153 | | - |
| 154 | ~QColorDialogOptionsPrivate() { qColorDialogStaticData()->writeSettings(); } executed: }Execution Count:3 | 3 |
| 155 | | - |
| 156 | QColorDialogOptions::ColorDialogOptions options; | - |
| 157 | QString windowTitle; | - |
| 158 | }; | - |
| 159 | | - |
| 160 | QColorDialogOptions::QColorDialogOptions() : d(new QColorDialogOptionsPrivate) | - |
| 161 | { | - |
| 162 | } executed: }Execution Count:3 | 3 |
| 163 | | - |
| 164 | QColorDialogOptions::QColorDialogOptions(const QColorDialogOptions &rhs) : d(rhs.d) | - |
| 165 | { | - |
| 166 | } | 0 |
| 167 | | - |
| 168 | QColorDialogOptions &QColorDialogOptions::operator=(const QColorDialogOptions &rhs) | - |
| 169 | { | - |
| 170 | if (this != &rhs) never evaluated: this != &rhs | 0 |
| 171 | d = rhs.d; never executed: d = rhs.d; | 0 |
| 172 | return *this; never executed: return *this; | 0 |
| 173 | } | - |
| 174 | | - |
| 175 | QColorDialogOptions::~QColorDialogOptions() | - |
| 176 | { | - |
| 177 | } | - |
| 178 | | - |
| 179 | QString QColorDialogOptions::windowTitle() const | - |
| 180 | { | - |
| 181 | return d->windowTitle; never executed: return d->windowTitle; | 0 |
| 182 | } | - |
| 183 | | - |
| 184 | void QColorDialogOptions::setWindowTitle(const QString &title) | - |
| 185 | { | - |
| 186 | d->windowTitle = title; | - |
| 187 | } | 0 |
| 188 | | - |
| 189 | void QColorDialogOptions::setOption(QColorDialogOptions::ColorDialogOption option, bool on) | - |
| 190 | { | - |
| 191 | if (!(d->options & option) != !on) never evaluated: !(d->options & option) != !on | 0 |
| 192 | setOptions(d->options ^ option); never executed: setOptions(d->options ^ option); | 0 |
| 193 | } | 0 |
| 194 | | - |
| 195 | bool QColorDialogOptions::testOption(QColorDialogOptions::ColorDialogOption option) const | - |
| 196 | { | - |
| 197 | return d->options & option; executed: return d->options & option;Execution Count:8 | 8 |
| 198 | } | - |
| 199 | | - |
| 200 | void QColorDialogOptions::setOptions(ColorDialogOptions options) | - |
| 201 | { | - |
| 202 | if (options != d->options) partially evaluated: options != d->options| yes Evaluation Count:2 | no Evaluation Count:0 |
| 0-2 |
| 203 | d->options = options; executed: d->options = options;Execution Count:2 | 2 |
| 204 | } executed: }Execution Count:2 | 2 |
| 205 | | - |
| 206 | QColorDialogOptions::ColorDialogOptions QColorDialogOptions::options() const | - |
| 207 | { | - |
| 208 | return d->options; executed: return d->options;Execution Count:30 | 30 |
| 209 | } | - |
| 210 | | - |
| 211 | int QColorDialogOptions::customColorCount() | - |
| 212 | { | - |
| 213 | return QColorDialogStaticData::CustomColorCount; never executed: return QColorDialogStaticData::CustomColorCount; | 0 |
| 214 | } | - |
| 215 | | - |
| 216 | QRgb QColorDialogOptions::customColor(int index) | - |
| 217 | { | - |
| 218 | if (uint(index) >= uint(QColorDialogStaticData::CustomColorCount)) never evaluated: uint(index) >= uint(QColorDialogStaticData::CustomColorCount) | 0 |
| 219 | return qRgb(255, 255, 255); never executed: return qRgb(255, 255, 255); | 0 |
| 220 | return qColorDialogStaticData()->customRgb[index]; never executed: return qColorDialogStaticData()->customRgb[index]; | 0 |
| 221 | } | - |
| 222 | | - |
| 223 | QRgb *QColorDialogOptions::customColors() | - |
| 224 | { | - |
| 225 | return qColorDialogStaticData()->customRgb; executed: return qColorDialogStaticData()->customRgb;Execution Count:4 | 4 |
| 226 | } | - |
| 227 | | - |
| 228 | void QColorDialogOptions::setCustomColor(int index, QRgb color) | - |
| 229 | { | - |
| 230 | if (uint(index) >= uint(QColorDialogStaticData::CustomColorCount)) never evaluated: uint(index) >= uint(QColorDialogStaticData::CustomColorCount) | 0 |
| 231 | return; | 0 |
| 232 | qColorDialogStaticData()->customSet = true; | - |
| 233 | qColorDialogStaticData()->customRgb[index] = color; | - |
| 234 | } | 0 |
| 235 | | - |
| 236 | QRgb *QColorDialogOptions::standardColors() | - |
| 237 | { | - |
| 238 | return qColorDialogStaticData()->standardRgb; executed: return qColorDialogStaticData()->standardRgb;Execution Count:8 | 8 |
| 239 | } | - |
| 240 | | - |
| 241 | QRgb QColorDialogOptions::standardColor(int index) | - |
| 242 | { | - |
| 243 | if (uint(index) >= uint(QColorDialogStaticData::StandardColorCount)) partially evaluated: uint(index) >= uint(QColorDialogStaticData::StandardColorCount)| no Evaluation Count:0 | yes Evaluation Count:8 |
| 0-8 |
| 244 | return qRgb(255, 255, 255); never executed: return qRgb(255, 255, 255); | 0 |
| 245 | return qColorDialogStaticData()->standardRgb[index]; executed: return qColorDialogStaticData()->standardRgb[index];Execution Count:8 | 8 |
| 246 | } | - |
| 247 | | - |
| 248 | void QColorDialogOptions::setStandardColor(int index, QRgb color) | - |
| 249 | { | - |
| 250 | if (uint(index) >= uint(QColorDialogStaticData::StandardColorCount)) never evaluated: uint(index) >= uint(QColorDialogStaticData::StandardColorCount) | 0 |
| 251 | return; | 0 |
| 252 | qColorDialogStaticData()->standardRgb[index] = color; | - |
| 253 | } | 0 |
| 254 | const QSharedPointer<QColorDialogOptions> &QPlatformColorDialogHelper::options() const | - |
| 255 | { | - |
| 256 | return m_options; never executed: return m_options; | 0 |
| 257 | } | - |
| 258 | | - |
| 259 | void QPlatformColorDialogHelper::setOptions(const QSharedPointer<QColorDialogOptions> &options) | - |
| 260 | { | - |
| 261 | m_options = options; | - |
| 262 | } | 0 |
| 263 | | - |
| 264 | | - |
| 265 | | - |
| 266 | class QFileDialogOptionsPrivate : public QSharedData | - |
| 267 | { | - |
| 268 | public: | - |
| 269 | QFileDialogOptionsPrivate() : options(0), | - |
| 270 | viewMode(QFileDialogOptions::Detail), | - |
| 271 | fileMode(QFileDialogOptions::AnyFile), | - |
| 272 | acceptMode(QFileDialogOptions::AcceptOpen), | - |
| 273 | filters(QDir::AllEntries | QDir::NoDotAndDotDot | QDir::AllDirs) | - |
| 274 | {} executed: }Execution Count:189 | 189 |
| 275 | | - |
| 276 | QFileDialogOptions::FileDialogOptions options; | - |
| 277 | QString windowTitle; | - |
| 278 | | - |
| 279 | QFileDialogOptions::ViewMode viewMode; | - |
| 280 | QFileDialogOptions::FileMode fileMode; | - |
| 281 | QFileDialogOptions::AcceptMode acceptMode; | - |
| 282 | QString labels[QFileDialogOptions::DialogLabelCount]; | - |
| 283 | QDir::Filters filters; | - |
| 284 | QList<QUrl> sidebarUrls; | - |
| 285 | QStringList nameFilters; | - |
| 286 | QString defaultSuffix; | - |
| 287 | QStringList history; | - |
| 288 | QString initialDirectory; | - |
| 289 | QString initiallySelectedNameFilter; | - |
| 290 | QStringList initiallySelectedFiles; | - |
| 291 | }; | - |
| 292 | | - |
| 293 | QFileDialogOptions::QFileDialogOptions() : d(new QFileDialogOptionsPrivate) | - |
| 294 | { | - |
| 295 | } executed: }Execution Count:189 | 189 |
| 296 | | - |
| 297 | QFileDialogOptions::QFileDialogOptions(const QFileDialogOptions &rhs) : d(rhs.d) | - |
| 298 | { | - |
| 299 | } | 0 |
| 300 | | - |
| 301 | QFileDialogOptions &QFileDialogOptions::operator=(const QFileDialogOptions &rhs) | - |
| 302 | { | - |
| 303 | if (this != &rhs) never evaluated: this != &rhs | 0 |
| 304 | d = rhs.d; never executed: d = rhs.d; | 0 |
| 305 | return *this; never executed: return *this; | 0 |
| 306 | } | - |
| 307 | | - |
| 308 | QFileDialogOptions::~QFileDialogOptions() | - |
| 309 | { | - |
| 310 | } | - |
| 311 | | - |
| 312 | QString QFileDialogOptions::windowTitle() const | - |
| 313 | { | - |
| 314 | return d->windowTitle; never executed: return d->windowTitle; | 0 |
| 315 | } | - |
| 316 | | - |
| 317 | void QFileDialogOptions::setWindowTitle(const QString &title) | - |
| 318 | { | - |
| 319 | d->windowTitle = title; | - |
| 320 | } | 0 |
| 321 | | - |
| 322 | void QFileDialogOptions::setOption(QFileDialogOptions::FileDialogOption option, bool on) | - |
| 323 | { | - |
| 324 | if (!(d->options & option) != !on) never evaluated: !(d->options & option) != !on | 0 |
| 325 | setOptions(d->options ^ option); never executed: setOptions(d->options ^ option); | 0 |
| 326 | } | 0 |
| 327 | | - |
| 328 | bool QFileDialogOptions::testOption(QFileDialogOptions::FileDialogOption option) const | - |
| 329 | { | - |
| 330 | return d->options & option; executed: return d->options & option;Execution Count:459 | 459 |
| 331 | } | - |
| 332 | | - |
| 333 | void QFileDialogOptions::setOptions(FileDialogOptions options) | - |
| 334 | { | - |
| 335 | if (options != d->options) partially evaluated: options != d->options| yes Evaluation Count:212 | no Evaluation Count:0 |
| 0-212 |
| 336 | d->options = options; executed: d->options = options;Execution Count:212 | 212 |
| 337 | } executed: }Execution Count:212 | 212 |
| 338 | | - |
| 339 | QFileDialogOptions::FileDialogOptions QFileDialogOptions::options() const | - |
| 340 | { | - |
| 341 | return d->options; executed: return d->options;Execution Count:709 | 709 |
| 342 | } | - |
| 343 | | - |
| 344 | QDir::Filters QFileDialogOptions::filter() const | - |
| 345 | { | - |
| 346 | return d->filters; never executed: return d->filters; | 0 |
| 347 | } | - |
| 348 | | - |
| 349 | void QFileDialogOptions::setFilter(QDir::Filters filters) | - |
| 350 | { | - |
| 351 | d->filters = filters; | - |
| 352 | } executed: }Execution Count:198 | 198 |
| 353 | | - |
| 354 | void QFileDialogOptions::setViewMode(QFileDialogOptions::ViewMode mode) | - |
| 355 | { | - |
| 356 | d->viewMode = mode; | - |
| 357 | } | 0 |
| 358 | | - |
| 359 | QFileDialogOptions::ViewMode QFileDialogOptions::viewMode() const | - |
| 360 | { | - |
| 361 | return d->viewMode; never executed: return d->viewMode; | 0 |
| 362 | } | - |
| 363 | | - |
| 364 | void QFileDialogOptions::setFileMode(QFileDialogOptions::FileMode mode) | - |
| 365 | { | - |
| 366 | d->fileMode = mode; | - |
| 367 | } executed: }Execution Count:211 | 211 |
| 368 | | - |
| 369 | QFileDialogOptions::FileMode QFileDialogOptions::fileMode() const | - |
| 370 | { | - |
| 371 | return d->fileMode; executed: return d->fileMode;Execution Count:2778 | 2778 |
| 372 | } | - |
| 373 | | - |
| 374 | void QFileDialogOptions::setAcceptMode(QFileDialogOptions::AcceptMode mode) | - |
| 375 | { | - |
| 376 | d->acceptMode = mode; | - |
| 377 | } executed: }Execution Count:217 | 217 |
| 378 | | - |
| 379 | QFileDialogOptions::AcceptMode QFileDialogOptions::acceptMode() const | - |
| 380 | { | - |
| 381 | return d->acceptMode; executed: return d->acceptMode;Execution Count:2858 | 2858 |
| 382 | } | - |
| 383 | | - |
| 384 | void QFileDialogOptions::setSidebarUrls(const QList<QUrl> &urls) | - |
| 385 | { | - |
| 386 | d->sidebarUrls = urls; | - |
| 387 | } | 0 |
| 388 | | - |
| 389 | QList<QUrl> QFileDialogOptions::sidebarUrls() const | - |
| 390 | { | - |
| 391 | return d->sidebarUrls; never executed: return d->sidebarUrls; | 0 |
| 392 | } | - |
| 393 | | - |
| 394 | void QFileDialogOptions::setNameFilters(const QStringList &filters) | - |
| 395 | { | - |
| 396 | d->nameFilters = filters; | - |
| 397 | } executed: }Execution Count:223 | 223 |
| 398 | | - |
| 399 | QStringList QFileDialogOptions::nameFilters() const | - |
| 400 | { | - |
| 401 | return d->nameFilters; executed: return d->nameFilters;Execution Count:244 | 244 |
| 402 | } | - |
| 403 | | - |
| 404 | void QFileDialogOptions::setDefaultSuffix(const QString &suffix) | - |
| 405 | { | - |
| 406 | d->defaultSuffix = suffix; | - |
| 407 | } executed: }Execution Count:2 | 2 |
| 408 | | - |
| 409 | QString QFileDialogOptions::defaultSuffix() const | - |
| 410 | { | - |
| 411 | return d->defaultSuffix; executed: return d->defaultSuffix;Execution Count:196 | 196 |
| 412 | } | - |
| 413 | | - |
| 414 | void QFileDialogOptions::setHistory(const QStringList &paths) | - |
| 415 | { | - |
| 416 | d->history = paths; | - |
| 417 | } | 0 |
| 418 | | - |
| 419 | QStringList QFileDialogOptions::history() const | - |
| 420 | { | - |
| 421 | return d->history; never executed: return d->history; | 0 |
| 422 | } | - |
| 423 | | - |
| 424 | void QFileDialogOptions::setLabelText(QFileDialogOptions::DialogLabel label, const QString &text) | - |
| 425 | { | - |
| 426 | if (label >= 0 && label < DialogLabelCount) partially evaluated: label >= 0| yes Evaluation Count:7 | no Evaluation Count:0 |
partially evaluated: label < DialogLabelCount| yes Evaluation Count:7 | no Evaluation Count:0 |
| 0-7 |
| 427 | d->labels[label] = text; executed: d->labels[label] = text;Execution Count:7 | 7 |
| 428 | } executed: }Execution Count:7 | 7 |
| 429 | | - |
| 430 | QString QFileDialogOptions::labelText(QFileDialogOptions::DialogLabel label) const | - |
| 431 | { | - |
| 432 | return (label >= 0 && label < DialogLabelCount) ? d->labels[label] : QString(); executed: return (label >= 0 && label < DialogLabelCount) ? d->labels[label] : QString();Execution Count:1 | 1 |
| 433 | } | - |
| 434 | | - |
| 435 | bool QFileDialogOptions::isLabelExplicitlySet(DialogLabel label) | - |
| 436 | { | - |
| 437 | return label >= 0 && label < DialogLabelCount && !d->labels[label].isEmpty(); executed: return label >= 0 && label < DialogLabelCount && !d->labels[label].isEmpty();Execution Count:1162 | 1162 |
| 438 | } | - |
| 439 | | - |
| 440 | QString QFileDialogOptions::initialDirectory() const | - |
| 441 | { | - |
| 442 | return d->initialDirectory; never executed: return d->initialDirectory; | 0 |
| 443 | } | - |
| 444 | | - |
| 445 | void QFileDialogOptions::setInitialDirectory(const QString &directory) | - |
| 446 | { | - |
| 447 | d->initialDirectory = directory; | - |
| 448 | } | 0 |
| 449 | | - |
| 450 | QString QFileDialogOptions::initiallySelectedNameFilter() const | - |
| 451 | { | - |
| 452 | return d->initiallySelectedNameFilter; never executed: return d->initiallySelectedNameFilter; | 0 |
| 453 | } | - |
| 454 | | - |
| 455 | void QFileDialogOptions::setInitiallySelectedNameFilter(const QString &filter) | - |
| 456 | { | - |
| 457 | d->initiallySelectedNameFilter = filter; | - |
| 458 | } | 0 |
| 459 | | - |
| 460 | QStringList QFileDialogOptions::initiallySelectedFiles() const | - |
| 461 | { | - |
| 462 | return d->initiallySelectedFiles; never executed: return d->initiallySelectedFiles; | 0 |
| 463 | } | - |
| 464 | | - |
| 465 | void QFileDialogOptions::setInitiallySelectedFiles(const QStringList &files) | - |
| 466 | { | - |
| 467 | d->initiallySelectedFiles = files; | - |
| 468 | } | 0 |
| 469 | const QSharedPointer<QFileDialogOptions> &QPlatformFileDialogHelper::options() const | - |
| 470 | { | - |
| 471 | return m_options; never executed: return m_options; | 0 |
| 472 | } | - |
| 473 | | - |
| 474 | void QPlatformFileDialogHelper::setOptions(const QSharedPointer<QFileDialogOptions> &options) | - |
| 475 | { | - |
| 476 | m_options = options; | - |
| 477 | } | 0 |
| 478 | | - |
| 479 | const char *QPlatformFileDialogHelper::filterRegExp = | - |
| 480 | "^(.*)\\(([a-zA-Z0-9_.*? +;#\\-\\[\\]@\\{\\}/!<>\\$%&=^~:\\|]*)\\)$"; | - |
| 481 | | - |
| 482 | | - |
| 483 | QStringList QPlatformFileDialogHelper::cleanFilterList(const QString &filter) | - |
| 484 | { | - |
| 485 | QRegExp regexp(QString::fromLatin1(filterRegExp)); | - |
| 486 | QString f = filter; | - |
| 487 | int i = regexp.indexIn(f); | - |
| 488 | if (i >= 0) evaluated: i >= 0| yes Evaluation Count:222 | yes Evaluation Count:3 |
| 3-222 |
| 489 | f = regexp.cap(2); executed: f = regexp.cap(2);Execution Count:222 | 222 |
| 490 | return f.split(QLatin1Char(' '), QString::SkipEmptyParts); executed: return f.split(QLatin1Char(' '), QString::SkipEmptyParts);Execution Count:225 | 225 |
| 491 | } | - |
| 492 | | - |
| 493 | | - |
| 494 | | - |
| | |