fix code formatting

This commit is contained in:
Morgan McMillian 2016-11-11 09:52:45 -08:00
parent 40878e1059
commit eee1fe6eda

View file

@ -1,18 +1,18 @@
/*
* Copyright (C) 2016 Morgan McMillian <gilag@monkeystew.com>
*
*
* This file is apart of the Goober application, a client for pnut.io
*
*
* This program 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.
*
*
* This program 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 this program. If not, see <http://www.gnu.org/licenses/>.
*/
@ -21,22 +21,23 @@ import bb.cascades 1.4
import org.labsquare 1.0
Page {
property variant user
property variant theme : Application.themeSupport.theme.colorTheme.style
property variant theme: Application.themeSupport.theme.colorTheme.style
property string lorem: "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse non enim tellus. Donec vestibulum enim urna, eget faucibus diam commodo a. Donec eget hendrerit metus. Pellentesque vehicula nisi nec vehicula ullamcorper. Aliquam a elit eget mi fringilla porta fermentum eget eros. Phasellus vestibulum nulla sed elit congue adipiscing. Cras imperdiet urna ac ipsum volutpat lobortis. Maecenas vehicula tortor at viverra convallis. Curabitur nibh massa, tristique id felis ut, venenatis faucibus dui. Donec fringilla, mi nec tincidunt dignissim, neque nunc semper mi, quis rutrum diam turpis sit amet erat. Cras a sodales nisi. Nunc sit amet diam sed lectus molestie cursus convallis et erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Duis vitae varius leo. Mauris eu leo a nunc bibendum rutrum euismod et ipsum. "
signal follow(string uid)
signal unfollow(string uid)
signal block(string uid)
signal unblock(string uid)
signal mute(string uid)
signal unmute(string uid)
ScrollView {
Container {
Container {
layout: DockLayout {}
layout: DockLayout {
}
horizontalAlignment: HorizontalAlignment.Fill
preferredHeight: cover.height
Container {
@ -79,7 +80,7 @@ Page {
text: user.name
textStyle.fontWeight: FontWeight.Bold
textStyle.fontSize: FontSize.Large
}
}
Container {
@ -87,20 +88,21 @@ Page {
//text: "thrrgilag"
text: user.username
textStyle.fontSize: FontSize.Medium
}
}
}
}
}
Container {
topPadding: ui.sdu(3)
leftPadding: ui.sdu(3)
rightPadding: ui.sdu(3)
layout: DockLayout {}
layout: DockLayout {
}
horizontalAlignment: HorizontalAlignment.Fill
Container {
preferredWidth: ui.du(45)
@ -122,7 +124,7 @@ Page {
horizontalAlignment: HorizontalAlignment.Right
Label {
text: qsTr("Following")
}
Label {
text: user.counts.following
@ -135,7 +137,7 @@ Page {
horizontalAlignment: HorizontalAlignment.Right
Label {
text: qsTr("Followers")
}
Label {
text: user.counts.followers
@ -148,7 +150,7 @@ Page {
horizontalAlignment: HorizontalAlignment.Right
Label {
text: qsTr("Posts")
}
Label {
text: user.counts.posts
@ -161,55 +163,57 @@ Page {
horizontalAlignment: HorizontalAlignment.Right
Label {
text: qsTr("Bookmarks")
}
Label {
text: user.counts.bookmarks
}
}
}
}
Divider {}
ListView {
id: threadView
dataModel: ArrayDataModel {
id: threadModel
Divider {
}
listItemComponents: [
ListItemComponent {
id: root
PostItem {}
ListView {
id: threadView
dataModel: ArrayDataModel {
id: threadModel
}
]
function sendReply(text, pid) {
pnut.sendReply(text, pid);
}
function getUserName() {
return _app.setting("username")
}
function viewProfile(userobj) {
var page = profilePage.createObject();
page.user = userobj
page.follow.connect(follow)
page.unfollow.connect(unfollow)
page.block.connect(block)
page.unblock.connect(unblock)
page.mute.connect(mute)
page.unmute.connect(unmute)
nav.push(page);
}
function ccOnReply() {
if (_app.setting("cc") === "true") {
return true
} else {
return false
listItemComponents: [
ListItemComponent {
id: root
PostItem {
}
}
]
function sendReply(text, pid) {
pnut.sendReply(text, pid);
}
function getUserName() {
return _app.setting("username")
}
function viewProfile(userobj) {
var page = profilePage.createObject();
page.user = userobj
page.follow.connect(follow)
page.unfollow.connect(unfollow)
page.block.connect(block)
page.unblock.connect(unblock)
page.mute.connect(mute)
page.unmute.connect(unmute)
nav.push(page);
}
function ccOnReply() {
if (_app.setting("cc") === "true") {
return true
} else {
return false
}
}
}
}
}
}
function loadThread(data) {
threadModel.append(data);
}