Added First version of MeeGo Harmattan port from pure QT to MTF.
authorRoman Moravcik <roman.moravcik@gmail.com>
Tue, 28 Jun 2011 14:46:03 +0000 (16:46 +0200)
committerRoman Moravcik <roman.moravcik@gmail.com>
Tue, 28 Jun 2011 14:46:03 +0000 (16:46 +0200)
15 files changed:
medard.pro
qtc_packaging/debian_harmattan/README [new file with mode: 0644]
qtc_packaging/debian_harmattan/changelog [new file with mode: 0644]
qtc_packaging/debian_harmattan/compat [new file with mode: 0644]
qtc_packaging/debian_harmattan/control [new file with mode: 0644]
qtc_packaging/debian_harmattan/copyright [new file with mode: 0644]
qtc_packaging/debian_harmattan/rules [new file with mode: 0755]
src/aboutdialog.cpp
src/aboutdialog.h
src/forecastwidget.cpp
src/forecastwidget.h
src/main.cpp
src/mainwindow.cpp
src/mainwindow.h
src/medarddownloader.cpp

index a92596f..c2bc3e4 100644 (file)
@@ -1,50 +1,55 @@
-# Add files and directories to ship with the application 
-# by adapting the examples below.
-# file1.source = myfile
-# dir1.source = mydir
-translations.source = \
-    translations/medard_cs.qm \
-    translations/medard_en.qm \
-    translations/medard_sk.qm
-
-maemo5 {
-    DEPLOYMENTFOLDERS = translations
-}
+TARGET = medard
+TEMPLATE = app
+VERSION = 0.2.0
 
 QT += network
 
-# Avoid auto screen rotation
-DEFINES += ORIENTATIONLOCK
-
-# Needs to be defined for Symbian
-DEFINES += NETWORKACCESS
-
-symbian:TARGET.UID3 = 0xE49E7B8A
-
-# If your application uses the Qt Mobility libraries, uncomment
-# the following lines and add the respective components to the 
-# MOBILITY variable. 
-# CONFIG += mobility
-# MOBILITY +=
-
 SOURCES += \
     src/forecastwidget.cpp \
     src/medarddownloader.cpp \
     src/mainwindow.cpp \
     src/main.cpp \
     src/aboutdialog.cpp
+
 HEADERS += \
     src/forecastwidget.h \
     src/medarddownloader.h \
     src/mainwindow.h \
     src/aboutdialog.h
+
 FORMS +=
 
+OTHER_FILES += \
+    qtc_packaging/debian_fremantle/rules \
+    qtc_packaging/debian_fremantle/README \
+    qtc_packaging/debian_fremantle/copyright \
+    qtc_packaging/debian_fremantle/control \
+    qtc_packaging/debian_fremantle/compat \
+    qtc_packaging/debian_fremantle/changelog \
+    qtc_packaging/debian_harmattan/rules \
+    qtc_packaging/debian_harmattan/README \
+    qtc_packaging/debian_harmattan/copyright \
+    qtc_packaging/debian_harmattan/control \
+    qtc_packaging/debian_harmattan/compat \
+    qtc_packaging/debian_harmattan/changelog
+
 TRANSLATIONS += \
     translations/medard_cs.ts \
     translations/medard_en.ts \
     translations/medard_sk.ts
 
-# Please do not modify the following two lines. Required for deployment.
-include(deployment.pri)
-qtcAddDeployment()
+unix:!symbian {
+    DEPLOYMENTFOLDERS = translations
+    maemo 5 {
+        DEFINES += Q_WS_MAEMO_5
+    } else {
+        DEFINES += Q_WS_MAEMO_6
+        CONFIG += meegotouch
+    }
+}
+
+translations.source = \
+    translations/medard_cs.qm \
+    translations/medard_en.qm \
+    translations/medard_sk.qm
+
diff --git a/qtc_packaging/debian_harmattan/README b/qtc_packaging/debian_harmattan/README
new file mode 100644 (file)
index 0000000..98a24cc
--- /dev/null
@@ -0,0 +1,6 @@
+The Debian Package medard
+----------------------------
+
+Comments regarding the Package
+
+ -- Roman Moravčík <xygromo@unknown>  Tue, 21 Jun 2011 12:36:33 +0200
diff --git a/qtc_packaging/debian_harmattan/changelog b/qtc_packaging/debian_harmattan/changelog
new file mode 100644 (file)
index 0000000..a47e7ea
--- /dev/null
@@ -0,0 +1,5 @@
+medard (0.0.0) unstable; urgency=low
+
+  * Initial Release.
+
+ -- Roman Moravčík <xygromo@unknown>  Tue, 21 Jun 2011 12:36:33 +0200
diff --git a/qtc_packaging/debian_harmattan/compat b/qtc_packaging/debian_harmattan/compat
new file mode 100644 (file)
index 0000000..7f8f011
--- /dev/null
@@ -0,0 +1 @@
+7
diff --git a/qtc_packaging/debian_harmattan/control b/qtc_packaging/debian_harmattan/control
new file mode 100644 (file)
index 0000000..cda8777
--- /dev/null
@@ -0,0 +1,15 @@
+Source: medard
+Section: user/other
+Priority: optional
+Maintainer: Roman Moravčík <xygromo@unknown>
+Build-Depends: debhelper (>= 5), libqt4-dev
+Standards-Version: 3.7.3
+Homepage: <insert the upstream URL, if relevant>
+
+Package: medard
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: <insert up to 60 chars description>
+ <insert long description, indented with spaces>
+XSBC-Maemo-Display-Name: medard
+XB-Maemo-Icon-26: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAOxAAADsQBlSsOGwAAF0NJREFUaIGVmmmMZNd133/3vqVeLV1d1dVdve8z3bMPh5wRKXJoUpQtOSIcyYg/JDYCJJDywRJsJDCQxIIFxJYjwzGCBHASwZSSDwGkxIGTWFDk0FooUdJw0Qw5w+EsPdP7UmvXvr96792bD9XTFKlYQe6XQr337n3/e+655/8/5z7B/6P93a9+bio0HH/RjoWuovWL9Uw5FU3FMR0LaUiyt7aZvLiAFalhR7p0qxME3qDv4XcMxlMfQgUBfbdN2ljAVPbf+K6aVcTDKwv0nkZ8WWnvW//p9z+V/Xn4xM+7+fmtlz7eKtRfHppMgh5c83p9DNNAmgZCCipbBdz2A868OIZG47tRmrk5ALoPo0T2n0FLn5ifJO4nHg3zf22HoQy+6L//otbf+JefXv7U/9cEPr/1VU8IzPePoxFCHP++N4IiknoXEIRiFqDoVifo1UfRKGgOIW5cIeYnGfKSaD7Q/6jlcneZnDhLTRVZO3iF+dUnEdIgu32bmeVLeJ7ro9Vn/+gzJ7/y0/3kBwf6zR986YuHDw5MAN/1qGwVaBXrCCmp7R9S3swReD6tYp3KToHKdgEhBTuvZdl89QCBxHRaVHYOaWQqyIiL22+wvvYDgqAPCIbj22Szr6GUol7PUiptk0zOIST4jQ6Lp54BoNuukZ5ZxfdcpBBmv9d56eeuwOe3v/JFNL+Xe2ebqceWBjM0DXZeu8f8U6dQgaLf6mHYJmbIAgE6UIwsrSEQdGo9w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1Mv4UO9QjG+jB1C6YPMEyfQeFWYOJT3W3gFxTzJyzyLQeHFg5dzFCXaHoaaWhmV65AYAxOtSdziK752T/41KX7R7jf3/7eb/zHLz7/3K//HipDq1UgFH+Kth6UH8peBisSQWsFAqoH25xKPAtIypUtIrOTNJbfhLltlLdJYs5CGLD7+gOWf2GaILDRSFLePqvOBjE6XP9WidlZyeoFm//5Tc35X5mhzDQZptl7ExIzF/D7HghNp9zk317+nfdhNj84gf/ytU9/QY3qf3723CfMetfCGdlFo5FCIpCDMiODvFc6NsVYBqtt0h3zCBbewlq9R3Rsn2aujukclSalgdIGwggYpci8sc84JQwUSycMFk6a5DM+S5MKi4DBuYzASVRRarBiAun3m73PfhCv8cELAE/9s6f/InQlP9NJbZwKzXURIxWYzCMPpxHaIO3NUK7vEB+fQKfzBCfv4Tx1nfiJe8SSOZQwkKZE2hKBwAwZ2FGbmGiRpEKUOmH69LRNJKS482qF5y91iE7EKFRNvPAwDRIYliSSatGtjXzDGc3+2r869YW//iDWn/u1CsDnfvzHU4mp1IsIfXXnjZsvnnjudEoqQfPgLabSFZYX+0RoUNrrUj/sM/TERQIEe40kQkIoZiMQ5O+PMX0qz7jIwO4G1UOPM5eHyHz7IWN2navPSd7JptnOmuX04+m9vLH85V5Hfesz0f/6cz+3+T/98KG5e2OWsgAAAABJRU5ErkJggg==
diff --git a/qtc_packaging/debian_harmattan/copyright b/qtc_packaging/debian_harmattan/copyright
new file mode 100644 (file)
index 0000000..77ed26a
--- /dev/null
@@ -0,0 +1,40 @@
+This package was debianized by Roman Moravčík <xygromo@unknown> on
+Tue, 21 Jun 2011 12:36:33 +0200.
+
+It was downloaded from <url://example.com>
+
+Upstream Author(s):
+
+    <put author's name and email here>
+    <likewise for another author>
+
+Copyright:
+
+    <Copyright (C) YYYY Name OfAuthor>
+    <likewise for another author>
+
+License:
+
+    This package is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    This package is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this package; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL'.
+
+The Debian packaging is (C) 2011, Roman Moravčík <xygromo@unknown> and
+is licensed under the GPL, see above.
+
+
+# Please also look if there are files or directories which have a
+# different copyright/license attached and list them here.
diff --git a/qtc_packaging/debian_harmattan/rules b/qtc_packaging/debian_harmattan/rules
new file mode 100755 (executable)
index 0000000..6373954
--- /dev/null
@@ -0,0 +1,91 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was added by Craig Small in version 0.37 of dh-make.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+
+
+
+
+configure: configure-stamp
+configure-stamp:
+       dh_testdir
+       # qmake PREFIX=/usr# Uncomment this line for use without Qt Creator
+
+       touch configure-stamp
+
+
+build: build-stamp
+
+build-stamp: configure-stamp  
+       dh_testdir
+
+       # Add here commands to compile the package.
+       # $(MAKE) # Uncomment this line for use without Qt Creator
+       #docbook-to-man debian/medard.sgml > medard.1
+
+       touch $@
+
+clean: 
+       dh_testdir
+       dh_testroot
+       rm -f build-stamp configure-stamp
+
+       # Add here commands to clean up after the build process.
+       $(MAKE) clean
+
+       dh_clean 
+
+install: build
+       dh_testdir
+       dh_testroot
+       dh_clean -k 
+       dh_installdirs
+
+       # Add here commands to install the package into debian/medard.
+       $(MAKE) INSTALL_ROOT="$(CURDIR)"/debian/medard install
+
+
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+       dh_testdir
+       dh_testroot
+       dh_installchangelogs 
+       dh_installdocs
+       dh_installexamples
+#      dh_install
+#      dh_installmenu
+#      dh_installdebconf       
+#      dh_installlogrotate
+#      dh_installemacsen
+#      dh_installpam
+#      dh_installmime
+#      dh_python
+#      dh_installinit
+#      dh_installcron
+#      dh_installinfo
+       dh_installman
+       dh_link
+       dh_strip
+       dh_compress
+       dh_fixperms
+#      dh_perl
+#      dh_makeshlibs
+       dh_installdeb
+       # dh_shlibdeps # Uncomment this line for use without Qt Creator
+       dh_gencontrol
+       dh_md5sums
+       dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install configure
index cc82887..2231bd0 100644 (file)
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
 
+#ifdef Q_WS_MAEMO_6
+#include <MLabel>
+#endif
+
 #include <QtGui>
 
 #include "aboutdialog.h"
 
+#ifdef Q_WS_MAEMO_6
+AboutDialog::AboutDialog(QGraphicsItem *parent) : MApplicationPage(parent)
+{
+    setAttribute(Qt::WA_LockPortraitOrientation, true);
+    setWindowTitle(tr("About"));
+    setPannable(false);
+
+    QGraphicsLinearLayout *layout = new QGraphicsLinearLayout(Qt::Vertical);
+    centralWidget()->setLayout(layout);
+
+    MLabel *application = new MLabel();
+    application->setText("Medard 0.1");
+//    application->setAlignment(Qt::AlignCenter);
+    layout->addItem(application);
+
+    MLabel *applicationCopyright = new MLabel();
+    applicationCopyright->setText(tr("Copyright(c) 2011 Roman Moravcik"));
+//    applicationCopyright->setAlignment(Qt::AlignCenter);
+    layout->addItem(applicationCopyright);
+
+    MLabel *weatherDataCopyright = new MLabel();
+    weatherDataCopyright->setText(tr("\n"
+                                  "Weather data:\n"
+                                  "Project MEDARD, Institute of Computer Science,\n"
+                                  "Academy of Sciences of the Czech Republic, Prague\n"
+                                  "\n"
+                                  "Copyright(c) Institute of Computer Science AS CR 2003-2009.\n"
+                                  "MM5: PSU/NCAR, USA (c) CAMx: EVNIRON Corp., USA"));
+    layout->addItem(weatherDataCopyright);
+}
+#else
 AboutDialog::AboutDialog(QDialog *parent) : QDialog(parent)
 {
     setWindowTitle(tr("About"));
@@ -55,3 +90,4 @@ AboutDialog::AboutDialog(QDialog *parent) : QDialog(parent)
     layout->addWidget(weatherDataCopyright);
 
 }
