| 1 |
import QtQuick 2.4 |
| 2 |
import QtQuick.Controls 2.2 |
| 3 |
|
| 4 |
import FlightGear.Launcher 1.0 |
| 5 |
import FlightGear 1.0 |
| 6 |
|
| 7 |
Item { |
| 8 |
id: root |
| 9 |
|
| 10 |
readonly property string forumLink: "href=\"https://forum.flightgear.org\""; |
| 11 |
readonly property string forumHelpLink: "href=\"https://forum.flightgear.org/viewforum.php?f=17\""; |
| 12 |
|
| 13 |
readonly property string wikiLink: "href=\"http://wiki.flightgear.org/Portal:User\""; |
| 14 |
|
| 15 |
Flickable |
| 16 |
{ |
| 17 |
id: flick |
| 18 |
|
| 19 |
contentHeight: contentColumn.childrenRect.height |
| 20 |
flickableDirection: Flickable.VerticalFlick |
| 21 |
height: parent.height |
| 22 |
width: parent.width - (Style.strutSize * 4) |
| 23 |
x: Style.strutSize * 2 |
| 24 |
y: Style.strutSize |
| 25 |
ScrollBar.vertical: ScrollBar {} |
| 26 |
|
| 27 |
function getDevelopmentYears() { |
| 28 |
// 1996 - the year work began on FlightGear |
| 29 |
return (new Date()).getFullYear() - 1996; |
| 30 |
} |
| 31 |
|
| 32 |
Column { |
| 33 |
id: contentColumn |
| 34 |
spacing: Style.strutSize |
| 35 |
width: parent.width |
| 36 |
|
| 37 |
Text { |
| 38 |
width: parent.width |
| 39 |
font.pixelSize: Style.baseFontPixelSize * 1.5 |
| 40 |
color: Style.baseTextColor |
| 41 |
wrapMode: Text.WordWrap |
| 42 |
|
| 43 |
readonly property var pdfManualLink: "href=\"https://www.flightgear.org/support/manual\"" |
| 44 |
readonly property var shortRefLink: "href=\"" + _launcher.urlToDataPath("Docs/FGShortRef.html") + "\"" |
| 45 |
|
| 46 |
text: qsTr("<p>FlightGear is open source software, developed entirely by volunteers. " + |
| 47 |
"Support is provided by our excellent user community. " + |
| 48 |
"The easiest place to ask questions and get support is on <a %1>our forums</a>.</p>\n" + |
| 49 |
"<p>To get started with the simulator, please use our tutorial system: " + |
| 50 |
"this is available from the 'Help' menu in the simulator. We recommend " + |
| 51 |
"starting with the Cessna 172 to learn how to get airborne.</p>\n" + |
| 52 |
"<p>Other good resources:<ul>" + |
| 53 |
"<li><a %2>the official manual</a></li>\n" + |
| 54 |
"<li><a %3>key commands reference</a></li>\n" + |
| 55 |
"<li><a %4>our wiki</a> (which includes FAQs)</li>\n" + |
| 56 |
"</ul></p>" |
| 57 |
).arg(root.forumLink).arg(pdfManualLink).arg(shortRefLink).arg(root.wikiLink) |
| 58 |
|
| 59 |
onLinkActivated: { |
| 60 |
Qt.openUrlExternally(link) |
| 61 |
} |
| 62 |
} |
| 63 |
|
| 64 |
Text { |
| 65 |
width: parent.width |
| 66 |
font.pixelSize: Style.baseFontPixelSize * 1.5 |
| 67 |
color: Style.baseTextColor |
| 68 |
wrapMode: Text.WordWrap |
| 69 |
|
| 70 |
text: qsTr("<p>For help using this launcher, <a %1>try enabling the getting started hints</a>.</p>\n").arg("href=\"enable-tips\""); |
| 71 |
|
| 72 |
onLinkActivated: { |
| 73 |
// reset tips, so they are shown again |
| 74 |
_launcher.resetGettingStartedTips(); |
| 75 |
} |
| 76 |
} |
| 77 |
|
| 78 |
Text { |
| 79 |
width: parent.width |
| 80 |
font.pixelSize: Style.baseFontPixelSize * 1.5 |
| 81 |
color: Style.baseTextColor |
| 82 |
wrapMode: Text.WordWrap |
| 83 |
|
| 84 |
text: qsTr("<p>If you find an issue, please use <a %1>our help forum</a>.</p>\n").arg(root.forumHelpLink); |
| 85 |
|
| 86 |
onLinkActivated: { |
| 87 |
Qt.openUrlExternally(link) |
| 88 |
} |
| 89 |
} |
| 90 |
|
| 91 |
Text { |
| 92 |
width: parent.width |
| 93 |
font.pixelSize: Style.baseFontPixelSize * 1.5 |
| 94 |
color: Style.baseTextColor |
| 95 |
wrapMode: Text.WordWrap |
| 96 |
|
| 97 |
text: qsTr("<p>FlightGear is the result of %1 years of work " + |
| 98 |
"by hundreds of contributors around the world. We'd be " + |
| 99 |
"delighted if you would join us.</p>\n").arg(flick.getDevelopmentYears()) |
| 100 |
|
| 101 |
// onLinkActivated: { |
| 102 |
// Qt.openUrlExternally(link) |
| 103 |
// } |
| 104 |
} |
| 105 |
} |
| 106 |
|
| 107 |
} // of flickable |
| 108 |
} |