This repository has been archived by the owner on Jul 22, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Starting from clean slate for the UI (#23)
1. **Explanation**: - Refreshed UI using the Model-View-Delegate approach from Qt. 2. **Fixed issues**: - Fixed #22 - Fixed #24 - Fixed #12 - Fixed #13 3. **Testing environment**: - Sailfish OS version: 2.1.0.11 - Sailfish OS hardware: Oneplus X
- Loading branch information
1 parent
b460eee
commit 4915c6f
Showing
106 changed files
with
6,755 additions
and
3,029 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,3 +37,6 @@ Makefile* | |
# QtCtreator CMake | ||
CMakeLists.txt.user* | ||
|
||
#Enforce .pro.user ignore | ||
harbour-berail.pro.user | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
/* | ||
* This file is part of BeRail. | ||
* | ||
* BeRail is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* BeRail is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with BeRail. If not, see <http://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
import QtQuick 2.0 | ||
import Sailfish.Silica 1.0 | ||
|
||
ListItem { | ||
contentHeight: column.height*1.1 | ||
|
||
Column { | ||
id: column | ||
width: parent.width | ||
anchors.centerIn: parent | ||
spacing: Theme.paddingSmall | ||
|
||
SectionHeader { | ||
text: model.title.split(":")[1].split(".")[0] // Remove "." from the end | ||
} | ||
|
||
TextLabel { | ||
text: model.text | ||
} | ||
|
||
Item { | ||
width: parent.width | ||
height: Theme.itemSizeSmall | ||
|
||
Label { | ||
width: parent.width - iconLocation.width | ||
anchors { right: iconLocation.left; rightMargin: Theme.paddingSmall; verticalCenter: parent.verticalCenter } | ||
horizontalAlignment: Text.AlignRight | ||
font.pixelSize: Theme.fontSizeSmall | ||
truncationMode: TruncationMode.Fade | ||
color: Theme.secondaryColor | ||
text: model.title.split(":")[0] | ||
} | ||
|
||
Image { | ||
id: iconLocation | ||
anchors { right: parent.right; rightMargin: Theme.horizontalPageMargin; verticalCenter: parent.verticalCenter } | ||
source: "image://theme/icon-m-location" | ||
} | ||
} | ||
|
||
Item { | ||
width: parent.width | ||
height: Theme.itemSizeSmall | ||
|
||
Label { | ||
width: parent.width - iconDate.width | ||
anchors { right: iconDate.left; rightMargin: Theme.paddingSmall; verticalCenter: parent.verticalCenter } | ||
horizontalAlignment: Text.AlignRight | ||
font.pixelSize: Theme.fontSizeSmall | ||
truncationMode: TruncationMode.Fade | ||
color: Theme.secondaryColor | ||
text: model.timestamp.toLocaleString(Qt.locale(), "dd MMM yyyy hh:mm"); | ||
} | ||
|
||
Image { | ||
id: iconDate | ||
anchors { right: parent.right; rightMargin: Theme.horizontalPageMargin; verticalCenter: parent.verticalCenter } | ||
source: "image://theme/icon-m-time-date" | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import QtQuick 2.0 | ||
import Sailfish.Silica 1.0 | ||
|
||
Item { | ||
width: parent.width | ||
height: parent.height | ||
|
||
Rectangle { | ||
anchors { fill: parent } | ||
opacity: 0.75 | ||
gradient: Gradient { | ||
GradientStop { position: 0.0; color: Theme.highlightBackgroundColor } | ||
GradientStop { position: 0.33; color: Theme.highlightDimmerColor } | ||
GradientStop { position: 0.66; color: Theme.highlightDimmerColor } | ||
GradientStop { position: 1.0; color: Theme.highlightBackgroundColor } | ||
} | ||
} | ||
|
||
Label { | ||
anchors { centerIn: parent } | ||
//% "Canceled" | ||
text: qsTrId("berail-canceled") + " :-(" | ||
color: Theme.primaryColor | ||
font.bold: true | ||
font.capitalization: Font.AllUppercase | ||
font.pixelSize: Theme.fontSizeLarge | ||
} | ||
} |
Oops, something went wrong.