+#endif
index 109f369..d81f45e 100644 (file)
 #ifndef ABOUTDIALOG_H
 #define ABOUTDIALOG_H
 
+#ifdef Q_WS_MAEMO_6
+#include <MApplicationPage>
+#else
 #include <QDialog>
+#endif
 
+#ifdef Q_WS_MAEMO_6
+class AboutDialog : public MApplicationPage
+#else
 class AboutDialog : public QDialog
+#endif
 {
     Q_OBJECT
 
 public:
+#ifdef Q_WS_MAEMO_6
+    AboutDialog(QGraphicsItem *parent = 0);
+#else
     AboutDialog(QDialog *parent = 0);
+#endif
 };
 
 #endif // ABOUTDIALOG_H
index 82ae3cb..e733544 100644 (file)
 
 #include "forecastwidget.h"
 
+#ifdef Q_WS_MAEMO_6
+ForecastWidget::ForecastWidget(QGraphicsWidget *parent) : QGraphicsWidget(parent)
+#else
 ForecastWidget::ForecastWidget(QWidget *parent) : QWidget(parent)
+#endif
 {
     m_filename.clear();
     m_error = false;
@@ -41,6 +45,32 @@ void ForecastWidget::clearImage(bool error)
     update();
 }
 
+#ifdef Q_WS_MAEMO_6
+void ForecastWidget::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
+{
+    Q_UNUSED(widget);
+    Q_UNUSED(option);
+
+    painter->setRenderHint(QPainter::Antialiasing);
+
+    QRect widgetArea(rect().x(), rect().y(), rect().width(), 369);
+
+    painter->setPen(QColor(0, 0, 0));
+    painter->setBrush(QColor(255, 255, 255));
+    painter->drawRect(widgetArea);
+
+    if (m_error) {
+        painter->drawText(widgetArea, Qt::AlignCenter, tr("Download failed!"));
+    } else {
+        if (!m_filename.isEmpty()) {
+            QImage image(m_filename);
+            painter->drawImage(widgetArea, image);
+        } else {
+            painter->drawText(widgetArea, Qt::AlignCenter, tr("Downloading image..."));
+        }
+    }
+}
+#else
 void ForecastWidget::paintEvent(QPaintEvent * /* event */)
 {
     QPainter painter(this);
@@ -63,3 +93,4 @@ void ForecastWidget::paintEvent(QPaintEvent * /* event */)
         }
     }
 }
+#endif
index e498582..f352a2a 100644 (file)
 #ifndef FORECASTWIDGET_H
 #define FORECASTWIDGET_H
 
