Commit 2c968927 authored by Claudio Cambra's avatar Claudio Cambra
Browse files

Remove unneeded dateutils import in datecombo and added default display value

parent 102c30f4
Pipeline #106920 passed with stage
in 6 minutes and 15 seconds
......@@ -5,7 +5,6 @@ import QtQuick 2.15
import QtQuick.Controls 2.15 as QQC2
import QtQuick.Layouts 1.15
import org.kde.kirigami 2.15 as Kirigami
import "dateutils.js" as DateUtils
QQC2.ComboBox {
id: root
......@@ -13,7 +12,7 @@ QQC2.ComboBox {
signal newDateChosen(int day, int month, int year)
property int timeZoneOffset: 0
property string display
property string display: dateTime.toLocaleString(Qt.locale(), Locale.NarrowFormat) // Can override for better C++ time strings
property date dateTime: new Date()
property date dateFromText: Date.fromLocaleDateString(Qt.locale(), editText, Locale.NarrowFormat)
property bool validDate: !isNaN(dateFromText.getTime())
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment