resources/stations/generatelist.xq \
resources/stations/generateunclassifiedlist.xq \
resources/harmattan/qml/main.qml \
- resources/harmattan/qml/StationListPage.qml
+ resources/harmattan/qml/StationListPage.qml \
+ resources/harmattan/qml/StationPage.qml
unix {
isEmpty(PREFIX) {
Page {
id: stationListPage
- tools: toolBar
anchors.margins: UiConstants.DEFAULT_MARGIN
+ tools: ToolBarLayout {
+ id: toolBar
+ ToolIcon { iconId: "icon-m-toolbar-back"; onClicked: pageStack.pop(); }
+ ToolIcon { iconId: "icon-m-toolbar-settings"; onClicked: settingsSheet.open(); }
+ ToolIcon { iconId: "icon-m-toolbar-view-menu"; }
+ }
+
+ function loadStation()
+ {
+ var component = Qt.createComponent("StationPage.qml");
+ if (component.status == Component.Ready) {
+ pageStack.push(component)
+ component.html = "<p>Hello World</p>"
+ }
+ else
+ console.log("Cannot load component: " + component.errorString());
+ }
+
Column {
+ width: parent.width
+ height: parent.height
TextField {
+ width: parent.width
placeholderText: "Search..."
}
ListView {
id: stationListView
- anchors.fill: parent
+ width: parent.width
+ height: parent.height
model: ListModel {
ListElement {
name: "Genova Sestri Ponente"
Label {
id: mainText
text: model.name
+ font.bold: true
//font.family: UiConstants.FONT_FAMILY
//font.pixelSize: UiConstants.FONT_DEFAULT
}
id: mouseArea
anchors.fill: background
onClicked: {
- stationListPage.openFile(page)
+ stationListPage.loadStation(name)
}
}
}
}
}
}
-
- ToolBarLayout {
- id: toolBar
- ToolIcon { iconId: "icon-m-toolbar-back"; onClicked: pageStack.pop(); }
- ToolIcon { iconId: "icon-m-toolbar-settings"; onClicked: settingsSheet.open(); }
- ToolIcon { iconId: "icon-m-toolbar-view-menu"; }
- }
}
--- /dev/null
+import QtQuick 1.1
+import com.nokia.meego 1.0
+import QtWebKit 1.0
+
+Page {
+ property string html: "<p>Hello</p>"
+ anchors.fill: parent
+
+ tools: ToolBarLayout {
+ id: toolBar
+ ToolIcon { iconId: "icon-m-toolbar-back"; onClicked: pageStack.pop(); }
+ ToolIcon { iconId: "icon-m-toolbar-view-menu"; }
+ }
+ WebView {
+ id: view
+ anchors.fill: parent
+ }
+}