Commit 316a19d5 authored by Daniel Molkentin's avatar Daniel Molkentin Committed by Leena Miettinen

Show 'what's new in Qt Creator' as fallback

...if the network connection to the servers containing the rss cannot be obtained.

Change-Id: I39a5706221eaa68e97b4f0abb58bea46a364dce1
Reviewed-on: http://codereview.qt.nokia.com/3424Reviewed-by: default avatarQt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: default avatarLeena Miettinen <riitta-leena.miettinen@nokia.com>
parent 8c6c7ce3
......@@ -47,8 +47,13 @@ Item {
}
ListModel {
id: tempNewsModel
ListElement { title: ""; description: "Loading news sources..." ; blogIcon: ""; blogName: ""; link: "" }
id: fallbackNewsModel
ListElement {
title: "Welcome to Qt Creator 2.3";
blogName: "The Qt Creator Team"
description: "<div>This release adds lots of new features as well as a great amount of bug fixes:</div><ul><li>Example and tutorial browsing with descriptive texts, and filtering for examples matching a keyword</li><li>Enhanced C++ coding style options, with indent settings and alignment settings split up for the different use cases depending on element, including preview and separation between global and project specific settings</li><li>Support for deployment and running to a more general &#8220;remote Linux&#8221;</li><li>Support for compiling projects with the Clang compiler</li><li>Code completion doesn't block the editor any more</li><li>Profiling now has it&#8217;s own &#8220;Analyze&#8221; mode.</li><li>Symbian got CODA support, allowing for deployment via WiFi</li><li>Support for models and delegates in the Qt Quick Designer</li><li>Support for editing inline components and delegates</li><li>Improved Live Preview (a.k.a. modifying QML while the app is running in the debugger)</li><li>Added &#8216;Find usages&#8217; functionality for QML types</li></ul>"
link: ""
}
}
NewsListing {
......@@ -56,8 +61,9 @@ Item {
model: {
if (aggregatedFeedsModel.articleCount > 0)
return aggregatedFeedsModel
else
return tempNewsModel
else {
return fallbackNewsModel
}
}
anchors.bottom: parent.bottom
anchors.top: text.bottom
......
......@@ -145,6 +145,7 @@ Item {
id: styleItem;
cursor: "pointinghandcursor";
anchors.fill: column
visible: link !== ""
}
Timer {
id: toolTipTimer
......@@ -171,7 +172,7 @@ Item {
states: [
State { name: "clicked"; when: mouseArea.pressed; PropertyChanges { target: text; color: "black" } },
State { name: "hovered"; when: mouseArea.containsMouse; PropertyChanges { target: text; color: "#074C1C" } }
State { name: "hovered"; when: mouseArea.containsMouse && link !== ""; PropertyChanges { target: text; color: "#074C1C" } }
]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment