From 427416711c9445224fc39e9afea5c9f22f1d53a2 Mon Sep 17 00:00:00 2001 From: Jaquee Date: Wed, 23 Nov 2016 21:17:01 +0100 Subject: [PATCH 1/4] adjust appwindow min height to fit content --- main.qml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.qml b/main.qml index 5f28e415..0293b806 100644 --- a/main.qml +++ b/main.qml @@ -954,7 +954,7 @@ ApplicationWindow { } property int maxWidth: leftPanel.width + 655 + rightPanel.width - property int maxHeight: 700 + property int minHeight: 720 MouseArea { id: resizeArea hoverEnabled: true @@ -991,9 +991,9 @@ ApplicationWindow { appWindow.width -= dx else appWindow.width = parent.maxWidth - if(appWindow.height - dy > parent.maxHeight) + if(appWindow.height - dy > parent.minHeight) appWindow.height -= dy - else appWindow.height = parent.maxHeight + else appWindow.height = parent.minHeight previousPosition = pos } } From a0756ff64f0969e1b1fb88595e1e54ed36e92085 Mon Sep 17 00:00:00 2001 From: Jaquee Date: Wed, 23 Nov 2016 21:18:02 +0100 Subject: [PATCH 2/4] adjust menuButton height dynamically --- components/MenuButton.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/MenuButton.qml b/components/MenuButton.qml index 95790662..50238bd8 100644 --- a/components/MenuButton.qml +++ b/components/MenuButton.qml @@ -36,7 +36,7 @@ Rectangle { property alias symbol: symbolText.text signal clicked() - height: 64 + height: (appWindow.height >= 800) ? 64 : 60 color: checked ? "#FFFFFF" : "#1C1C1C" Item { From 3245d7d860ab050efc27638edabbb052b1c7d4fd Mon Sep 17 00:00:00 2001 From: Jaquee Date: Wed, 23 Nov 2016 21:19:19 +0100 Subject: [PATCH 3/4] redesign daemon progress bar to fit smaller screens --- components/DaemonProgress.qml | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/components/DaemonProgress.qml b/components/DaemonProgress.qml index 1ed533e3..dd6c24ac 100644 --- a/components/DaemonProgress.qml +++ b/components/DaemonProgress.qml @@ -26,13 +26,13 @@ // STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF // THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -import QtQuick 2.0 +import QtQuick 2.6 Item { id: item property int fillLevel: 0 - height: 44 - anchors.margins: 10 + height: 22 + anchors.margins:15 visible: false //clip: true @@ -56,7 +56,7 @@ Item { anchors.left: parent.left anchors.right: parent.right anchors.top: parent.top - height: 18 + height: 22 //radius: 4 color: "#FFFFFF" @@ -66,25 +66,28 @@ Item { anchors.bottom: parent.bottom anchors.left: parent.left anchors.margins: 2 + height: bar.height property int maxWidth: parent.width - 4 width: (maxWidth * fillLevel) / 100 - color: { - if(item.fillLevel < 99) return "#FF6C3C" + if(item.fillLevel < 99 ) return "#FF6C3C" //if(item.fillLevel < 99) return "#FFE00A" return "#36B25C" } } - } - Text { - id:progressText - anchors.bottom: parent.bottom - font.family: "Arial" - font.pixelSize: 12 - color: "#545454" - text: qsTr("Synchronizing blocks") + Text { + id:progressText + anchors.bottom: parent.bottom + font.family: "Arial" + font.pixelSize: 12 + leftPadding: 8 + color: "#000" + height: 18 + verticalAlignment: Text.alignVCenter + text: qsTr("Synchronizing blocks") + } } } From eef11bf22a2cd40a9fd4288c48e62bd214cb8fef Mon Sep 17 00:00:00 2001 From: Jaquee Date: Fri, 25 Nov 2016 20:58:27 +0100 Subject: [PATCH 4/4] remove qtquick 2.6 dependency --- components/DaemonProgress.qml | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/components/DaemonProgress.qml b/components/DaemonProgress.qml index dd6c24ac..5fac2079 100644 --- a/components/DaemonProgress.qml +++ b/components/DaemonProgress.qml @@ -26,7 +26,7 @@ // STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF // THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -import QtQuick 2.6 +import QtQuick 2.0 Item { id: item @@ -42,7 +42,6 @@ Item { fillLevel = progressLevel console.log("target block: ",progressLevel) progressText.text = qsTr("Synchronizing blocks %1/%2").arg(currentBlock.toFixed(0)).arg(targetBlock.toFixed(0)); - console.log("Progress text: " + progressText.text); // TODO: lower daemon block height cache, ttl and refresh interval? @@ -57,7 +56,7 @@ Item { anchors.right: parent.right anchors.top: parent.top height: 22 - //radius: 4 + radius: 2 color: "#FFFFFF" Rectangle { @@ -77,16 +76,21 @@ Item { } - Text { - id:progressText + Rectangle { + color:"#333" anchors.bottom: parent.bottom - font.family: "Arial" - font.pixelSize: 12 - leftPadding: 8 - color: "#000" - height: 18 - verticalAlignment: Text.alignVCenter - text: qsTr("Synchronizing blocks") + anchors.left: parent.left + anchors.leftMargin: 8 + + Text { + id:progressText + anchors.bottom: parent.bottom + font.family: "Arial" + font.pixelSize: 12 + color: "#000" + text: qsTr("Synchronizing blocks") + height:18 + } } }