diff --git a/src/Project-Orion/CalendarGrid.qml b/src/Project-Orion/CalendarGrid.qml index 9c31038..f6eeca7 100644 --- a/src/Project-Orion/CalendarGrid.qml +++ b/src/Project-Orion/CalendarGrid.qml @@ -7,19 +7,16 @@ Flickable { id: flickable width: 200 height: 200 - onDragStarted: console.info("Drag has started") - onDragEnded: console.info("Drag has ended") GridLayout { columns: 1 DayOfWeekRow { locale: grid.locale - - Layout.fillWidth: true } + // We don't need a week column for the moment // WeekNumberColumn { // month: grid.month // year: grid.year @@ -35,6 +32,7 @@ Flickable { // } MonthGrid { + id: grid month: Calendar.November year: currentDate.getFullYear() @@ -42,14 +40,24 @@ Flickable { Layout.fillWidth: true Layout.fillHeight: true - delegate: Text { - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - text: model.day - color: model.month === currentDate.getMonth() ? myPalette.text : disabledPalette.text + delegate: Rectangle { + color: model.today ? "transparent": myPalette.accent + width: 30 + height: 20 + + Text { + anchors.centerIn: parent + font.pixelSize: 12 + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + text: model.day + color: model.month === currentDate.getMonth() ? myPalette.text : disabledPalette.text + } + required property var model } } } + required property date currentDate }