Friendiqa v0.2.1

This commit is contained in:
LubuWest 2018-04-11 21:50:43 +02:00
commit ee50729e0d
45 changed files with 580 additions and 146 deletions

View file

@ -34,15 +34,15 @@ import QtQuick.Controls 1.4
import QtQuick.Controls.Styles 1.4
import "qrc:/js/news.js" as Newsjs
import "qrc:/js/helper.js" as Helperjs
import "qrc:/qml/genericqml"
Item {
id: newsitem
width: parent.width
height:toprow.height+friendicaActivities.height+controlrow.height+1//Math.max((itemMessage.height+topFlow.height+friendicaActivities.height+4*mm),profileImage.height+user_name.height+mm)
property int itemindex: index
property string attending: ""
property int itemindex: index
onAttendingChanged: {attendLabel.visible=true;
attendLabel.text= qsTr("attending: ")+ qsTr(attending)}
@ -145,8 +145,9 @@ Item {
textFormat: Text.RichText
text:Qt.atob(newsitemobject.statusnet_html)
width: newsitem.width-8*mm-2
height: implicitHeight
height: Math.min(implicitHeight,3/4*root.height)
wrapMode: Text.Wrap
clip:true
onLinkActivated:{
Qt.openUrlExternally(link)}
Component.onCompleted:{
@ -159,6 +160,29 @@ Item {
}
}
}
BlueButton{
width: newsitem.width-8*mm-2
height:10*mm
anchors.bottom: itemMessage.bottom
visible: itemMessage.implicitHeight>3/4*root.height
text:"\uf078"
fontColor:"grey"
border.color: "transparent"
gradient: Gradient {
GradientStop { position: 0.0; color: "transparent" }
GradientStop { position: 0.5; color: "white" }
}
radius:0
onClicked: {
if (text=="\uf078"){
itemMessage.height=itemMessage.implicitHeight+10*mm;text="\uf077"
} else {
itemMessage.height=Math.min(itemMessage.implicitHeight,3/4*root.height);
text="\uf078";
newsView.positionViewAtIndex(index,ListView.Beginning);
}
}
}
}
}
}