+#ifdef Q_WS_MAEMO_6
+#include <QGraphicsWidget>
+#else
 #include <QWidget>
+#endif
+
 #include <QString>
 
+#ifdef Q_WS_MAEMO_6
+class ForecastWidget : public QGraphicsWidget
+#else
 class ForecastWidget : public QWidget
+#endif
 {
     Q_OBJECT
 
 public:
+#ifdef Q_WS_MAEMO_6
+    ForecastWidget(QGraphicsWidget *parent = 0);
+
+    void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget);
+#else
     ForecastWidget(QWidget *parent = 0);
+#endif
 
     void setImage(const QString &filename);
     void clearImage(bool error);
 
+#ifdef Q_WS_MAEMO_5
 protected:
     void paintEvent(QPaintEvent *event);
+#endif
 
 private:
     QString m_filename;
index 8ae1d03..539b54e 100644 (file)
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
 
+#ifdef Q_WS_MAEMO_6
+#include <MApplication>
+#include <MApplicationWindow>
+#else
 #include <QApplication>
+#endif
+
 #include <QTranslator>
 #include <QLocale>
 
 
 int main(int argc, char *argv[])
 {
+#ifdef Q_WS_MAEMO_6
+    MApplication app(argc, argv);
+#else
     QApplication app(argc, argv);
+#endif
 
     QString translatorFileName = "medard_" + QLocale::system().name();
     QTranslator translator;
     if (translator.load(translatorFileName, "/opt/usr/share/medard/"))
         app.installTranslator(&translator);
 
+#ifdef Q_WS_MAEMO_6
+    MApplicationWindow window;
+    MainWindow page;
+    page.appear(&window);
+    window.show();
+#else
     MainWindow window;
     window.showMaximized();
+#endif
 
     return app.exec();
 }
index bf318f5..0253c38 100644 (file)
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
 
+#ifdef Q_WS_MAEMO_6
+#include <MLayout>
+#include <MAction>
+#include <MWidgetAction>
+#include <MComboBox>
+#endif
+
 #include <QtGui>
 #include <QSettings>
 
 #include "aboutdialog.h"
 #include "mainwindow.h"
 
+#ifdef Q_WS_MAEMO_6
+MainWindow::MainWindow(QGraphicsItem *parent) : MApplicationPage(parent)
+{
+    m_downloader = new MedardDownloader();
+
+    connect(m_downloader, SIGNAL(downloadFinished(const QString &, const QDateTime &)), this,
+            SLOT(downloadedFinished(const QString &, const QDateTime &)));
+    connect(m_downloader, SIGNAL(downloadFailed()), this, SLOT(downloadFailed()));
+
+    m_forecast = new ForecastWidget();
+    m_forecast->setPreferredSize(m_downloader->imageSize());
+
+    m_forecastTypeLabel = new MLabel();
+    m_forecastTypeLabel->setAlignment(Qt::AlignCenter);
+    m_forecastTypeLabel->setPreferredSize(220, 80);
+
+    m_forecastInitialDateLabel = new MLabel();
+    m_forecastInitialDateLabel->setAlignment(Qt::AlignCenter);
+//    m_forecastInitialDateLabel->setDisabled(true);
+
+    m_forecastDateLabel = new MLabel();
+    m_forecastDateLabel->setAlignment(Qt::AlignCenter);
+
+    m_downloadRetryButton = new MButton(tr("Download again"));
+    m_downloadRetryButton->setPreferredWidth(220);
+
+    connect(m_downloadRetryButton, SIGNAL(clicked()), this, SLOT(downloadAgainClicked()));
+
+    m_minusDayButton = new MButton(tr("-1 d"));
+    m_minusDayButton->setPreferredWidth(50);
+    m_plusDayButton = new MButton(tr("+1 d"));
+    m_plusDayButton->setPreferredWidth(50);
+    m_minusHourButton = new MButton(tr("-1 h"));
+    m_minusHourButton->setPreferredWidth(50);
+    m_plusHourButton = new MButton(tr("+1 h"));
+    m_plusHourButton->setPreferredWidth(50);
+
+    connect(m_minusDayButton, SIGNAL(clicked()), this, SLOT(minusDayClicked()));
+    connect(m_plusDayButton, SIGNAL(clicked()), this, SLOT(plusDayClicked()));
+    connect(m_minusHourButton, SIGNAL(clicked()), this, SLOT(minusHourClicked()));
+    connect(m_plusHourButton, SIGNAL(clicked()), this, SLOT(plusHourClicked()));
+
+    setupUi();
+    setupMenu();
+
+    loadSettings();
+}
+#else
 MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent)
 {
     m_downloader = new MedardDownloader();
@@ -64,12 +119,46 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent)
 
     loadSettings();
 }
