summaryrefslogtreecommitdiffstats
path: root/src/core/type_conversion.h
diff options
context:
space:
mode:
authorPierre Rossi <pierre.rossi@digia.com>2014-09-18 18:21:28 +0200
committerPierre Rossi <pierre.rossi@gmail.com>2014-11-24 13:23:12 +0100
commita029fa2f6ef08bcad653f3d3e5a53ca8e3340b14 (patch)
tree446d7e2eee03aed3886246f11622bb7fc47b6b6b /src/core/type_conversion.h
parent66b2ca886063cfecaf000578492aa360581cab8a (diff)
Wire the geolocation API to QtPositioning
If QtPositioning is available, provide chromium with a LocationProvider that uses it as a backend. Change-Id: I53ad3b45e49d0d2d181c1a6459b7be764293c2a6 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
Diffstat (limited to 'src/core/type_conversion.h')
-rw-r--r--src/core/type_conversion.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/type_conversion.h b/src/core/type_conversion.h
index 9d9cdd675..be59c97b8 100644
--- a/src/core/type_conversion.h
+++ b/src/core/type_conversion.h
@@ -135,6 +135,10 @@ inline QDateTime toQt(base::Time time)
return QDateTime::fromMSecsSinceEpoch(time.ToJavaTime());
}
+inline base::Time toTime(const QDateTime &dateTime) {
+ return base::Time::FromInternalValue(dateTime.toMSecsSinceEpoch());
+}
+
inline base::FilePath::StringType toFilePathString(const QString &str)
{
#if defined(OS_WIN)