Changeset View
Changeset View
Standalone View
Standalone View
src/declarativeimports/core/iconitem.cpp
Show First 20 Lines • Show All 619 Lines • ▼ Show 20 Line(s) | 616 | } else { | |||
---|---|---|---|---|---|
620 | return; | 620 | return; | ||
621 | } | 621 | } | ||
622 | 622 | | |||
623 | // Strangely KFileItem::overlays() returns empty string-values, so | 623 | // Strangely KFileItem::overlays() returns empty string-values, so | ||
624 | // we need to check first whether an overlay must be drawn at all. | 624 | // we need to check first whether an overlay must be drawn at all. | ||
625 | // It is more efficient to do it here, as KIconLoader::drawOverlays() | 625 | // It is more efficient to do it here, as KIconLoader::drawOverlays() | ||
626 | // assumes that an overlay will be drawn and has some additional | 626 | // assumes that an overlay will be drawn and has some additional | ||
627 | // setup time. | 627 | // setup time. | ||
628 | foreach (const QString& overlay, m_overlays) { | 628 | for (const QString& overlay : qAsConst(m_overlays)) { | ||
ahmadsamir: Coding style &overlay | |||||
629 | if (!overlay.isEmpty()) { | 629 | if (!overlay.isEmpty()) { | ||
630 | // There is at least one overlay, draw all overlays above m_pixmap | 630 | // There is at least one overlay, draw all overlays above m_pixmap | ||
631 | // and cancel the check | 631 | // and cancel the check | ||
632 | KIconLoader::global()->drawOverlays(m_overlays, result, KIconLoader::Desktop); | 632 | KIconLoader::global()->drawOverlays(m_overlays, result, KIconLoader::Desktop); | ||
633 | break; | 633 | break; | ||
634 | } | 634 | } | ||
635 | } | 635 | } | ||
636 | 636 | | |||
▲ Show 20 Lines • Show All 82 Lines • Show Last 20 Lines |
Coding style &overlay