From e2ea66cdd3f3d413066e3b7c83b50dfc7fa1e488 Mon Sep 17 00:00:00 2001 From: Anatasof Wirapraja Date: Tue, 3 Sep 2019 14:39:40 +0700 Subject: add Drawer --- main.qml | 7 ++++++- pages/Home.qml | 6 ++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/main.qml b/main.qml index d8a888d..b432dd5 100644 --- a/main.qml +++ b/main.qml @@ -11,11 +11,16 @@ ApplicationWindow { Material.accent: Material.DeepPurple + Drawer { + id: drawer + width: 0.8 * appWindow.width + height: appWindow.height + } + StackView { id: stackView anchors.fill : parent initialItem: Login {} } - } diff --git a/pages/Home.qml b/pages/Home.qml index 1cce621..7116a43 100644 --- a/pages/Home.qml +++ b/pages/Home.qml @@ -4,4 +4,10 @@ import id.co.darapsa.kelakon.user 0.1 HomeForm { width: stackView.width height: stackView.height + + menuButton { + onClicked: { + drawer.visible = !drawer.visible + } + } } -- cgit v1.2.3