import CameraPlus 1.0
import QtCamera 1.0
+// TODO: qrc:/qml/PostCaptureView.qml:104:5: QML CameraToolBar: Binding loop detected for property "height"
Item {
+ id: postCaptureView
+
+ property Camera camera: null
property bool pressed: view.currentItem ? view.currentItem.playing : false
property int policyMode: view.currentItem && view.currentItem.playing ?
CameraResources.Player : settings.mode == Camera.VideoMode ? CameraResources.Video :
CameraResources.Image
property bool available: view.currentItem ? view.currentItem.itemData.available : false
+ Connections {
+ target: view.currentItem
+ onPlayingChanged: {
+ if (view.currentItem.playing) {
+ hideTimer.running = false
+ }
+ }
+ }
+
ShareHelper {
id: share
settings: platformSettings
cacheBuffer: height * 3
model: postCaptureModel
highlightRangeMode: ListView.StrictlyEnforceRange
+ interactive: view.currentItem && view.currentItem.playing ? false : true
delegate: PostCaptureItem {
width: view.width
anchors.bottomMargin: show ? 20 : -1 * (height + 20)
anchors.left: parent.left
anchors.leftMargin: 20
+ anchors.right: parent.right
+ anchors.rightMargin: 20
opacity: 0.8
property bool show: deleteDialog.isOpen || deleteDialog.isOpening ||
(view.currentItem && view.currentItem.error) && !view.currentItem.playing
Behavior on anchors.bottomMargin {
- PropertyAnimation { duration: 200; }
+ PropertyAnimation { duration: view.currentItem && view.currentItem.playing ? 0 : 200 }
}
- items: [
+ tools: CameraToolBarTools {
CameraToolIcon {
- iconId: !available ? "icon-m-toolbar-favorite-mark-dimmed-white" : view.currentItem.itemData.favorite ? "icon-m-toolbar-favorite-mark-white" : "icon-m-toolbar-favorite-unmark-white"
+ iconId: !available ? cameraTheme.favoriteDisabledIconId : view.currentItem.itemData.favorite ? cameraTheme.favoriteMarkIconId : cameraTheme.favoriteUnmarkIconId
onClicked: {
addOrRemoveFavorite()
restartTimer()
}
- },
+ }
+
CameraToolIcon {
- iconId: available ? "icon-m-toolbar-share-white" : "icon-m-toolbar-share-dimmed-white"
+ iconId: available ? cameraTheme.shareEnabledIconId : cameraTheme.shareDisabledIconId
onClicked: {
shareCurrentItem()
restartTimer()
}
- },
+ }
+
CameraToolIcon {
- iconId: available ? "icon-m-toolbar-delete-white" : "icon-m-toolbar-delete-dimmed-white"
+ iconId: available ? cameraTheme.deleteEnabledIconId : cameraTheme.deleteDisabledIconId
onClicked: {
deleteCurrentItem()
restartTimer()
}
- },
+ }
+
CameraToolIcon {
- iconId: "icon-m-toolbar-view-menu-white"
+ iconId: cameraTheme.menuIconId
onClicked: {
menu.open()
restartTimer()
}
}
- ]
+ }
}
CameraQueryDialog {
radius: toolBar.radius
Behavior on anchors.topMargin {
- PropertyAnimation { duration: 200; }
+ PropertyAnimation { duration: view.currentItem && view.currentItem.playing ? 0 : 200 }
}
Flow {