X-Git-Url: http://git.maemo.org/git/?p=lichviet;a=blobdiff_plain;f=qml%2FLichViet%2FAmDateTimeDialog.qml;fp=qml%2FLichViet%2FAmDateTimeDialog.qml;h=2cafdd242ef8f82206ccd9c940e6a68f8a075c39;hp=83f05cd11693bce6e56800f59a7e5d43e4890bc4;hb=31922fa7094d9554f2d6cef18a4f796ba22993ae;hpb=274c1daf9c51c4127195b5e8370722887dace99e diff --git a/qml/LichViet/AmDateTimeDialog.qml b/qml/LichViet/AmDateTimeDialog.qml index 83f05cd..2cafdd2 100644 --- a/qml/LichViet/AmDateTimeDialog.qml +++ b/qml/LichViet/AmDateTimeDialog.qml @@ -35,6 +35,7 @@ Item{ } signal toolbar + signal updatedate(int day, int month, int year) Rectangle { id: rectangle1 @@ -51,8 +52,9 @@ Item{ Button { id: button2 - x: 313 - anchors.right: parent.right; anchors.rightMargin: 8; y: 185; width: 140; height: 40 + anchors.right: parent.right; anchors.rightMargin: 145; y: 185; width: 100; height: 40 + anchors.horizontalCenter: parent.horizontalCenter + text: "OK" onClicked: { var lday = lunarday_pathview.currentIndex+1; @@ -76,15 +78,11 @@ Item{ if (thangnhuan!=-1 && lunarmonth_pathview.currentIndex> thangnhuan) lmonth-=1; - var finalSolarDay = Script.convertLunar2Solar(lday,lmonth,lyear,lnhuan,7) - - LC.reset(finalSolarDay[0],finalSolarDay[1],finalSolarDay[2]) - Script.calculateLunar( finalSolarDay[0], finalSolarDay[1], finalSolarDay[2]) - Script.state="mainscreen" - Script.refresh() + var finalSolarDay = Script.convertLunar2Solar(lday,lmonth,lyear,lnhuan,7); - maindatemodel.reset() - txtDATEpv.currentIndex = finalSolarDay[0]-1; + amdatetime.state="close"; + amdatetime.toolbar(); + amdatetime.updatedate(finalSolarDay[0], finalSolarDay[1], finalSolarDay[2]) } }