Changeset View
Changeset View
Standalone View
Standalone View
containments/desktop/package/contents/ui/FolderView.qml
Show First 20 Lines • Show All 766 Lines • ▼ Show 20 Line(s) | 765 | if (cachedRectangleSelection.length) { | |||
---|---|---|---|---|---|
767 | // cachedRectangleSelection is pre-sorted. | 767 | // cachedRectangleSelection is pre-sorted. | ||
768 | currentIndex = cachedRectangleSelection[0]; | 768 | currentIndex = cachedRectangleSelection[0]; | ||
769 | } | 769 | } | ||
770 | 770 | | |||
771 | dir.updateSelection(cachedRectangleSelection.map(positioner.map), | 771 | dir.updateSelection(cachedRectangleSelection.map(positioner.map), | ||
772 | gridView.ctrlPressed); | 772 | gridView.ctrlPressed); | ||
773 | } | 773 | } | ||
774 | 774 | | |||
775 | function makeIconSize() { | 775 | function makeIconSize() { | ||
776 | if (root.useListViewMode) { | 776 | if (root.useListViewMode) { | ||
777 | return units.iconSizes.small; | 777 | return units.iconSizes.small; | ||
ngraham: since makeIconSize() now does only one thing, we should probably just remove the function and… | |||||
778 | } | 778 | } | ||
779 | 779 | | |||
780 | return FolderTools.iconSizeFromTheme(plasmoid.configuration.iconSize); | 780 | return FolderTools.iconSizeFromTheme(plasmoid.configuration.iconSize); | ||
781 | } | 781 | } | ||
782 | 782 | | |||
783 | function updateSelection(modifier) { | 783 | function updateSelection(modifier) { | ||
784 | if (modifier & Qt.ShiftModifier) { | 784 | if (modifier & Qt.ShiftModifier) { | ||
785 | positioner.setRangeSelected(anchorIndex, currentIndex); | 785 | positioner.setRangeSelected(anchorIndex, currentIndex); | ||
▲ Show 20 Lines • Show All 293 Lines • ▼ Show 20 Line(s) | 1076 | Connections { | |||
1079 | onIconSizeChanged: { | 1079 | onIconSizeChanged: { | ||
1080 | gridView.iconSize = gridView.makeIconSize(); | 1080 | gridView.iconSize = gridView.makeIconSize(); | ||
1081 | } | 1081 | } | ||
1082 | } | 1082 | } | ||
1083 | 1083 | | |||
1084 | Connections { | 1084 | Connections { | ||
1085 | target: plasmoid.configuration | 1085 | target: plasmoid.configuration | ||
1086 | 1086 | | |||
1087 | onViewModeChanged: { | ||||
1088 | gridView.iconSize = gridView.makeIconSize(); | ||||
1089 | } | ||||
1090 | } | ||||
1091 | | ||||
1092 | Connections { | ||||
1093 | target: plasmoid.configuration | ||||
1094 | | ||||
1087 | onUrlChanged: { | 1095 | onUrlChanged: { | ||
1088 | history = []; | 1096 | history = []; | ||
1089 | updateHistory(); | 1097 | updateHistory(); | ||
1090 | } | 1098 | } | ||
1091 | } | 1099 | } | ||
1092 | } | 1100 | } | ||
1093 | } | 1101 | } | ||
1094 | 1102 | | |||
▲ Show 20 Lines • Show All 293 Lines • Show Last 20 Lines |
since makeIconSize() now does only one thing, we should probably just remove the function and instead just iconSize to FolderTools.iconSizeFromTheme(plasmoid.configuration.iconSize) on line 561.