Internal makeover #35

Merged
dorian merged 1 commit from internal_makeover into master 2019-08-08 19:08:49 +02:00
4 changed files with 36 additions and 19 deletions

View file

@ -168,7 +168,7 @@ Popup {
fontSizeMode: Text.Fit
font.pixelSize: headlineUnderline.width * 0.1
minimumPixelSize: 0
minimumPixelSize: 1
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
@ -244,7 +244,7 @@ Popup {
onClicked: {
switch(profilesStack.currentItem.secondButt){
case "add":
profilesStack.push(addProfileComp)
profilesStack.createAthlete()
break
case "ok":
//speedBackend.createAthlete(fullNameTf.text, userNameTf.text)

View file

@ -53,22 +53,23 @@ StackView {
profilesStack.push(resComp)
}
function createAthlete() {
var createAthleteComp = addProfileComp.createObject(null, {})
profilesStack.push(createAthleteComp)
}
/*-----List of all profiles-----*/
Component {
id: profileListComp
ProfileListPage {
}
ProfileListPage {}
}
/*-----Option to add a profile-----*/
Component {
id: addProfileComp
AddProfilePage {
}
AddProfilePage {}
}
// --- Result View ---

View file

@ -57,8 +57,7 @@ RemoteDataListView {
backgroundRect.radius: 0
function getDateText(){
var date = new Date(listData[index]["timestamp"]*1000).toLocaleString(Qt.locale(), "dddd, dd.MMM HH:mm")
return date
return new Date(listData[index]["timestamp"]*1000).toLocaleString(Qt.locale(), "dddd, dd.MMM HH:mm")
}
Rectangle {

View file

@ -144,7 +144,7 @@ Window {
font.pixelSize: root.landscape() ? parent.width * 0.15 : parent.height * 0.4
minimumPixelSize: 0
minimumPixelSize: 1
Behavior on text {
FadeAnimation{
@ -194,7 +194,7 @@ Window {
font.pixelSize: root.landscape() ? parent.width * 0.15 : parent.height * 0.4
minimumPixelSize: 0
minimumPixelSize: 1
Behavior on text {
enabled: root.state !== "RUNNING"
@ -605,7 +605,7 @@ Window {
enabled: height > 0
height: speedBackend.baseStationState === "connected" ? root.landscape() ? menu_container.width * 0.7:menu_container.height * 0.7:0
state: speedBackend.baseStationState === "connected" ? "visible":"hidden"
width: height
onClicked: {
@ -616,15 +616,32 @@ Window {
backgroundColor: parent.pressed ? appTheme.style.buttonPressedColor:appTheme.style.buttonColor
Behavior on height {
states: [
State {
name: "hidden"
PropertyChanges {
target: profilesButt
height: 0
}
},
State {
name: "visible"
PropertyChanges {
target: profilesButt
height: root.landscape() ? menu_container.width * 0.7:menu_container.height * 0.7
}
}
]
transitions: [
Transition {
NumberAnimation {
duration: 200
properties: "height"
}
}
]
}
}
}
/*----------------------