diff --git a/images/images.qrc b/images/images.qrc
index e52e24be0e..b4fa28d63a 100644
--- a/images/images.qrc
+++ b/images/images.qrc
@@ -172,6 +172,16 @@
themes/qfield/xhdpi/ic_settings_white_24dp.png
themes/qfield/xxhdpi/ic_settings_white_24dp.png
themes/qfield/xxxhdpi/ic_settings_white_24dp.png
+ themes/qfield/hdpi/ic_topology_green_24dp.png
+ themes/qfield/mdpi/ic_topology_green_24dp.png
+ themes/qfield/xhdpi/ic_topology_green_24dp.png
+ themes/qfield/xxhdpi/ic_topology_green_24dp.png
+ themes/qfield/xxxhdpi/ic_topology_green_24dp.png
+ themes/qfield/hdpi/ic_topology_white_24dp.png
+ themes/qfield/mdpi/ic_topology_white_24dp.png
+ themes/qfield/xhdpi/ic_topology_white_24dp.png
+ themes/qfield/xxhdpi/ic_topology_white_24dp.png
+ themes/qfield/xxxhdpi/ic_topology_white_24dp.png
themes/qfield/hdpi/ic_clear_black_18dp.png
themes/qfield/mdpi/ic_clear_black_18dp.png
themes/qfield/xhdpi/ic_clear_black_18dp.png
diff --git a/images/themes/qfield/hdpi/ic_topology_green_24dp.png b/images/themes/qfield/hdpi/ic_topology_green_24dp.png
new file mode 100644
index 0000000000..afcf0308e7
Binary files /dev/null and b/images/themes/qfield/hdpi/ic_topology_green_24dp.png differ
diff --git a/images/themes/qfield/hdpi/ic_topology_white_24dp.png b/images/themes/qfield/hdpi/ic_topology_white_24dp.png
new file mode 100644
index 0000000000..165a17474b
Binary files /dev/null and b/images/themes/qfield/hdpi/ic_topology_white_24dp.png differ
diff --git a/images/themes/qfield/mdpi/ic_topology_green_24dp.png b/images/themes/qfield/mdpi/ic_topology_green_24dp.png
new file mode 100644
index 0000000000..2b092a879e
Binary files /dev/null and b/images/themes/qfield/mdpi/ic_topology_green_24dp.png differ
diff --git a/images/themes/qfield/mdpi/ic_topology_white_24dp.png b/images/themes/qfield/mdpi/ic_topology_white_24dp.png
new file mode 100644
index 0000000000..165a17474b
Binary files /dev/null and b/images/themes/qfield/mdpi/ic_topology_white_24dp.png differ
diff --git a/images/themes/qfield/xhdpi/ic_topology_green_24dp.png b/images/themes/qfield/xhdpi/ic_topology_green_24dp.png
new file mode 100644
index 0000000000..c9a8183d0f
Binary files /dev/null and b/images/themes/qfield/xhdpi/ic_topology_green_24dp.png differ
diff --git a/images/themes/qfield/xhdpi/ic_topology_white_24dp.png b/images/themes/qfield/xhdpi/ic_topology_white_24dp.png
new file mode 100644
index 0000000000..c98038b058
Binary files /dev/null and b/images/themes/qfield/xhdpi/ic_topology_white_24dp.png differ
diff --git a/images/themes/qfield/xxhdpi/ic_topology_green_24dp.png b/images/themes/qfield/xxhdpi/ic_topology_green_24dp.png
new file mode 100644
index 0000000000..ed5bede096
Binary files /dev/null and b/images/themes/qfield/xxhdpi/ic_topology_green_24dp.png differ
diff --git a/images/themes/qfield/xxhdpi/ic_topology_white_24dp.png b/images/themes/qfield/xxhdpi/ic_topology_white_24dp.png
new file mode 100644
index 0000000000..17266c9f21
Binary files /dev/null and b/images/themes/qfield/xxhdpi/ic_topology_white_24dp.png differ
diff --git a/images/themes/qfield/xxxhdpi/ic_topology_green_24dp.png b/images/themes/qfield/xxxhdpi/ic_topology_green_24dp.png
new file mode 100644
index 0000000000..3cae9cd759
Binary files /dev/null and b/images/themes/qfield/xxxhdpi/ic_topology_green_24dp.png differ
diff --git a/images/themes/qfield/xxxhdpi/ic_topology_white_24dp.png b/images/themes/qfield/xxxhdpi/ic_topology_white_24dp.png
new file mode 100644
index 0000000000..5c19542e32
Binary files /dev/null and b/images/themes/qfield/xxxhdpi/ic_topology_white_24dp.png differ
diff --git a/sdk.conf b/sdk.conf
index eca64b96fb..3d1e86da20 100644
--- a/sdk.conf
+++ b/sdk.conf
@@ -1 +1 @@
-osgeo4a_version=20200318
+osgeo4a_version=20200416
diff --git a/src/qml/qgismobileapp.qml b/src/qml/qgismobileapp.qml
index 9af64724b3..a9166b80d1 100644
--- a/src/qml/qgismobileapp.qml
+++ b/src/qml/qgismobileapp.qml
@@ -509,7 +509,51 @@ ApplicationWindow {
}
Column {
- id: mainToolBar
+ id: mainToolbar
+ anchors.left: mainMenuBar.left
+ anchors.top: mainMenuBar.bottom
+ anchors.leftMargin: 4 * dp
+ spacing: 4 * dp
+
+ Button {
+ id: topologyButton
+ round: true
+ visible: stateMachine.state === "digitize" && ( dashBoard.currentLayer.geometryType() === QgsWkbTypes.PolygonGeometry || dashBoard.currentLayer.geometryType() === QgsWkbTypes.LineGeometry )
+ state: qgisProject.topologicalEditing ? "On" : "Off"
+ iconSource: Theme.getThemeIcon( "ic_topology_white_24dp" )
+
+ bgcolor: Theme.darkGray
+
+ states: [
+ State {
+
+ name: "Off"
+ PropertyChanges {
+ target: topologyButton
+ iconSource: Theme.getThemeIcon( "ic_topology_white_24dp" )
+ bgcolor: "#88212121"
+ }
+ },
+
+ State {
+ name: "On"
+ PropertyChanges {
+ target: topologyButton
+ iconSource: Theme.getThemeIcon( "ic_topology_green_24dp" )
+ bgcolor: Theme.darkGray
+ }
+ }
+ ]
+
+ onClicked: {
+ qgisProject.topologicalEditing = !qgisProject.topologicalEditing;
+ displayToast( qgisProject.topologicalEditing ? qsTr( "Topological editing turned on" ) : qsTr( "Topological editing turned off" ) );
+ }
+ }
+ }
+
+ Column {
+ id: locationToolbar
anchors.right: mapCanvas.right
anchors.rightMargin: 4 * dp
anchors.bottom: mapCanvas.bottom
@@ -1365,7 +1409,7 @@ ApplicationWindow {
toast.open()
toastContent.visible = true
toast.opacity = 1
- toastTimer.start()
+ toastTimer.restart()
}
Behavior on opacity {