+#endif
 
 MainWindow::~MainWindow()
 {
     delete m_downloader;
 }
 
+#ifdef Q_WS_MAEMO_6
+void MainWindow::setupUi()
+{
+    setAttribute(Qt::WA_LockPortraitOrientation, true);
+    setWindowTitle(tr("Medard"));
+    setPannable(false);
+
+    QGraphicsLinearLayout *mainLayout = new QGraphicsLinearLayout(Qt::Horizontal);
+    centralWidget()->setLayout(mainLayout);
+
+    mainLayout->addItem(m_forecast);
+
+    QGraphicsLinearLayout *layout = new QGraphicsLinearLayout(Qt::Vertical);
+    mainLayout->addItem(layout);
+
+    layout->addItem(m_forecastTypeLabel);
+    layout->addItem(m_forecastDateLabel);
+    layout->addItem(m_forecastInitialDateLabel);
+    layout->addItem(m_downloadRetryButton);
+
+    QGraphicsLinearLayout *dayNavigationBox = new QGraphicsLinearLayout(Qt::Horizontal);
+    dayNavigationBox->addItem(m_minusDayButton);
+    dayNavigationBox->addItem(m_plusDayButton);
+    layout->addItem(dayNavigationBox);
+
+    QGraphicsLinearLayout *hourNavigationBox = new QGraphicsLinearLayout(Qt::Horizontal);
+    hourNavigationBox->addItem(m_minusHourButton);
+    hourNavigationBox->addItem(m_plusHourButton);
+    layout->addItem(hourNavigationBox);
+
+    hideNavigationButtons(false);
+}
+#else
 void MainWindow::setupUi()
 {
 #ifdef Q_WS_MAEMO_5
@@ -110,7 +199,57 @@ void MainWindow::setupUi()
 
     hideNavigationButtons(false);
 }
+#endif
 
+#ifdef Q_WS_MAEMO_6
+void MainWindow::setupMenu()
+{
+    QStringList domainsList;
+    domainsList << tr("Europe") << tr("Czech Republic");
+
+    MWidgetAction *domainAction = new MWidgetAction(centralWidget());
+    domainAction->setLocation(MAction::ApplicationMenuLocation);
+
+    m_domainComboBox = new MComboBox;
+    m_domainComboBox->setTitle(tr("Domain"));
+    m_domainComboBox->setIconVisible(false);
+    m_domainComboBox->addItems(domainsList);
+    domainAction->setWidget(m_domainComboBox);
+    addAction(domainAction);
+    connect(m_domainComboBox, SIGNAL(activated(int)), this, SLOT(forecastDomainChanged(int)));
+
+    MAction *seaLevelPreasureAction = new MAction("icon-m-weather-cloudy", tr("Sea Level Pressure"), this);
+    seaLevelPreasureAction->setLocation(MAction::ToolBarLocation);
+    addAction(seaLevelPreasureAction);
+    connect(seaLevelPreasureAction, SIGNAL(triggered()), this, SLOT(seaLevelPreasureMenuClicked()));
+
+    MAction *precipitationAction = new MAction("icon-m-weather-rain", tr("Precipitation"), this);
+    precipitationAction->setLocation(MAction::ToolBarLocation);
+    addAction(precipitationAction);
+    connect(precipitationAction, SIGNAL(triggered()), this, SLOT(precipitationMenuClicked()));
+
+    MAction *windVelocityAction = new MAction("icon-m-weather-stormy", tr("Wind Velocity"), this);
+    windVelocityAction->setLocation(MAction::ToolBarLocation);
+    addAction(windVelocityAction);
+    connect(windVelocityAction, SIGNAL(triggered()), this, SLOT(windVelocityMenuClicked()));
+
+    MAction *cloudinessAction = new MAction("icon-m-weather-partly-sunny", tr("Cloudinese"), this);
+    cloudinessAction->setLocation(MAction::ToolBarLocation);
+    addAction(cloudinessAction);
+    connect(cloudinessAction, SIGNAL(triggered()), this, SLOT(cloudinessMenuClicked()));
+
+    MAction *temperatureAction = new MAction("icon-m-weather-hot", tr("Temperature"), this);
+    temperatureAction->setLocation(MAction::ToolBarLocation);
+    addAction(temperatureAction);
+    connect(temperatureAction, SIGNAL(triggered()), this, SLOT(temperatureMenuClicked()));
+
+    MAction *aboutAction = new MAction(this);
+    aboutAction->setText(tr("About"));
+    aboutAction->setLocation(MAction::ApplicationMenuLocation);
+    addAction(aboutAction);
+    connect(aboutAction, SIGNAL(triggered()), this, SLOT(aboutMenuClicked()));
+}
+#else
 void MainWindow::setupMenu()
 {
     QMenuBar *menu = new QMenuBar();
@@ -151,6 +290,7 @@ void MainWindow::setupMenu()
     menu->addAction(aboutAction);
     connect(aboutAction, SIGNAL(triggered()), this, SLOT(aboutMenuClicked()));
 }
