import QtQuick 2.6
import Esri.ArcGISRuntime 100.0
import Esri.ArcGISExtras 1.1
Rectangle {
width: 800
height: 600
property real scaleFactor: System.displayScaleFactor
// property string dataPath: System.userHomePath + "/ArcGIS/Runtime/Data/mmpk/"
[B][I]property string dataPath: "file:///storage/sdcard1/"[/I][/B]
// Create MapView
MapView {
id: mapView
anchors.fill: parent
}
// Create a Mobile Map Package and set the path
MobileMapPackage {
id: mmpk
path: dataPath + "Yellowstone.mmpk"
// load the mobile map package
Component.onCompleted: {
mmpk.load();
}
// wait for the mobile map package to load
onLoadStatusChanged: {
if (loadStatus === Enums.LoadStatusLoaded) {
// set the map view's map to the first map in the mobile map package
mapView.map = mmpk.maps[0];
}
}
}
Rectangle {
anchors.fill: parent
color: "transparent"
border {
width: 0.5 * scaleFactor
color: "black"
}
}
}