diff --git a/debian/rules b/debian/rules old mode 100755 new mode 100644 diff --git a/siilihai-mobile.desktop b/harbour-siilihai-mobile.desktop similarity index 58% rename from siilihai-mobile.desktop rename to harbour-siilihai-mobile.desktop index 25f9f54..7351467 100644 --- a/siilihai-mobile.desktop +++ b/harbour-siilihai-mobile.desktop @@ -2,5 +2,5 @@ Type=Application X-Nemo-Application-Type=no-invoker Name=Siilihai -Icon=siilihai-mobile -Exec=siilihai-mobile +Icon=harbour-siilihai-mobile +Exec=harbour-siilihai-mobile diff --git a/siilihai-mobile.png b/harbour-siilihai-mobile.png similarity index 100% rename from siilihai-mobile.png rename to harbour-siilihai-mobile.png diff --git a/main.cpp b/main.cpp index 9944c72..07c949b 100644 --- a/main.cpp +++ b/main.cpp @@ -17,15 +17,12 @@ Q_DECL_EXPORT int main(int argc, char *argv[]) app.setQuitOnLastWindowClosed(false); app.connect(&viewer, SIGNAL(closing(QQuickCloseEvent*)), &shm, SLOT(haltSiilihai())); -#ifdef use_components - viewer.setMainQmlFile(QStringLiteral("qrc:/qml/siilihai-mobile/main.qml")); -#else // Find the main.qml to use.. QFile mainQml("../siilihai-mobile/qml/siilihai-mobile-nocomponents/main.qml"); if(mainQml.exists()) { viewer.setMainQmlFile(mainQml.fileName()); } else { - mainQml.setFileName("/usr/share/siilihai-mobile/qml/siilihai-mobile-nocomponents/main.qml"); + mainQml.setFileName("/usr/share/harbour-siilihai-mobile/qml/siilihai-mobile-nocomponents/main.qml"); if(mainQml.exists()) { viewer.setMainQmlFile(mainQml.fileName()); } else { @@ -33,7 +30,7 @@ Q_DECL_EXPORT int main(int argc, char *argv[]) return -1; } } -#endif + // viewer.setOrientation(QmlApplicationViewer::ScreenOrientationAuto); shm.setContextProperties(); // Root ctx may change when loading, so redo this //viewer.showExpanded(); diff --git a/qml/siilihai-mobile-nocomponents/HideEffect.qml b/qml/siilihai-mobile-nocomponents/HideEffect.qml index 0de4699..c81fcbf 100644 --- a/qml/siilihai-mobile-nocomponents/HideEffect.qml +++ b/qml/siilihai-mobile-nocomponents/HideEffect.qml @@ -1,6 +1,11 @@ import QtQuick 2.0 -import QtGraphicalEffects 1.0 +// Disabled until QGE are allowed +//import QtGraphicalEffects 1.0 +Item { + +} +/* RecursiveBlur { anchors.fill: parent source: parent @@ -10,3 +15,4 @@ RecursiveBlur { visible: opacity > 0 Behavior on opacity { SmoothedAnimation { velocity: 5 } } } +*/ diff --git a/qml/siilihai-mobile-nocomponents/widgets/BusyIndicator.qml b/qml/siilihai-mobile-nocomponents/widgets/BusyIndicator.qml index d409f46..09c680c 100644 --- a/qml/siilihai-mobile-nocomponents/widgets/BusyIndicator.qml +++ b/qml/siilihai-mobile-nocomponents/widgets/BusyIndicator.qml @@ -11,7 +11,7 @@ Rectangle { height: parent.height width: height*2 SequentialAnimation on x { - running: enabled + running: enabled && Qt.application.active loops: Animation.Infinite NumberAnimation { from: 0; to: busyindicator.width; duration: 500; easing.type: Easing.InOutQuad } NumberAnimation { from: busyindicator.width; to: 0; duration: 500; easing.type: Easing.InOutQuad } diff --git a/qml/siilihai-mobile/AccountlessRegistration.qml b/qml/siilihai-mobile/AccountlessRegistration.qml deleted file mode 100644 index e8ed24e..0000000 --- a/qml/siilihai-mobile/AccountlessRegistration.qml +++ /dev/null @@ -1,25 +0,0 @@ -// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5 -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Page { - tools: commonTools - anchors.fill: parent - - Column { - spacing: 30 - anchors.centerIn: parent - Label { - text: "Note: Some features such as synchronizing are not possible without an account." - wrapMode: Text.Wrap - width: parent.width - } - Button { - text: "Continue" - onClicked: { - appWindow.registerUser('', '', '', false) - appWindow.pageStack.pop(mainPage); - } - } - } -} diff --git a/qml/siilihai-mobile/ButtonWithUnreadCount.qml b/qml/siilihai-mobile/ButtonWithUnreadCount.qml deleted file mode 100644 index 3ad2a46..0000000 --- a/qml/siilihai-mobile/ButtonWithUnreadCount.qml +++ /dev/null @@ -1,89 +0,0 @@ -// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5 -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Button { - id: button - property string label: "" - property string icon: "" - property string errorIcon: "emblem-web.png" - property int unreads: 0 - property bool busy: false - property bool moreAvailable: false - width: mainPage.width - height: buttonText.height + 30 - BusyIndicator { - id: busyindicator - running: button.busy - visible: running - anchors.fill: iconImage - z: 100 - } - Image { - id: iconImage - source: icon - anchors.left: button.left - anchors.verticalCenter: button.verticalCenter - width: 32 - height: 32 - anchors.leftMargin: 5 - onStatusChanged: { - if(status == Image.Error) - source = errorIcon - } - } - - Label { - font.pointSize: button.font.pointSize - anchors.verticalCenter: button.verticalCenter - anchors.left: busyindicator.right - id: buttonText - wrapMode: Text.Wrap - anchors.leftMargin: 5 - text: button.label -// text: iconImage.source - width: button.width - busyindicator.width - separator.width - unreadText.width - verticalAlignment: Text.AlignVCenter - font.bold: unreads > 0 - } - Rectangle { - id: separator - visible: unreadText.visible - width: 2 - height: button.height * 0.9 - anchors.right: unreadText.left - anchors.rightMargin: 2 - anchors.verticalCenter: button.verticalCenter - gradient: Gradient { - GradientStop { - position: 0.0 - color: "#FFFFFF" - } - GradientStop { - position: 0.2 - color: "#888888" - } - GradientStop { - position: 0.8 - color: "#666666" - } - GradientStop { - position: 1.0 - color: "#FFFFFF" - } - } - } - Label { - id: unreadText - font.pointSize: button.font.pointSize/2 - text: button.unreads.toString() + (moreAvailable ? "+" : "") - visible: button.unreads > 0 || moreAvailable - anchors.right: button.right - anchors.top: buttonText.top - width: button.width / 10 - height: buttonText.height - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - font.bold: unreads > 0 - } -} diff --git a/qml/siilihai-mobile/ConfirmUnsubscribe.qml b/qml/siilihai-mobile/ConfirmUnsubscribe.qml deleted file mode 100644 index 525187b..0000000 --- a/qml/siilihai-mobile/ConfirmUnsubscribe.qml +++ /dev/null @@ -1,8 +0,0 @@ -// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5 -import QtQuick 1.1 - -Rectangle { - width: 100 - height: 62 - -} diff --git a/qml/siilihai-mobile/CredentialsDialogPage.qml b/qml/siilihai-mobile/CredentialsDialogPage.qml deleted file mode 100644 index dfb1ef2..0000000 --- a/qml/siilihai-mobile/CredentialsDialogPage.qml +++ /dev/null @@ -1,57 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - anchors.fill: parent - property string forumname: "?" - property string credentialtype: "?" - Column { - spacing: 15 - anchors.centerIn: parent - Label { - text: "Enter " + credentialtype + " credentials for " + forumname - wrapMode: Text.Wrap - width: parent.width - } - Column { - spacing: 4 - Label { - text: "Username:" - } - TextField { - placeholderText: "Username" - id: forumUsername - } - } - Column { - spacing: 4 - Label { - text: "Password:" - } - TextField { - placeholderText: "Password" - echoMode: TextInput.Password - id: forumPassword - } - } - CheckBox { - id: rememberCreds - text: "Remember" - checked: true - } - - Button { - text: "Ok" - onClicked: { - appWindow.pageStack.pop(mainPage, true); - appWindow.credentialsEntered(forumUsername.text, forumPassword.text, rememberCreds.checked) - } - } - } - function resetForm() { - console.log("resetform") - forumUsername.text = "" - forumPassword.text = "" - rememberCreds.checked = true - } -} diff --git a/qml/siilihai-mobile/ForumCredentialsPage.qml b/qml/siilihai-mobile/ForumCredentialsPage.qml deleted file mode 100644 index bd0b103..0000000 --- a/qml/siilihai-mobile/ForumCredentialsPage.qml +++ /dev/null @@ -1,84 +0,0 @@ -// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5 -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Page { - anchors.fill: parent - property string forumname: "" - property string subscribeError: "" - property int forumid: 0 - property bool supportsLogin: false - property bool forumDownloaded: false - Column { - visible: subscribeError.length == 0 - spacing: 15 - anchors.centerIn: parent - ProgressBar { - indeterminate: true - width: parent.width - visible: !forumDownloaded && subscribeError.length == 0 - } - CheckBox { - id: haveCredentials - text: "I have user account on this forum" - enabled: supportsLogin - visible: supportsLogin - } - Label { - text: "This forum does not support authentication" - wrapMode: Text.Wrap - visible: !supportsLogin - } - Column { - spacing: 4 - Label { - text: "Username:" - } - TextField { - placeholderText: "Username" - id: forumUsername - enabled: haveCredentials.checked - } - } - Column { - spacing: 4 - Label { - text: "Password:" - } - TextField { - placeholderText: "Password" - echoMode: TextInput.Password - id: forumPassword - enabled: haveCredentials.checked - } - } - Button { - text: "Continue" - enabled: forumDownloaded - onClicked: { - if(haveCredentials.checked) { - appWindow.subscribeForumWithCredentials(forumid, forumname, forumUsername.text, forumPassword.text) - } else { - appWindow.subscribeForum(forumid, forumname) - } - subscribeWizardPage.selectionMode = 0; - forumid = 0 - forumname = "" - appWindow.pageStack.pop(mainPage) - } - } - Label { - text: subscribeError - visible: subscribeError.length > 0 - wrapMode: Text.Wrap - width: forumCredentialsPage.width - } - Button { - text: "Back" - onClicked: { - subscribeWizardPage.selectionMode = 0; - appWindow.pageStack.pop() - } - } - } -} diff --git a/qml/siilihai-mobile/GroupListPage.qml b/qml/siilihai-mobile/GroupListPage.qml deleted file mode 100644 index a7c1a83..0000000 --- a/qml/siilihai-mobile/GroupListPage.qml +++ /dev/null @@ -1,76 +0,0 @@ -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Page { - anchors.fill: parent - property string forumname: "?" - property string forumIcon: "" - tools: commonTools - - ListView { - anchors.fill: parent - model: groups - spacing: 5 - header: Row { - Image { - source: forumIcon - width: height - height: 32 - z: -10 - anchors.verticalCenter: forumNameLabel.Center - } - Label { - id: forumNameLabel - text: forumname; - wrapMode: Text.Wrap - anchors.leftMargin: 10 - } - } - - delegate: Row { - ButtonWithUnreadCount { - label: name - unreads: unreadCount - icon: unreads > 0 ? "folder-new.png" : "folder.png" - onClicked: { - threadListPage.groupname = name - appWindow.groupSelected(id) - appWindow.pageStack.push(threadListPage) - } - } - } - footer: Column { - Button { - text: "Manage Subscriptions" - onClicked: appWindow.subscribeGroups() - anchors.horizontalCenter: parent.horizontalCenter - } - Button { - text: "Unsubscribe" - anchors.horizontalCenter: parent.horizontalCenter - onClicked: confirmUnsubscribeDialog.open() - } - } - } - Dialog { - id: confirmUnsubscribeDialog - content: Label { - text: "Really unsubscribe from forum?" - width: parent.width - anchors.centerIn: parent - wrapMode: Text.Wrap - color: "white" - } - buttons: ButtonRow { - anchors.horizontalCenter: parent.horizontalCenter - anchors.topMargin: 30 - anchors.top: errorLabel.Bottom - Button {text: "Yes"; onClicked: confirmUnsubscribeDialog.accept()} - Button {text: "No"; onClicked: confirmUnsubscribeDialog.reject()} - } - onAccepted: { - pageStack.pop() - appWindow.unSubscribeCurrentForum() - } - } -} diff --git a/qml/siilihai-mobile/HaltScreen.qml b/qml/siilihai-mobile/HaltScreen.qml deleted file mode 100644 index a637ed4..0000000 --- a/qml/siilihai-mobile/HaltScreen.qml +++ /dev/null @@ -1,18 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - anchors.fill: parent - property string text - Column { - Label { - text: "Quitting, please wait" - wrapMode: Text.Wrap - } - Label { - text: mainPage.message - wrapMode: Text.Wrap - font.italic: true - } - } -} diff --git a/qml/siilihai-mobile/LoginWizardPage.qml b/qml/siilihai-mobile/LoginWizardPage.qml deleted file mode 100644 index ffe02b4..0000000 --- a/qml/siilihai-mobile/LoginWizardPage.qml +++ /dev/null @@ -1,91 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - property bool loggingIn: false - enabled: !loggingIn - - RegistrationPage { - id: registrationPage - } - AccountlessRegistration { - id: accountlessRegistration - } - anchors.fill: parent - Column { - spacing: 15 - anchors.centerIn: parent - Label { - text: "Welcome to Siilihai" - wrapMode: Text.Wrap - width: parent.width - } - Column { - spacing: 4 - Label { - text: "Username:" - } - TextField { - placeholderText: "Username" - id: loginUsername - font.capitalization: Font.MixedCase - } - } - Column { - spacing: 4 - Label { - text: "Password:" - } - TextField { - placeholderText: "Password" - echoMode: TextInput.Password - id: loginPassword - } - } - Button { - text: "Login" - onClicked: { - loggingIn = true - appWindow.loginUser(loginUsername.text, loginPassword.text) - } - } - Button { - anchors.topMargin: 15 - text: "Register" - - onClicked: { - appWindow.pageStack.push(registrationPage) - } - } - Button { - anchors.topMargin: 15 - text: "Use without account" - - onClicked: { - appWindow.pageStack.push(accountlessRegistration) - } - } - ProgressBar { - indeterminate: true - width: parent.width - visible: loggingIn - } - } - Component.onCompleted: { - appWindow.closeLogin.connect(closeLogin) - } - - function closeLogin(success, motd) { - console.log("closeLogin " + success + motd); - loggingIn = false - if(success) { - appWindow.pageStack.pop(mainPage); - } else { - if(motd.length > 0) { - appWindow.showMessage(motd); - } else { - appWindow.showMessage("Login failed. Check your Internet connection etc."); - } - } - } -} diff --git a/qml/siilihai-mobile/MainPage.qml b/qml/siilihai-mobile/MainPage.qml deleted file mode 100644 index f211f5a..0000000 --- a/qml/siilihai-mobile/MainPage.qml +++ /dev/null @@ -1,46 +0,0 @@ -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Page { - property bool busy: true - property string message: "" - - tools: commonTools - ListView { - anchors.fill: parent - model: subscriptions - spacing: 5 - header: Column { - width: parent.width - ProgressBar { - indeterminate: true - width: parent.width - visible: mainPage.busy - } - Label { - id: statusmessage - text: mainPage.message - font.italic: true - } - } - delegate: Row { - ButtonWithUnreadCount { - label: alias - unreads: unreadCount - busy: beingUpdated || beingSynced || scheduledForUpdate - icon: faviconUrl.length > 0 ? faviconUrl : "emblem-web.png" - onClicked: { - groupListPage.forumname = alias - groupListPage.forumIcon = icon - appWindow.subscriptionSelected(forumId) - appWindow.pageStack.push(groupListPage) - } - } - } - footer: Button { - anchors.horizontalCenter: parent.horizontalCenter - text: "Subscribe new.." - onClicked: appWindow.showSubscribeWizard() - } - } -} diff --git a/qml/siilihai-mobile/MessageDisplay.qml b/qml/siilihai-mobile/MessageDisplay.qml deleted file mode 100644 index f9476be..0000000 --- a/qml/siilihai-mobile/MessageDisplay.qml +++ /dev/null @@ -1,97 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 -import QtWebKit 1.0 - -Rectangle { - id: message - property string subject: "?" - property string author: "?" - property string messageBody: "" - property bool messageRead: false - property string messageId: "" - - property string styleHtml: "" - property string contentHtml: "" + - styleHtml + "" + messageBody + "" - width: mainPage.width - height: subjectLine.height + body.height + 40 - radius: 15 - smooth: true - anchors.bottomMargin: 4 - - Label { - id: subjectLine - text: message.subject + " (" + message.author + ")" - width: message.width - openButton.width - wrapMode: Text.WordWrap - font.pointSize: 20 - color: "white" - } - - Button { - id: openButton - iconSource: "emblem-web.png" - anchors.left: subjectLine.right - width: height - onClicked: { - openInBrowser(messageId) - } - } - - Label { - id: toolLine - text: (messageRead?"Read":"Unread") + " by " + message.author - width: message.width - font.pointSize: 12 - anchors.top: subjectLine.bottom - } - - WebView { // Causes some trouble, won't wrap text as expected - id: body - html: message.contentHtml - width: mainPage.width - preferredWidth: width - anchors.top: toolLine.bottom - z: 10 - settings.pluginsEnabled: true - settings.javascriptEnabled: true - settings.javascriptCanOpenWindows: false - } - Rectangle { - radius: 5 - smooth: true - color: "white" - width: message.width - height: body.height - anchors.top: body.top - } - - gradient: Gradient { - GradientStop { - position: 0.0 - color: "#888888" - } - GradientStop { - position: 0.1 - color: "#AAAAAA" - } - GradientStop { - position: 0.8 - color: "#CCCCCC" - } - GradientStop { - position: 1.0 - color: "#CCCCFF" - } - } -} diff --git a/qml/siilihai-mobile/MessageListPage.qml b/qml/siilihai-mobile/MessageListPage.qml deleted file mode 100644 index 7c6a63b..0000000 --- a/qml/siilihai-mobile/MessageListPage.qml +++ /dev/null @@ -1,96 +0,0 @@ -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Page { - property bool hasMoreMessages: false - property string threadname: "?" - - tools: ToolBarLayout { - visible: true - ToolIcon { - id: backButton - platformIconId: "toolbar-back" - onClicked: pageStack.pop() - } - ToolIcon { - id: upButton - platformIconId: "toolbar-up" - onClicked: { - messagelistview.contentY = 0 - messagelistview.returnToBounds() - } - anchors.left: backButton.right - visible: !messagelistview.atYBeginning - } - ToolIcon { - platformIconId: "toolbar-down" - onClicked: { - messagelistview.contentY = messagelistview.contentHeight - messagelistview.returnToBounds() - } - anchors.left: upButton.right - visible: !messagelistview.atYEnd - } - ToolIcon { - platformIconId: "toolbar-view-menu" - anchors.right: (parent === undefined) ? undefined : parent.right - onClicked: (myMenu.status == DialogStatus.Closed) ? myMenu.open() : myMenu.close() - } - } - Rectangle { - id: scrollbar - anchors.right: messagelistview.right - y: messagelistview.visibleArea.yPosition * messagelistview.height - width: 10 - height: messagelistview.visibleArea.heightRatio * messagelistview.height - color: "black" - z: 100 - visible: messagelistview.moving - } - Rectangle { - id: scrollbarbg - anchors.right: messagelistview.right - y: 0 - width: 10 - height: messagelistview.height - color: "white" - z: 99 - visible: scrollbar.visible - } - ListView { - id: messagelistview - anchors.fill: parent - model: messages - boundsBehavior: Flickable.StopAtBounds - - delegate: Row { - MessageDisplay { - subject: displayName - author: authorCleaned - messageBody: body - messageRead: isRead - messageId: id - } - } - footer: Column { - anchors.topMargin: 10 - spacing: 30 - Button { - text: "Show more messages.." - anchors.horizontalCenter: parent.horizontalCenter - onClicked: appWindow.showMoreMessages() - visible: hasMoreMessages - } - Button { - text: "Mark thread read" - anchors.horizontalCenter: parent.horizontalCenter - onClicked: appWindow.markThreadRead(true) - } - Button { - text: "Mark thread unread" - anchors.horizontalCenter: parent.horizontalCenter - onClicked: appWindow.markThreadRead(false) - } - } - } -} diff --git a/qml/siilihai-mobile/MessagePage.qml b/qml/siilihai-mobile/MessagePage.qml deleted file mode 100644 index f7eeda5..0000000 --- a/qml/siilihai-mobile/MessagePage.qml +++ /dev/null @@ -1,13 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - tools: commonTools - anchors.fill: parent - property string text - Label { - text: messagePage.text - wrapMode: Text.Wrap - anchors.fill: parent - } -} diff --git a/qml/siilihai-mobile/RegistrationPage.qml b/qml/siilihai-mobile/RegistrationPage.qml deleted file mode 100644 index 20dc6f4..0000000 --- a/qml/siilihai-mobile/RegistrationPage.qml +++ /dev/null @@ -1,101 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - tools: commonTools - anchors.fill: parent - property bool registering: false - enabled: !registering - Label { - text: "Registration" - width: parent.width - } - Column { - spacing: 15 - anchors.centerIn: parent - - Column { - spacing: 4 - Label { - text: "Username:" - } - TextField { - placeholderText: "Username" - id: username - text: loginUsername.text - } - } - Column { - spacing: 4 - Label { - text: "E-mail address:" - } - TextField { - placeholderText: "E-mail address" - id: email - } - } - Column { - spacing: 4 - Label { - text: "Password:" - } - TextField { - placeholderText: "Password" - echoMode: TextInput.Password - id: password - text: loginPassword.text - } - TextField { - placeholderText: "Repeat" - echoMode: TextInput.Password - id: password2 - } - } - Column { - spacing: 4 - CheckBox { - id: sync - text: "Synchronize with server" - checked: true - } - } - Button { - text: "Continue" - enabled: valuesValid() && !registering - onClicked: { - registering = true - appWindow.registerUser(username.text, password.text, email.text, sync.checked) - } - function valuesValid() { - if(username.text.length < 4) return false; - if(password.text.length < 5 || password.text!=password2.text) return false; - if(email.text.length<4 || email.text.indexOf("@")==-1 || email.text.indexOf(".")==-1) return false; - return true; - } - } - ProgressBar { - indeterminate: true - width: parent.width - visible: registering - } - } - - Component.onCompleted: { - appWindow.closeRegistration.connect(closeRegistration) - } - - function closeRegistration(success, motd) { - console.log("closeRegistration " + success + motd); - registering = false - if(success) { - appWindow.pageStack.pop(mainPage); - } else { - if(motd.length > 0) { - appWindow.showMessage(motd); - } else { - appWindow.showMessage("Registration failed. Check your Internet connection etc."); - } - } - } -} diff --git a/qml/siilihai-mobile/SubscribeGroupsPage.qml b/qml/siilihai-mobile/SubscribeGroupsPage.qml deleted file mode 100644 index 871a5a5..0000000 --- a/qml/siilihai-mobile/SubscribeGroupsPage.qml +++ /dev/null @@ -1,38 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - tools: commonTools - anchors.fill: parent - - ListView { - model: subscribeGroupList - anchors.fill: parent - - header: Label { - id: text - text: "Subscribe to groups" - wrapMode: Text.Wrap - } - - delegate: Row { - CheckBox { - text: displayName - width: mainPage.width - checked: isSubscribed - onCheckedChanged: { - appWindow.setGroupSubscribed(id, checked) - } - } - } - - footer: Button { - text: "Apply" - anchors.horizontalCenter: parent.horizontalCenter - onClicked: { - appWindow.applyGroupSubscriptions() - appWindow.pageStack.pop() - } - } - } -} diff --git a/qml/siilihai-mobile/SubscribeWizardPage.qml b/qml/siilihai-mobile/SubscribeWizardPage.qml deleted file mode 100644 index b0ac52c..0000000 --- a/qml/siilihai-mobile/SubscribeWizardPage.qml +++ /dev/null @@ -1,71 +0,0 @@ -import QtQuick 1.0 -import com.nokia.meego 1.0 - -Page { - tools: commonTools - anchors.fill: parent - property int selectionMode: 0 // 0=nothing 1=url 2=list - - ListView { - model: forumList - anchors.fill: parent - id: forumListView - header: Column { - spacing: 30 - Label { - text: "Subscribe to a forum" - wrapMode: Text.Wrap - width: subscribeWizardPage.width - } - Button { - text: "Enter URL" - visible: selectionMode == 0 - onClicked: selectionMode = 1 - } - Button { - text: "Select from list" - visible: selectionMode == 0 - onClicked: selectionMode = 2 - } - TextInput { - id: urlInput - visible: selectionMode == 1 - font.pointSize: 30 - width: parent.width - color: "black" - text: "http://" -// inputMask: "\http://XXX" - Rectangle { - color: "white" - anchors.fill: parent - z: -10 - } - } - Button { - text: "Continue" - visible: selectionMode == 1 - onClicked: { - forumCredentialsPage.forumname = "Getting forum.." - forumCredentialsPage.forumid = 0 - forumCredentialsPage.subscribeError = "" - appWindow.getForumUrlDetails(urlInput.text); - } - } - } - delegate: Column { - visible: selectionMode == 2 - ButtonWithUnreadCount { - label: alias - width: subscribeWizardPage.width - icon: faviconUrl - onClicked: { - forumCredentialsPage.forumname = alias - forumCredentialsPage.forumid = forumId - forumCredentialsPage.subscribeError = "" - appWindow.pageStack.push(forumCredentialsPage) - appWindow.getForumDetails(forumId) - } - } - } - } -} diff --git a/qml/siilihai-mobile/ThreadListPage.qml b/qml/siilihai-mobile/ThreadListPage.qml deleted file mode 100644 index c00196d..0000000 --- a/qml/siilihai-mobile/ThreadListPage.qml +++ /dev/null @@ -1,43 +0,0 @@ -import QtQuick 1.1 -import com.nokia.meego 1.0 - -Page { - tools: commonTools - property string groupname: "?" - - ListView { - anchors.fill: parent - model: threads - - header: Row { - Image { - source: groupListPage.forumIcon - width: height - height: 32 - z: -10 - anchors.verticalCenter: forumNameLabel.Center - } - Label { - id: forumNameLabel - text: groupname; - wrapMode: Text.Wrap - anchors.leftMargin: 10 - } - } - - delegate: Row { - ButtonWithUnreadCount { - label: displayName - unreads: unreadCount - moreAvailable: hasMoreMessages - icon: (unreads > 0 || hasMoreMessages) ? "folder-new.png" : "folder.png" - onClicked: { - appWindow.threadSelected(id) - messageListPage.hasMoreMessages = hasMoreMessages - messageListPage.threadname = displayName - appWindow.pageStack.push(messageListPage) - } - } - } - } -} diff --git a/qml/siilihai-mobile/emblem-web.png b/qml/siilihai-mobile/emblem-web.png deleted file mode 100644 index dc81971..0000000 Binary files a/qml/siilihai-mobile/emblem-web.png and /dev/null differ diff --git a/qml/siilihai-mobile/folder-new.png b/qml/siilihai-mobile/folder-new.png deleted file mode 100644 index ca31874..0000000 Binary files a/qml/siilihai-mobile/folder-new.png and /dev/null differ diff --git a/qml/siilihai-mobile/folder.png b/qml/siilihai-mobile/folder.png deleted file mode 100644 index cd3e1a0..0000000 Binary files a/qml/siilihai-mobile/folder.png and /dev/null differ diff --git a/qml/siilihai-mobile/main.qml b/qml/siilihai-mobile/main.qml deleted file mode 100644 index a833630..0000000 --- a/qml/siilihai-mobile/main.qml +++ /dev/null @@ -1,193 +0,0 @@ -import QtQuick 1.1 -import com.nokia.meego 1.1 - -PageStackWindow { - id: appWindow - initialPage: mainPage - - // QML -> C++ - signal subscriptionSelected(int parser) - signal groupSelected(string id) - signal threadSelected(string id) - signal haltSiilihai() - signal registerUser(string username, string password, string email, bool sync) - signal closeRegistration(bool success, string motd) - signal loginUser(string username, string password) - signal closeLogin(bool success, string motd) - signal listSubscriptions() - signal getForumDetails(int id) - signal getForumUrlDetails(string url) - signal subscribeForum(int id, string name) - signal subscribeForumWithCredentials(int id, string name, string user, string pass) - signal unSubscribeCurrentForum() - signal subscribeGroups() - signal setGroupSubscribed(string id, bool sub) - signal applyGroupSubscriptions(); - signal credentialsEntered(string u, string p, bool remember) - signal markThreadRead(bool read); - signal showMoreMessages(); - signal updateClicked(); - signal openInBrowser(string id); - signal confirmMessages(); - - Component.onCompleted: { - console.log("Loaded") - } - Component.onDestruction: { - console.log("QML exit") - haltSiilihai() - } - - MainPage { - id: mainPage - } - GroupListPage { - id: groupListPage - } - ThreadListPage { - id: threadListPage - } - MessageListPage { - id: messageListPage - } - MessagePage { - id: messagePage - } - LoginWizardPage { - id: loginWizardPage - } - SubscribeWizardPage { - id: subscribeWizardPage - } - ForumCredentialsPage { - id: forumCredentialsPage - } - SubscribeGroupsPage { - id: subscribeGroupsPage - } - CredentialsDialogPage { - id: credentialsDialogPage - } - HaltScreen { - id: haltScreen - } - - ToolBarLayout { - id: commonTools - Row { - ToolIcon { - id: backButton - platformIconId: "toolbar-back" - onClicked: { - if(pageStack.currentPage==messagePage) { - pageStack.pop() - displayNextMessage(); - } else { - pageStack.pop() - } - } - visible: appWindow.pageStack.currentPage != mainPage - } - ToolIcon { - platformIconId: "toolbar-refresh" - enabled: !mainPage.busy - onClicked: appWindow.updateClicked() - visible: !backButton.visible - } - } - } - - Timer { - id: statusmessagetimer - interval: 5000; running: false; repeat: false - onTriggered: mainPage.message = " " - } - - Dialog { - id: errorDialog - property string errorText: "" - content: Label { - id: errorLabel - text: errorDialog.errorText - width: parent.width - anchors.centerIn: parent - wrapMode: Text.Wrap - color: "white" - } - buttons: ButtonRow { - anchors.horizontalCenter: parent.horizontalCenter - anchors.topMargin: 30 - anchors.top: errorLabel.Bottom - Button {text: "Ok"; onClicked: errorDialog.accept()} - } - onRejected: confirmMessages() - onAccepted: confirmMessages() - } - - - onSubscriptionSelected: { - console.log("onSubscriptionSelected " + parser) - } - - function showErrorMessage(msg) { - console.log("showErrorMessage") - errorDialog.errorText = msg - errorDialog.open() - } - - function showLoginWizard() { - console.log("showLoginWizard") - appWindow.pageStack.push(loginWizardPage) - } - function registrationFinished(success, motd) { - console.log("registrationFinished") - appWindow.closeRegistration(success, motd) - } - function loginFinished(success, motd) { - console.log("loginFinished") - appWindow.closeLogin(success, motd) - } - function showSubscribeWizard() { - console.log("showSubscribeWizard cp=" + pageStack.currentPage + " busy=" + pageStack.busy) - appWindow.pageStack.push(subscribeWizardPage) - appWindow.listSubscriptions() - } - function showSubscribeGroups() { - console.log("showSubscribeGroups") - appWindow.pageStack.push(subscribeGroupsPage) - } - function askCredentials(sub, type) { - console.log("askCredentials " + sub + " " + type) - credentialsDialogPage.forumname = sub - credentialsDialogPage.credentialtype = type - credentialsDialogPage.resetForm() - pageStack.push(credentialsDialogPage) - } - function forumDetails(id, name, supportsLogin) { - console.log("forumDetails " + id + " " + name + " "+ supportsLogin) - forumCredentialsPage.forumid = id - forumCredentialsPage.forumname = name - forumCredentialsPage.supportsLogin = supportsLogin - forumCredentialsPage.forumDownloaded = true - appWindow.pageStack.push(forumCredentialsPage) - } - function subscribeFailed(msg) { - subscribeWizardPage.selectionMode = 0; - forumCredentialsPage.forumid = 0 - forumCredentialsPage.subscribeError = msg - } - function setBusy(busy) { - console.log("setBusy " + busy) - mainPage.busy = busy - } - function showStatusMessage(message) { - console.log("showStatusMessage " + message) - mainPage.message = message - statusmessagetimer.restart() - } - function showHaltScreen() { - console.log("showHaltScreen") - pageStack.clear() - pageStack.push(haltScreen, null, true) - } -} diff --git a/qtc_packaging/debian_harmattan/rules b/qtc_packaging/debian_harmattan/rules old mode 100755 new mode 100644 diff --git a/rpm/copy_to_obs.sh b/rpm/copy_to_obs.sh old mode 100755 new mode 100644 diff --git a/rpm/prepare_sources.sh b/rpm/prepare_sources.sh old mode 100755 new mode 100644 diff --git a/rpm/siilihai-mobile.yaml b/rpm/siilihai-mobile.yaml index dd65ad9..6b0b4c1 100644 --- a/rpm/siilihai-mobile.yaml +++ b/rpm/siilihai-mobile.yaml @@ -1,4 +1,4 @@ -Name: siilihai-mobile +Name: harbour-siilihai-mobile Summary: Siilihai Version: 2.0.1 Release: 1 @@ -21,11 +21,10 @@ Requires: - qt5-plugin-imageformat-jpeg - qt5-plugin-imageformat-ico - qt5-qtsvg-plugin-imageformat-svg -- qt5-qtgraphicaleffects Files: - /usr/share/icons/hicolor/86x86/apps - /usr/share/applications -- /usr/share/siilihai-mobile +- /usr/share/harbour-siilihai-mobile - /usr/bin - '%{_datadir}/icons/hicolor/86x86/apps/%{name}.png' - '%{_datadir}/applications/%{name}.desktop' diff --git a/siilihai-mobile.qrc b/siilihai-mobile.qrc deleted file mode 100644 index b2b0205..0000000 --- a/siilihai-mobile.qrc +++ /dev/null @@ -1,26 +0,0 @@ - - - qml/siilihai-mobile/AccountlessRegistration.qml - qml/siilihai-mobile/ButtonWithUnreadCount.qml - qml/siilihai-mobile/ConfirmUnsubscribe.qml - qml/siilihai-mobile/CredentialsDialogPage.qml - qml/siilihai-mobile/emblem-web.png - qml/siilihai-mobile/ForumCredentialsPage.qml - qml/siilihai-mobile/GroupListPage.qml - qml/siilihai-mobile/HaltScreen.qml - qml/siilihai-mobile/LoginWizardPage.qml - qml/siilihai-mobile/main.qml - qml/siilihai-mobile/MainPage.qml - qml/siilihai-mobile/MessageDisplay.qml - qml/siilihai-mobile/MessageListPage.qml - qml/siilihai-mobile/MessagePage.qml - qml/siilihai-mobile/RegistrationPage.qml - qml/siilihai-mobile/SubscribeGroupsPage.qml - qml/siilihai-mobile/SubscribeWizardPage.qml - qml/siilihai-mobile/ThreadListPage.qml - qml/siilihai-mobile/folder.png - qml/siilihai-mobile/folder-new.png - qml/siilihai-mobile-nocomponents/main.qml - qml/siilihai-mobile-nocomponents/Toolbar.qml - - diff --git a/siilihaimobile.pro b/siilihaimobile.pro index b87575d..61333d3 100644 --- a/siilihaimobile.pro +++ b/siilihaimobile.pro @@ -1,4 +1,4 @@ -TARGET=siilihai-mobile +TARGET=harbour-siilihai-mobile CONFIG += sailfishapp QT += core quick xml network svg @@ -34,9 +34,9 @@ SOURCES += main.cpp siilihaimobile.cpp HEADERS += siilihaimobile.h OTHER_FILES += \ - rpm/siilihai-mobile.spec \ - rpm/siilihai-mobile.yaml \ - siilihai-mobile.desktop + rpm/harbour-siilihai-mobile.spec \ + rpm/harbour-siilihai-mobile.yaml \ + harbour-siilihai-mobile.desktop OTHER_FILES += debian/rules \ debian/control\ @@ -126,8 +126,6 @@ OTHER_FILES += debian/rules \ QMAKE_CLEAN += *.o -#RESOURCES += siilihai-mobile.qrc - # Please do not modify the following two lines. Required for deployment. include(qtquick2applicationviewer/qtquick2applicationviewer.pri) qtcAddDeployment()