X-Git-Url: http://cgit.sxemacs.org/?p=harmattan%2Fcameraplus;a=blobdiff_plain;f=qml%2FPostCaptureView.qml;h=b0bf1d626fb4ae4ea6fa85195b86db1f2809f49d;hp=603798ba2be6b06b4107cff7998aa99ffb53d91d;hb=862f234624baae20acbcb11f85c1082180c406bd;hpb=64114bd3bf98a8d79bfcc7bb7690c810338316e1 diff --git a/qml/PostCaptureView.qml b/qml/PostCaptureView.qml index 603798b..b0bf1d6 100644 --- a/qml/PostCaptureView.qml +++ b/qml/PostCaptureView.qml @@ -24,7 +24,10 @@ import QtQuick 2.0 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 ? @@ -32,6 +35,15 @@ Item { 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 @@ -107,6 +119,8 @@ Item { 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 || @@ -114,31 +128,34 @@ Item { (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 ? cameraTheme.favoriteDisabledIconId : view.currentItem.itemData.favorite ? cameraTheme.favoriteMarkIconId : cameraTheme.favoriteUnmarkIconId onClicked: { addOrRemoveFavorite() restartTimer() } - }, + } + CameraToolIcon { iconId: available ? cameraTheme.shareEnabledIconId : cameraTheme.shareDisabledIconId onClicked: { shareCurrentItem() restartTimer() } - }, + } + CameraToolIcon { iconId: available ? cameraTheme.deleteEnabledIconId : cameraTheme.deleteDisabledIconId onClicked: { deleteCurrentItem() restartTimer() } - }, + } + CameraToolIcon { iconId: cameraTheme.menuIconId onClicked: { @@ -146,7 +163,7 @@ Item { restartTimer() } } - ] + } } CameraQueryDialog { @@ -203,7 +220,7 @@ Item { radius: toolBar.radius Behavior on anchors.topMargin { - PropertyAnimation { duration: 200; } + PropertyAnimation { duration: view.currentItem && view.currentItem.playing ? 0 : 200 } } Flow {