Warning, /utilities/ktrip/src/qml/DatePickerButton.qml is written in an unsupported language. File is not indexed.

0001 /**
0002  * SPDX-FileCopyrightText: 2019 Nicolas Fella <nicolas.fella@gmx.de>
0003  *
0004  * SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0005  */
0006 
0007 import QtQuick 2.2
0008 import QtQuick.Layouts 1.1
0009 import QtQuick.Controls 2.5
0010 import org.kde.kirigami 2.4 as Kirigami
0011 
0012 import org.kde.kirigamiaddons.dateandtime 0.1 as KDT
0013 
0014 Button {
0015 
0016     signal datePicked(date theDate)
0017 
0018     onClicked: {
0019         if (_isAndroid) {
0020             _androidUtils.showDatePicker()
0021         } else {
0022             dialog.open()
0023         }
0024     }
0025 
0026      Connections {
0027         target: _androidUtils
0028         onDatePickerFinished: {
0029             datePicked(date)
0030         }
0031     }
0032 
0033     KDT.DatePopup {
0034         id: dialog
0035         onAccepted: datePicked(selectedDate)
0036     }
0037 }