Locations selectors and edit window implemented.
[ptas] / zouba / src / addressdialog.cpp
index a5d7bd8..eba193d 100644 (file)
 #include <QLineEdit>\r
 #include <QPushButton>\r
 #include <QXmlStreamReader>\r
-#include <QMaemo5InformationBox>\r
 #include <QListWidget>\r
 #include <QDebug>\r
+#ifdef Q_WS_MAEMO_5\r
+#include <QMaemo5InformationBox>\r
+#endif\r
 \r
 AddressDialog::AddressDialog(QWidget *parent, const Location *location) :\r
     QDialog(parent), m_reply(0), m_current(0)\r
@@ -117,7 +119,9 @@ void AddressDialog::searchFinished()
                     QString errorMessage("Unknown category: ");\r
                     errorMessage.append(category);\r
                     qDebug() << errorMessage;\r
+#ifdef Q_WS_MAEMO_5\r
                     QMaemo5InformationBox::information(this, errorMessage);\r
+#endif\r
                 }\r
             }\r
 \r
@@ -132,13 +136,17 @@ void AddressDialog::searchFinished()
 \r
     qDebug() << xml.errorString();\r
     if ( xml.hasError() || responseHasError ) {\r
+#ifdef Q_WS_MAEMO_5\r
         QMaemo5InformationBox::information(this, "Invalid response received from Ytv.");\r
+#endif\r
         qDebug() << "Invalid response received from Ytv";\r
     } else {\r
         // Case where no addresses are found.\r
         if (m_places.size() + m_roadNames.size() + m_stops.size() == 0)\r
         {\r
+#ifdef Q_WS_MAEMO_5\r
             QMaemo5InformationBox::information(this, "No addresses were found with the given address.");\r
+#endif\r
         }\r
         // Case where addresses are found.\r
         else        {\r