Skip to content

Commit

Permalink
Fixed ServiceStatusPage and ThisWeekPage
Browse files Browse the repository at this point in the history
Pulley menu is now disabled on This Weekend and Service Status pages
when busy to avoid possible segfault.
  • Loading branch information
KrisztianOlah committed Sep 7, 2014
1 parent 0af5373 commit a401bfc
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 9 deletions.
2 changes: 1 addition & 1 deletion qml/pages/AboutPage.qml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Page {
right: parent.right
rightMargin: Theme.paddingLarge
}
text: "Version: 0.4.1"
text: "Version: 0.4.2"
}
Label {
id: descriptionLabel
Expand Down
18 changes: 18 additions & 0 deletions qml/pages/ChangelogPage.qml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,24 @@ Page {
PageHeader {
title: "Changelog"
}
Label {
anchors {
left: parent.left
leftMargin: Theme.paddingLarge
right: parent.right
rightMargin: Theme.paddingLarge
}
wrapMode: Text.WordWrap
color: Theme.highlightColor
textFormat: Text.RichText
text: "<b>0.4.2 - Bus Stop Messages.</b><br>
*Added Bus stop messages: relevant messages now appear in the header.<br>
*Fixed bug: Widgets in This Weekend and Service Status pages' expand and contract consistently and text is displayed only inside widget.<br>
*Pulley menu is now disabled on This Weekend and Service Status pages when busy to avoid possible segfault.
*Fixed bug: on Bus Stop page BusyIndicator is now correctly shown whilst dowloading.<br>
*Fixed bug: on Journey Progress page placeholder is now not visible during downloading.<br>
*Other minor GUI improvements."
}
Label {
anchors {
left: parent.left
Expand Down
1 change: 1 addition & 0 deletions qml/pages/ServiceStatusPage.qml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ Page {
onStateChanged: {
busyIndicator.running = serviceStatusData.isDownloading()
pulley.busy = serviceStatusData.isDownloading()
pulley.enabled = !serviceStatusData.isDownloading()
}
}
}
Expand Down
1 change: 1 addition & 0 deletions qml/pages/ThisWeekPage.qml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ Page {
onStateChanged: {
busyIndicator.running = thisWeekendData.isDownloading()
pulley.busy = thisWeekendData.isDownloading()
pulley.enabled = !thisWeekendData.isDownloading()
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion rpm/harbour-london-sail.spec
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Name: harbour-london-sail
%{!?qtc_make:%define qtc_make make}
%{?qtc_builddir:%define _builddir %qtc_builddir}
Summary: London Sail is commuter application for London.
Version: 0.4.1
Version: 0.4.2
Release: 1
Group: Qt/Qt
License: MIT Licence
Expand Down
2 changes: 1 addition & 1 deletion rpm/harbour-london-sail.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Name: harbour-london-sail
Summary: London Sail is commuter application for London.
Version: 0.4.1
Version: 0.4.2
Release: 1
Group: Qt/Qt
URL: http://example.org/
Expand Down
7 changes: 3 additions & 4 deletions src/logic/servicestatuslogic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,16 +72,15 @@ void ServiceStatusLogic::parse(const QByteArray& data) {
qDebug() << ">>> Parsed Successfuly <<<";
emit dataChanged();
}
downloading = false;
emit stateChanged();
}

//private slots:

//It will be called as soon as "reply" signals "finished()"
void ServiceStatusLogic::downloaded() {
QByteArray data = reply->readAll();
parse(data);
downloading = false;
emit stateChanged();
parse(reply->readAll());
reply->deleteLater();
}

Expand Down
4 changes: 2 additions & 2 deletions src/logic/thisweekendlogic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@ void ThisWeekendLogic::parseData(const QByteArray& data) {
qDebug() << "Parsing failed";
}
qDebug() << "Not Downloading";
downloading = false;
emit stateChanged();
}

//private slots:
//This slot is called when data is downloaded
void ThisWeekendLogic::downloaded() {
downloading = false;
emit stateChanged();
parseData(reply->readAll());
reply->deleteLater();
}
Expand Down

0 comments on commit a401bfc

Please sign in to comment.