Changeset View
Changeset View
Standalone View
Standalone View
containments/desktop/package/contents/ui/FolderItemDelegate.qml
Show First 20 Lines • Show All 207 Lines • ▼ Show 20 Line(s) | 83 | Item { | |||
---|---|---|---|---|---|
208 | 208 | | |||
209 | Loader { | 209 | Loader { | ||
210 | id: frameLoader | 210 | id: frameLoader | ||
211 | 211 | | |||
212 | x: root.useListViewMode ? 0 : units.smallSpacing | 212 | x: root.useListViewMode ? 0 : units.smallSpacing | ||
213 | y: root.useListViewMode ? 0 : units.smallSpacing | 213 | y: root.useListViewMode ? 0 : units.smallSpacing | ||
214 | 214 | | |||
215 | property Item textShadow: null | 215 | property Item textShadow: null | ||
216 | property Item iconShadow: null | ||||
216 | property string prefix: "" | 217 | property string prefix: "" | ||
217 | 218 | | |||
218 | sourceComponent: frameComponent | 219 | sourceComponent: frameComponent | ||
219 | active: state !== "" | 220 | active: state !== "" | ||
220 | asynchronous: true | 221 | asynchronous: true | ||
221 | 222 | | |||
222 | width: { | 223 | width: { | ||
223 | if (root.useListViewMode) { | 224 | if (root.useListViewMode) { | ||
▲ Show 20 Lines • Show All 177 Lines • ▼ Show 20 Line(s) | 397 | FolderItemActionButton { | |||
401 | onClicked: { | 402 | onClicked: { | ||
402 | dir.setSelected(positioner.map(index)) | 403 | dir.setSelected(positioner.map(index)) | ||
403 | openPopup(); | 404 | openPopup(); | ||
404 | } | 405 | } | ||
405 | } | 406 | } | ||
406 | } | 407 | } | ||
407 | 408 | | |||
408 | Component { | 409 | Component { | ||
410 | id: iconShadowComponent | ||||
411 | | ||||
412 | DropShadow { | ||||
413 | anchors.fill: icon | ||||
414 | | ||||
415 | z: 1 | ||||
416 | | ||||
417 | verticalOffset: 1 | ||||
418 | | ||||
419 | radius: 5 | ||||
420 | samples: 10 | ||||
421 | spread: 0.05 | ||||
422 | | ||||
423 | color: "black" | ||||
424 | | ||||
425 | opacity: model.isHidden ? 0.3 : 0.6 | ||||
426 | | ||||
427 | source: icon | ||||
428 | | ||||
429 | visible: !editor || editor.targetItem != main | ||||
430 | } | ||||
431 | } | ||||
432 | | ||||
433 | Component { | ||||
409 | id: textShadowComponent | 434 | id: textShadowComponent | ||
410 | 435 | | |||
411 | DropShadow { | 436 | DropShadow { | ||
412 | anchors.fill: label | 437 | anchors.fill: label | ||
413 | 438 | | |||
414 | z: 1 | 439 | z: 1 | ||
415 | 440 | | |||
416 | horizontalOffset: 1 | 441 | horizontalOffset: 1 | ||
▲ Show 20 Lines • Show All 72 Lines • ▼ Show 20 Line(s) | 489 | Column { | |||
489 | 514 | | |||
490 | width: implicitWidth | 515 | width: implicitWidth | ||
491 | height: implicitHeight | 516 | height: implicitHeight | ||
492 | } | 517 | } | ||
493 | 518 | | |||
494 | Component.onCompleted: { | 519 | Component.onCompleted: { | ||
495 | if (root.isContainment && main.GridView.view.isRootView && root.GraphicsInfo.api === GraphicsInfo.OpenGL) { | 520 | if (root.isContainment && main.GridView.view.isRootView && root.GraphicsInfo.api === GraphicsInfo.OpenGL) { | ||
496 | frameLoader.textShadow = textShadowComponent.createObject(frameLoader); | 521 | frameLoader.textShadow = textShadowComponent.createObject(frameLoader); | ||
522 | frameLoader.iconShadow = iconShadowComponent.createObject(frameLoader); | ||||
497 | } | 523 | } | ||
498 | } | 524 | } | ||
499 | } | 525 | } | ||
500 | } | 526 | } | ||
501 | } | 527 | } |