1 import QtQuick 1.0 // to target S60 5th Edition or Maemo 5
2 import "../UIConstants.js" as Const
8 property bool isDownload: false
9 property bool isUpload: false
13 width: mainWindow.width-3*Const.DEFAULT_MARGIN
15 signal cancel(string file);
18 spacing: Const.DEFAULT_MARGIN
19 anchors.verticalCenter: parent.verticalCenter
23 source: isDownload? "../images/download.png" :
24 isUpload? "../images/upload.png" : ""
25 visible: isDownload || isUpload
26 anchors.verticalCenter: parent.verticalCenter
31 anchors.verticalCenter: parent.verticalCenter
32 color: Const.TRANSPARENT
34 border.color: Const.DEFAULT_FOREGROUND_COLOR
37 root.width-icon.width-button.width-2*Const.DEFAULT_MARGIN :
38 root.width-button.width-1*Const.DEFAULT_MARGIN
45 color: Const.DEFAULT_FOREGROUND_COLOR
64 anchors.centerIn: parent
67 elide: Text.ElideRight
68 horizontalAlignment: Text.AlignHCenter
75 anchors.verticalCenter: parent.verticalCenter
76 iconSource: "images/close.png"
77 onButtonClicked: root.cancel(root.label)
81 function setProgres(progress) {
82 //console.log("proggress = "+progress);
83 if(bar.state!="progress") {
85 bar.state = "progress"
88 bar.width = bbar.width*progress;
94 bar.width=bbar.width/2;
100 //console.log("stop!");
108 if(bar.x+bar.width>=bbar.width)
113 if(bar.state=="right")
115 else if(bar.state=="left")