UI improvements

This commit is contained in:
molan-git 2020-07-06 10:28:42 +02:00
parent 95f065fd5b
commit bc8bcf39e5
21 changed files with 93 additions and 152 deletions

View file

@ -16,7 +16,7 @@ Page {
property string status_id: ""
property string status_url: ""
property string status_uri: ""
property int tootMaxChar: 500;
property int tootMaxChar: 500
property bool bot: false //otherwise ReferenceError ProfileHeader.qml
property bool followed_by: false //otherwise ReferenceError ProfileHeader.qml
property bool locked: false //otherwise ReferenceError ProfileHeader.qml
@ -60,6 +60,7 @@ Page {
SilicaListView {
id: myList
header: PageHeader {
title: headerTitle // pageTitle pushed from MainPage.qml or VisualContainer.qml
}

View file

@ -85,7 +85,7 @@ Page {
height: parent.itemHeight
onSearchChanged: {
console.log(search)
loader.sourceComponent = loading
//loader.sourceComponent = loading
if (search.charAt(0) === "@") {
loader.sourceComponent = userListComponent
} else if (search.charAt(0) === "#") {
@ -119,14 +119,14 @@ Page {
}
}
Component {
id: loading
BusyIndicator {
size: BusyIndicatorSize.Large
anchors.centerIn: parent
running: true
}
}
// Component {
// id: loading
// BusyIndicator {
// size: BusyIndicatorSize.Large
// anchors.centerIn: parent
// running: true
// }
// }
Component {
id: tagListComponent

View file

@ -41,22 +41,16 @@ SilicaListView {
description: myList.description
}
BusyIndicator {
size: BusyIndicatorSize.Large
running: myList.model.count === 0 && !viewPlaceHolder.visible
anchors.centerIn: parent
BusyLabel {
id: loadStatusList
running: model.count === 0
anchors {
horizontalCenter: parent.horizontalCenter
verticalCenter: parent.verticalCenter
}
ViewPlaceholder {
id: viewPlaceHolder
enabled: model.count === 0
text: qsTr("Loading")
hintText: qsTr("please wait...")
anchors.centerIn: parent
}
PullDownMenu {
MenuItem {
text: qsTr("Settings")
visible: !profilePage
@ -124,10 +118,13 @@ SilicaListView {
}
BusyIndicator {
running: loadStarted
visible: loadStatusList.running ? false : true
size: BusyIndicatorSize.Small
running: loadStarted;
anchors.verticalCenter: parent.verticalCenter
anchors.horizontalCenter: parent.horizontalCenter
anchors {
verticalCenter: parent.verticalCenter
horizontalCenter: parent.horizontalCenter
}
}
}
@ -171,10 +168,10 @@ SilicaListView {
function loadData(mode) {
var p = []
if (params.length)
if (params.length) {
for(var i = 0; i<params.length; i++)
p.push(params[i])
}
if (mode === "append" && model.count) {
p.push({name: 'max_id', data: model.get(model.count-1).id})
}

View file

@ -16,10 +16,10 @@ Item {
Rectangle {
id: bgImage
opacity: 0.2
opacity: 0.7
gradient: Gradient {
GradientStop { position: 0.0; color: Theme.highlightBackgroundColor }
GradientStop { position: 1.0; color: Theme.highlightBackgroundColor }
GradientStop { position: 0.0; color: Theme.highlightDimmerColor }
GradientStop { position: 2.0; color: Theme.highlightBackgroundColor }
}
anchors.fill: parent
@ -27,6 +27,7 @@ Item {
asynchronous: true
fillMode: Image.PreserveAspectCrop
source: bg
opacity: 0.6
anchors.fill: parent
}
}

View file

@ -16,12 +16,12 @@ FullscreenContentPage {
IconButton {
icon.source: "image://theme/icon-m-dismiss"
onClicked: pageStack.pop()
anchors {
top: profileImage.top
topMargin: Theme.horizontalPageMargin
right: parent.right
rightMargin: Theme.horizontalPageMargin
}
onClicked: pageStack.pop()
}
}

View file

@ -18,7 +18,7 @@ BackgroundItem {
id: bgDirect
x: 0
y: 0
visible: status_visibility === "direct"
visible: model.status_visibility === "direct"
width: parent.width
height: parent.height
opacity: 0.3
@ -188,7 +188,7 @@ BackgroundItem {
left: miniHeader.left
leftMargin: Theme.paddingMedium
right: miniHeader.right
rightMargin: Theme.horizontalPageMargin
rightMargin: Theme.horizontalPageMargin + Theme.paddingLarge
top: miniHeader.bottom
topMargin: Theme.paddingSmall
bottomMargin: Theme.paddingLarge
@ -255,16 +255,14 @@ BackgroundItem {
// Displays media in Toots
MediaBlock {
id: media
visible: if (myList.type === "notifications" && ( type === "favourite" || type === "reblog" )) {
false
} else true
visible: (myList.type === "notifications" && ( type === "favourite" || type === "reblog" )) ? false : true
model: typeof attachments !== "undefined" ? attachments : Qt.createQmlObject('import QtQuick 2.0; ListModel { }', Qt.application, 'InternalQmlObject')
height: Theme.iconSizeExtraLarge * 2
anchors {
left: lblContent.left
leftMargin: isPortrait ? 0 : Theme.itemSizeSmall
right: lblContent.right
rightMargin: isPortrait ? 0 : Theme.itemSizeLarge * 1.4
rightMargin: isPortrait ? 0 : Theme.itemSizeLarge * 1.2
top: lblContent.bottom
topMargin: Theme.paddingMedium
bottomMargin: Theme.paddingLarge
@ -278,7 +276,7 @@ BackgroundItem {
MenuItem {
id: mnuBoost
visible: model.type !== "follow"
enabled: status_visibility !== "direct"
enabled: model.status_visibility !== "direct"
text: typeof model.status_reblogged !== "undefined" && model.status_reblogged ? qsTr("Unboost") : qsTr("Boost")
onClicked: {
var status = typeof model.status_reblogged !== "undefined" && model.status_reblogged

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Einstellungen</translation>
</message>
<message>
<source>Loading</source>
<translation>Wird geladen</translation>
</message>
<message>
<source>please wait...</source>
<translation>bitte warten...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Neuer Toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation>Im Browser öffnen</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Ρυθμίσεις</translation>
</message>
<message>
<source>Loading</source>
<translation>Φόρτωση</translation>
</message>
<message>
<source>please wait...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>New Toot</source>
<translation>Νέος</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Ajustes</translation>
</message>
<message>
<source>Loading</source>
<translation>Cargando</translation>
</message>
<message>
<source>please wait...</source>
<translation>por favor, espera...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nuevo toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished">Abrir en el navegador</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Paramètres</translation>
</message>
<message>
<source>Loading</source>
<translation>Chargement</translation>
</message>
<message>
<source>please wait...</source>
<translation>patientez...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nouveau pouet</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation>Ouvrir dans le navigateur</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Impostazioni</translation>
</message>
<message>
<source>Loading</source>
<translation>Caricamento</translation>
</message>
<message>
<source>please wait...</source>
<translation>Attendere un momento...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nuovo Toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation>Aprire nel browser</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Instellingen</translation>
</message>
<message>
<source>Loading</source>
<translation>Laden</translation>
</message>
<message>
<source>please wait...</source>
<translation>even geduld</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nieuwe Toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished">Open een Browser</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Instellingen</translation>
</message>
<message>
<source>Loading</source>
<translation>Laden</translation>
</message>
<message>
<source>please wait...</source>
<translation>efkens geduld</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nieuwen toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Parmètres</translation>
</message>
<message>
<source>Loading</source>
<translation>Cargament</translation>
</message>
<message>
<source>please wait...</source>
<translation>esperatz....</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nòu Tut</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Ustawienia</translation>
</message>
<message>
<source>Loading</source>
<translation>Ładowanie</translation>
</message>
<message>
<source>please wait...</source>
<translation>proszę czekać</translation>
</message>
<message>
<source>New Toot</source>
<translation>Nowy wpis</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Настройки</translation>
</message>
<message>
<source>Loading</source>
<translation>Загрузка</translation>
</message>
<message>
<source>please wait...</source>
<translation>Пожалуйста, подождите...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Новый</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished">Открыть в браузере</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Подешавања</translation>
</message>
<message>
<source>Loading</source>
<translation>Učitavanje</translation>
</message>
<message>
<source>please wait...</source>
<translation>молимо вас, сачекајте...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Novi toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Inställningar</translation>
</message>
<message>
<source>Loading</source>
<translation>Laddar</translation>
</message>
<message>
<source>please wait...</source>
<translation>Vänligen vänta...</translation>
</message>
<message>
<source>New Toot</source>
<translation>Ny toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation></translation>
</message>
<message>
<source>Loading</source>
<translation></translation>
</message>
<message>
<source>please wait...</source>
<translation>......</translation>
</message>
<message>
<source>New Toot</source>
<translation></translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>

View file

@ -174,14 +174,6 @@
<source>Settings</source>
<translation>Settings</translation>
</message>
<message>
<source>Loading</source>
<translation></translation>
</message>
<message>
<source>please wait...</source>
<translation></translation>
</message>
<message>
<source>New Toot</source>
<translation>New Toot</translation>
@ -194,6 +186,10 @@
<source>Open in Browser</source>
<translation type="unfinished">Open in Browser</translation>
</message>
<message>
<source>Loading...</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ProfileHeader</name>