2
import Ubuntu.Components 1.1
8
property bool isCurrentMonth;
10
property bool showEvent;
11
property alias fontSize: dateLabel.font.pixelSize
14
sourceComponent: isToday && isCurrentMonth ? highLightComp : undefined
15
onSourceComponentChanged: {
16
width = Qt.binding( function() { return ( dateRootItem.height / 1.5 ); });
17
height = Qt.binding ( function() { return width} );
18
anchors.centerIn = Qt.binding( function() { return dateLabel});
24
anchors.centerIn: parent
26
fontSize: root.dateLabelFontSize
28
if( isCurrentMonth ) {
43
anchors.horizontalCenter: parent.horizontalCenter
44
anchors.top: dateLabel.bottom
45
anchors.topMargin: dateRootItem.height/4
46
sourceComponent: showEvent ? eventIndicatorComp : undefined
50
id: eventIndicatorComp
68
var selectedDate = new Date();
69
selectedDate.setFullYear(intern.monthStartYear)
70
selectedDate.setMonth(intern.monthStartMonth + 1)
71
selectedDate.setDate(date)
72
selectedDate.setMinutes(60, 0, 0)
73
pageStack.push(Qt.resolvedUrl("NewEvent.qml"), {"date":selectedDate, "model":eventModel});
76
var selectedDate = new Date(intern.monthStartYear,
77
intern.monthStartMonth,
78
intern.monthStartDate + index, 0, 0, 0, 0)
79
//If monthView is clicked then open selected DayView
80
if ( isYearView === false ) {
81
root.dateSelected(selectedDate);
83
//If yearView is clicked then open selected MonthView
85
root.monthSelected(selectedDate);