Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
5.8.0, 5.9.4, 5.10.1
-
None
-
2b8b7a162be52f8cd6c2bc39f498a1ddfb59dd68
Description
Is there a reason QTime::currentTime() does not convert when handed to QML... like QDate and QDateTime do?
engine.rootContext()->setContextProperty("currentDate", QDate::currentDate()); // Can be accessed in QML as "currentDate"
engine.rootContext()->setContextProperty("currentDateTime", QDateTime::currentDateTime()); // Can be accessed in QML as "currentDateTime"
engine.rootContext()->setContextProperty("currentTime", QTime::currentTime()); // "currentTime" in QML is empty, needs to be QTime::currentTime().toString()
Attachments
Issue Links
- relates to
-
QTBUG-56787 V4's Date constructor fails to take account of variations in time-zone offset
- Closed