+#endif
 
 void MainWindow::loadSettings()
 {
@@ -160,7 +300,11 @@ void MainWindow::loadSettings()
     int forecastType = settings.value("ForecastType").toInt();
 
     m_downloader->setForecastDomain((MedardDownloader::ForecastDomain) forecastDomain);
+#ifdef Q_WS_MAEMO_6
+    m_domainComboBox->setCurrentIndex(forecastDomain);
+#else
     m_domainActionGroup->actions().at(forecastDomain)->setChecked(true);
+#endif
 
     switch ((MedardDownloader::ForecastType) forecastType) {
         case MedardDownloader::SeaLevelPressure:
@@ -211,25 +355,25 @@ void MainWindow::hideNavigationButtons(bool showRetryButton)
 void MainWindow::updateNavigationButtons()
 {
     if ((m_downloader->forecastDateOffset() - 24) < m_downloader->minForecastDateOffset()) {
-        m_minusDayButton->setDisabled(true);
-        m_plusDayButton->setDisabled(false);
+//        m_minusDayButton->setDisabled(true);
+//        m_plusDayButton->setDisabled(false);
     } else if ((m_downloader->forecastDateOffset() + 24) > m_downloader->maxForecastDateOffset()) {
-        m_minusDayButton->setDisabled(false);
-        m_plusDayButton->setDisabled(true);
+//        m_minusDayButton->setDisabled(false);
+//        m_plusDayButton->setDisabled(true);
     } else {
-        m_minusDayButton->setDisabled(false);
-        m_plusDayButton->setDisabled(false);
+//        m_minusDayButton->setDisabled(false);
+//        m_plusDayButton->setDisabled(false);
     }
 
     if ((m_downloader->forecastDateOffset() - 1) < m_downloader->minForecastDateOffset()) {
-        m_minusHourButton->setDisabled(true);
-        m_plusHourButton->setDisabled(false);
+//        m_minusHourButton->setDisabled(true);
+//        m_plusHourButton->setDisabled(false);
     } else if ((m_downloader->forecastDateOffset() + 1) > m_downloader->maxForecastDateOffset()) {
-        m_minusHourButton->setDisabled(false);
-        m_plusHourButton->setDisabled(true);
+//        m_minusHourButton->setDisabled(false);
+//        m_plusHourButton->setDisabled(true);
     } else {
-        m_minusHourButton->setDisabled(false);
-        m_plusHourButton->setDisabled(false);
+//        m_minusHourButton->setDisabled(false);
+//        m_plusHourButton->setDisabled(false);
     }
 }
 
@@ -261,7 +405,11 @@ void MainWindow::temperatureMenuClicked()
 void MainWindow::aboutMenuClicked()
 {
     AboutDialog *dialog = new AboutDialog();
+#ifdef Q_WS_MAEMO_6
+    dialog->appear(scene(), MSceneWindow::DestroyWhenDismissed);
+#else
     dialog->exec();
+#endif
 }
 
 void MainWindow::downloadAgainClicked()
@@ -310,6 +458,22 @@ void MainWindow::forecastDateOffsetChanged(int offset)
     m_downloader->downloadImage();
 }
 
+#ifdef Q_WS_MAEMO_6
+void MainWindow::forecastDomainChanged(int index)
+{
+    m_forecast->clearImage(false);
+
+    if (index == 0)
+        m_downloader->setForecastDomain(MedardDownloader::Europe);
+    else
+        m_downloader->setForecastDomain(MedardDownloader::CzechRepublic);
+
+    m_downloader->downloadImage();
+
+    QSettings settings;
+    settings.setValue("ForecastDomain", index);
+}
+#else
 void MainWindow::forecastDomainChanged(QAction *action)
 {
     int forecastDomain = m_domainActionGroup->actions().indexOf(action);
@@ -326,6 +490,7 @@ void MainWindow::forecastDomainChanged(QAction *action)
     QSettings settings;
     settings.setValue("ForecastDomain", forecastDomain);
 }
+#endif
 
 void MainWindow::downloadedFinished(const QString &filename, const QDateTime &date)
 {
index c4f224e..499c69a 100644 (file)
 #ifndef MAINWINDOW_H
 #define MAINWINDOW_H
 
+#ifdef Q_WS_MAEMO_6
+#include <MApplicationPage>
+#include <MLabel>
+#include <MButton>
+#include <MComboBox>
+#else
 #include <QMainWindow>
 #include <QActionGroup>
 #include <QLabel>
 #include <QPushButton>
+#endif
 
 #include "forecastwidget.h"
 #include "medarddownloader.h"
 
+#ifdef Q_WS_MAEMO_6
+class MainWindow : public MApplicationPage
+#else
 class MainWindow : public QMainWindow
+#endif
 {
     Q_OBJECT
 
 public:
+#ifdef Q_WS_MAEMO_6
+    MainWindow(QGraphicsItem *parent = 0);
+#else
     MainWindow(QWidget *parent = 0);
+#endif
     virtual ~MainWindow();
 
 private slots:
@@ -53,7 +68,11 @@ private slots:
 
     void forecastTypeChanged(const QString label, MedardDownloader::ForecastType type);
     void forecastDateOffsetChanged(int offset);
+#if Q_WS_MAEMO_6
+    void forecastDomainChanged(int index);
+#else
     void forecastDomainChanged(QAction *action);
+#endif
 
     void downloadedFinished(const QString &filename, const QDateTime &date);
     void downloadFailed();
@@ -71,6 +90,20 @@ private:
     MedardDownloader *m_downloader;
 
     ForecastWidget *m_forecast;
+#if Q_WS_MAEMO_6
+    MLabel *m_forecastTypeLabel;
+    MLabel *m_forecastInitialDateLabel;
+    MLabel *m_forecastDateLabel;
+
+    MButton *m_downloadRetryButton;
+
+    MButton *m_minusDayButton;
+    MButton *m_plusDayButton;
+    MButton *m_minusHourButton;
+    MButton *m_plusHourButton;
+
+    MComboBox *m_domainComboBox;
+#else
     QLabel *m_forecastTypeLabel;
     QLabel *m_forecastInitialDateLabel;
     QLabel *m_forecastDateLabel;
@@ -83,6 +116,8 @@ private:
     QPushButton *m_plusHourButton;
 
     QActionGroup *m_domainActionGroup;
+#endif
+
 };
 
 #endif // MAINWINDOW_H
index 07dc798..a2ea87a 100644 (file)
 #define MAX_OFFSET 72
 
 #define IMAGE_WIDTH 556
+#ifdef Q_WS_MAEMO_6
+#define IMAGE_HEIGHT 369
+#else
 #define IMAGE_HEIGHT 408
+#endif
 
 #define MAX_DOWNLOAD_RETRIES 3
 #define RETRY_TIMEOUT 5000