Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/ui redesign #31

Open
wants to merge 26 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
d857a09
Feature(Map): Changes to Map Element
Sefriol Aug 20, 2020
e16b3f8
main.qml: Add Notifications
Sefriol Aug 27, 2020
5e58b72
main.qml: Add global locationParameters
Sefriol Aug 27, 2020
5af32ca
Feature: New Mainpage
Sefriol Aug 27, 2020
5b65450
Mainpage: Use Favorites and RecentItems.
Sefriol Aug 30, 2020
d287693
Mainpage: remove reverse favorite route button
Sefriol Aug 30, 2020
e5e75e9
Remove infobanner (use notification)
Sefriol Aug 30, 2020
56c7b70
Separate RoutePlanner from MainPage
Sefriol Aug 31, 2020
4267481
Use ExpandingBottomDrawer for FavoriteRoutes
Sefriol Sep 1, 2020
9b89fb0
MapDialog: clear model when selected coord changes
Sefriol Sep 2, 2020
7976db1
Add model to SuggestionDelegate
Sefriol Sep 2, 2020
d0be447
Add Stop times back to StopPage
Sefriol Sep 5, 2020
2b37e52
Add more helper functions
Sefriol Sep 6, 2020
a01a973
Change Database interactions
Sefriol Sep 6, 2020
78f720a
Improve some database functions and fix bugs
Sefriol Sep 7, 2020
b054ce3
Add clips for SilicalistViews in FavRecItemSelect
Sefriol Sep 7, 2020
451a038
Reittiopas.js: Use Pattern instead of ServiceDate
Sefriol Sep 7, 2020
12bcd4a
Move most of the common variables to main.qml
Sefriol Sep 12, 2020
737b857
Improve Legs processing
Sefriol Sep 13, 2020
ba6a207
CoverPage: Complete Redesign
Sefriol Sep 13, 2020
a992555
RoutePlanner: Add Press&Hold for all ContextMenus
Sefriol Sep 13, 2020
05babee
FavoritesPage: Rename vars based on model changes
Sefriol Sep 13, 2020
38349d1
ResultPage: Add header update function
Sefriol Sep 13, 2020
2e991bb
Remove some aspect related to old UI
Sefriol Sep 13, 2020
55fda09
Favorites: Minor UI Layout tweaks
Sefriol Sep 13, 2020
e32b1b3
Mainpage: Add Drawer optimizations
Sefriol Sep 14, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions harbour-jollaopas.pro
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ lupdate_only{
SOURCES += \
qml/pages/*.qml \
qml/components/*.qml \
qml/pages/AboutDialog.qml.in \
qml/pages/dialogs/About.qml.in\
qml/main.qml

TRANSLATIONS += \
Expand Down Expand Up @@ -103,6 +103,6 @@ INCLUDEPATH += \

include(version.pri)
include(common.pri)
configure($${PWD}/qml/pages/AboutDialog.qml.in)
configure($${PWD}/qml/pages/dialogs/About.qml.in)

desktop.files = harbour-jollaopas.desktop
145 changes: 145 additions & 0 deletions qml/components/ExpandingBottomDrawer.qml
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
/****************************************************************************************
**
** Copyright (C) 2013 Jolla Ltd.
** Contact: Andrew den Exter <[email protected]>
** All rights reserved.
**
** This file is part of Sailfish Silica UI component package.
**
** You may use this file under the terms of BSD license as follows:
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the Jolla Ltd nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR
** ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 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.1
import Sailfish.Silica 1.0

Item {
id: root

property bool open
property bool opened: open || menuProgressAnimation.running

property real backgroundSize: open ? height / 2 : startPoint

property alias backgroundItem: backgroundItem
property alias background: backgroundItem.children

property alias foregroundItem: foregroundItem
property alias foreground: foregroundItem.children

default property alias data: foregroundItem.data

property bool hideOnMinimize: false
property bool hideEvent: !Qt.application.active && hideOnMinimize
property alias custHeight: root.height
property double startPoint
onHideEventChanged: {
if (hideEvent) {
open = false
_completeAnimations()
}
}
Behavior on backgroundSize {
NumberAnimation {
id: menuProgressAnimation
duration: 200
easing.type: Easing.InOutQuad
}
}
function _completeAnimations() {
menuProgressAnimation.complete()
backgroundOpacityAnimation.complete()
}

function show(immediate) {
open = true
if (immediate) {
_completeAnimations()
}
}

function hide(immediate) {
open = false
if (immediate) {
_completeAnimations()
}
}

Item {
id: backgroundClip
clip: true
anchors {
left: root.left
top: foregroundItem.bottom
right: root.right
bottom: root.bottom
}
Rectangle {
gradient: Gradient {
GradientStop { position: 0.0; color: Qt.rgba (0, 0, 0, 0); }
GradientStop { position: 1.0; color: Theme.highlightDimmerColor; }
}
anchors.fill: backgroundClip;

}
Item {
id: backgroundItem
x: 0
width: root.width
height: root.backgroundSize
}
}

Rectangle {
id: dimmerRect
anchors.fill: foregroundItem
color: Theme.highlightDimmerColor
z:1000
// The dimmed rectangle provides a seam between the background and foreground. It shouldn't
// pop in instantly but should be distinct for the majority of the animation so the animation
// easing is cubic instead of the normal quad.
opacity: root.open ? 0.5 : 0.0
Behavior on opacity {
NumberAnimation {
id: backgroundOpacityAnimation
duration: 200
easing.type: Easing.InOutCubic
}
}
}

Item {
id: foregroundItem
clip: true

anchors {
fill: parent
leftMargin: 0
topMargin: 0
rightMargin: 0
bottomMargin: root.backgroundSize
}
}
}
2 changes: 1 addition & 1 deletion qml/components/FavoritesDelegate.qml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ ListItem {
anchors.verticalCenter: parent.verticalCenter
anchors.left: icon.right
anchors.right: parent.right
text: modelData
text: name
font.pixelSize: Theme.fontSizeMedium
}
}
4 changes: 4 additions & 0 deletions qml/components/FlickableMap.qml
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,10 @@ Map {
map.center = QtPositioning.coordinate(latitude, longitude)
}

function screenToCoordinate(x,y) {
return map.toCoordinate(Qt.point(x,y))
}

MapQuickItem {
width: 70 // width of MapButton
anchors.left: parent.left
Expand Down
Loading