Kill data.js and move all icons and functions to CameraTheme
[harmattan/cameraplus] / qml / CaptureButton.qml
index 090bb64..d314cc9 100644 (file)
@@ -25,7 +25,7 @@ import QtQuick 2.0
 Item {
     id: button
 
-    property url iconSource
+    property string iconId
     property CameraButtonStyle platformStyle: CameraButtonStyle {}
 
     property alias pressed: mouse.pressed
@@ -49,7 +49,7 @@ Item {
         border.top: button.platformStyle.backgroundMarginTop
         border.right: button.platformStyle.backgroundMarginRight
         border.bottom: button.platformStyle.backgroundMarginBottom
-        source:  pressed ? button.platformStyle.pressedBackground : button.platformStyle.background
+        source: pressed ? button.platformStyle.pressedBackground : button.platformStyle.background
     }
 
     Image {
@@ -57,7 +57,7 @@ Item {
         anchors.centerIn: parent
         anchors.verticalCenter: parent.verticalCenter
         anchors.verticalCenterOffset: -1
-        source: button.iconSource
+        source: "image://theme/" + button.iconId
         visible: source != ""
     }
 }