On 02/02/2016 03:59, Dirk Hohndel wrote:
Whitespace :-(
I really can't tell easily what you changed.
It's usually a good idea to take a look at your patch before you send it
and ask yourself... "are these the changes that I made, or is something
else going on"?

/D

Apologies. it was a confusion of versions after messing up with vim during a commit.

Subject: [PATCH 3/3] [PATCH] Mobile. Update downloadfromdivecomputer screen.

1) Insert spacer to make space for silly button at screen bottom.
2) Adjust column widths of table of downloaded dives.
3) Simplification and general cleanup of QML code for this page.

Signed-off-by: Willem Ferguson<[email protected]>

I attach a screenshot of what it looks like on my computer.
Kind regards,
willem

>From 59edf9b64d2f76bde526b68bae4f801eb593c75d Mon Sep 17 00:00:00 2001
From: Willem Ferguson <[email protected]>
Date: Tue, 2 Feb 2016 07:32:43 +0200
Subject: [PATCH 3/3] [PATCH] Mobile. Update downloadfromdivecomputer screen.

1) Insert spacer to make space for silly button.
2) Adjust column widths of table.
3) General cleanup and simplification of QML code for this page.

Signed-off-by: Willem Ferguson <[email protected]>
---
 qt-mobile/qml/DownloadFromDiveComputer.qml | 145 ++++++++++++++++-------------
 1 file changed, 81 insertions(+), 64 deletions(-)

diff --git a/qt-mobile/qml/DownloadFromDiveComputer.qml b/qt-mobile/qml/DownloadFromDiveComputer.qml
index a401d57..300ef66 100644
--- a/qt-mobile/qml/DownloadFromDiveComputer.qml
+++ b/qt-mobile/qml/DownloadFromDiveComputer.qml
@@ -1,5 +1,6 @@
 import QtQuick 2.3
 import QtQuick.Controls 1.2
+import QtQuick.Controls.Styles 1.2
 import QtQuick.Window 2.2
 import QtQuick.Dialogs 1.2
 import QtQuick.Layouts 1.1
@@ -7,91 +8,107 @@ import org.subsurfacedivelog.mobile 1.0
 
 Item {
 	id: diveComputerDownloadWindow
-	anchors.top: parent.top
+	anchors.top:parent.top
 	width: parent.width
 	height: parent.height
+	Layout.fillWidth: true;
 
-	GridLayout {
-		columns: 2
+	ColumnLayout {
 		anchors.top: parent.top
-		width: parent.width
 		height: parent.height
+		width: parent.width
+		Layout.fillWidth: true
+		RowLayout {
+			anchors.top:parent.top
+			Layout.fillWidth: true
+			Text { text: " Vendor name : " }
+			ComboBox { Layout.fillWidth: true }
+		}
+		RowLayout {
+			Text { text: " Dive Computer:" }
+			ComboBox { Layout.fillWidth: true }
+		}
+		RowLayout {
+			Text { text: " Progress:" }
+			Layout.fillWidth: true
+			ProgressBar { Layout.fillWidth: true }
+		}
+		RowLayout {
+			SubsurfaceButton {
+				text: "Download"
+				onClicked: {
+					text: "Retry"
+					stackView.pop();
+				}
+			}
+			SubsurfaceButton {
+				id:quitbutton
+				text: "Quit"
+				onClicked: {
+					stackView.pop();
+				}
+			}
+		}
+		RowLayout {
+			Text {
+				text: " Downloaded dives"
+			}
+		}
 		ColumnLayout {
-			height: parent.height
 			width: parent.width
-			ColumnLayout {
-				width: parent.width
-				Layout.fillHeight: true
-				ColumnLayout {
-					Layout.fillHeight: true
-					Layout.fillWidth: true
-					ColumnLayout {
-						height: parent.height
-						Layout.fillWidth: true
-						Text { text: "Vendor" }
-						ComboBox { Layout.fillWidth: true }
-						Text { text: "Dive Computer" }
-						ComboBox { Layout.fillWidth: true }
-						Text { text: "Device or mount point" }
-						RowLayout {
-							Layout.fillWidth: true
-							TextField { Layout.fillWidth: true }
-							SubsurfaceButton { text: "..." }
-						}
-						GridLayout {
-							columns: 2
-							CheckBox { text: "Force download of all dives" }
-							CheckBox { text: "Always prefer downloaded dives" }
-							CheckBox { text: "Download into new trip" }
-							CheckBox { text: "Save libdivecomputer logfile" }
-							CheckBox { text: "Save libdivecomputer dumpfile" }
-							CheckBox { text: "Choose Bluetooth download mode" }
-						}
-
-						RowLayout {
-							Layout.fillWidth: true
-							ProgressBar { Layout.fillWidth: true }
-							SubsurfaceButton { text: "Download" }
-						}
-					}
+			Layout.fillWidth: true
+			TableView {
+				Layout.fillWidth: true  // The table should take up
+				Layout.fillHeight: true // all available vertical space
+				height: parent.height
+				TableViewColumn {
+					width: parent.width / 2
+					role: "datetime"
+					title: "Date / Time"
 				}
-				ColumnLayout {
-					height: parent.height
-					Layout.fillWidth: true
-					RowLayout {
-						Text {
-							text: "Downloaded dives"
-						}
-						SubsurfaceButton {
-							text: "Select All"
-						}
-						SubsurfaceButton {
-							text: "Unselect All"
-						}
-					}
-					TableView {
-						Layout.fillWidth: true
-						Layout.fillHeight: true
-					}
+				TableViewColumn {
+					width: parent.width / 4
+					role: "duration"
+					title: "Duration"
+				}
+				TableViewColumn {
+					width: parent.width / 4
+					role: "depth"
+					title: "Depth"
 				}
 			}
 			RowLayout {
-				width: parent.width
+				Layout.fillWidth: true
 				SubsurfaceButton {
-					text: "OK"
-
+					text: "Accept"
 					onClicked: {
 						stackView.pop();
 					}
 				}
 				SubsurfaceButton {
-					text: "Cancel"
-
+					text: "Quit"
 					onClicked: {
 						stackView.pop();
 					}
 				}
+				Text {
+					text: ""  // Spacer between 2 button groups
+					Layout.fillWidth: true
+				}
+				SubsurfaceButton {
+					text: "Select All"
+				}
+				SubsurfaceButton {
+					id: unselectbutton
+					text: "Unselect All"
+				}
 			}
-		}
+			RowLayout { // spacer to make space for silly button
+				Layout.minimumHeight: 1.2 * unselectbutton.height
+				Text {
+					text:""
+				}
+			}
+		} // columnlayout
 	}
 }
-- 
2.5.0

_______________________________________________
subsurface mailing list
[email protected]
http://lists.subsurface-divelog.org/cgi-bin/mailman/listinfo/subsurface

Reply via email to