diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2011-10-18 09:54:31 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-10-18 15:47:49 +0200 |
commit | 87274e272d2a854563066489e20d019b4e6320de (patch) | |
tree | d01e71403a41db3ca2b83599fcc7036d79d7a13e /examples/xml | |
parent | 08e24858607d1b1483fb1faa54effa957501cfbb (diff) |
QtBase examples: Remove Maemo/Symbian-specific code.
- Maemo/Symbian are no longer supported and QWidget-based examples
are no longer supposed to run on mobile platforms, so, remove any
Maemo/Symbian or mobile-specific code from source files and
profiles.
- Remove Maemo/Symbian vibration examples.
- Change Q_WS_MAC/WIN to Q_OS_MAC/WIN where appropriate.
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Change-Id: I488a0adadb98934567aa6416206a80465c9c3a81
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Diffstat (limited to 'examples/xml')
-rw-r--r-- | examples/xml/dombookmarks/dombookmarks.pro | 10 | ||||
-rw-r--r-- | examples/xml/dombookmarks/main.cpp | 4 | ||||
-rw-r--r-- | examples/xml/dombookmarks/mainwindow.cpp | 18 | ||||
-rw-r--r-- | examples/xml/htmlinfo/htmlinfo.pro | 10 | ||||
-rw-r--r-- | examples/xml/rsslisting/main.cpp | 4 | ||||
-rw-r--r-- | examples/xml/rsslisting/rsslisting.cpp | 19 | ||||
-rw-r--r-- | examples/xml/rsslisting/rsslisting.h | 13 | ||||
-rw-r--r-- | examples/xml/rsslisting/rsslisting.pro | 13 | ||||
-rw-r--r-- | examples/xml/saxbookmarks/main.cpp | 4 | ||||
-rw-r--r-- | examples/xml/saxbookmarks/mainwindow.cpp | 9 | ||||
-rw-r--r-- | examples/xml/saxbookmarks/saxbookmarks.pro | 10 | ||||
-rw-r--r-- | examples/xml/streambookmarks/main.cpp | 3 | ||||
-rw-r--r-- | examples/xml/streambookmarks/mainwindow.cpp | 18 | ||||
-rw-r--r-- | examples/xml/streambookmarks/streambookmarks.pro | 8 | ||||
-rw-r--r-- | examples/xml/xml.pro | 3 | ||||
-rw-r--r-- | examples/xml/xmlstreamlint/xmlstreamlint.pro | 3 |
16 files changed, 1 insertions, 148 deletions
diff --git a/examples/xml/dombookmarks/dombookmarks.pro b/examples/xml/dombookmarks/dombookmarks.pro index 21eb5c071f..9c1746a67f 100644 --- a/examples/xml/dombookmarks/dombookmarks.pro +++ b/examples/xml/dombookmarks/dombookmarks.pro @@ -11,19 +11,9 @@ sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS dombookmarks.pro *.xbel sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/dombookmarks INSTALLS += target sources -symbian: CONFIG += qt_example - -symbian: { - CONFIG += qt_example - addFiles.sources = frank.xbel jennifer.xbel - addFiles.path = files - DEPLOYMENT += addFiles -} - wince*: { addFiles.files = frank.xbel jennifer.xbel addFiles.path = "\\My Documents" DEPLOYMENT += addFiles } -maemo5: CONFIG += qt_example diff --git a/examples/xml/dombookmarks/main.cpp b/examples/xml/dombookmarks/main.cpp index 6a3bb8c1a9..d23af14af2 100644 --- a/examples/xml/dombookmarks/main.cpp +++ b/examples/xml/dombookmarks/main.cpp @@ -46,11 +46,7 @@ int main(int argc, char *argv[]) { QApplication app(argc, argv); MainWindow mainWin; -#if defined(Q_OS_SYMBIAN) - mainWin.showMaximized(); -#else mainWin.show(); -#endif mainWin.open(); return app.exec(); diff --git a/examples/xml/dombookmarks/mainwindow.cpp b/examples/xml/dombookmarks/mainwindow.cpp index 0c8568332e..0c3ceafc88 100644 --- a/examples/xml/dombookmarks/mainwindow.cpp +++ b/examples/xml/dombookmarks/mainwindow.cpp @@ -59,15 +59,6 @@ MainWindow::MainWindow() void MainWindow::open() { -#if defined(Q_OS_SYMBIAN) - // Look for bookmarks on the same drive where the application is installed to, - // if drive is not read only. QDesktopServices::DataLocation does this check, - // and returns writable drive. - QString bookmarksFolder = - QDesktopServices::storageLocation(QDesktopServices::DataLocation).left(1); - bookmarksFolder.append(":/Data/qt/saxbookmarks"); - QDir::setCurrent(bookmarksFolder); -#endif QString fileName = QFileDialog::getOpenFileName(this, tr("Open Bookmark File"), QDir::currentPath(), @@ -90,15 +81,6 @@ void MainWindow::open() void MainWindow::saveAs() { -#if defined(Q_OS_SYMBIAN) - // Look for bookmarks on the same drive where the application is installed to, - // if drive is not read only. QDesktopServices::DataLocation does this check, - // and returns writable drive. - QString bookmarksFolder = - QDesktopServices::storageLocation(QDesktopServices::DataLocation).left(1); - bookmarksFolder.append(":/Data/qt/saxbookmarks"); - QDir::setCurrent(bookmarksFolder); -#endif QString fileName = QFileDialog::getSaveFileName(this, tr("Save Bookmark File"), QDir::currentPath(), diff --git a/examples/xml/htmlinfo/htmlinfo.pro b/examples/xml/htmlinfo/htmlinfo.pro index 7a58ed35a0..bf2387831c 100644 --- a/examples/xml/htmlinfo/htmlinfo.pro +++ b/examples/xml/htmlinfo/htmlinfo.pro @@ -5,7 +5,7 @@ RESOURCES = resources.qrc win32: CONFIG += console -wince*|symbian:{ +wince*:{ htmlfiles.files = *.html htmlfiles.path = . DEPLOYMENT += htmlfiles @@ -16,11 +16,3 @@ target.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/htmlinfo sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS *.html htmlinfo.pro sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/htmlinfo INSTALLS += target sources - -symbian { - TARGET.UID3 = 0xA000C609 - CONFIG += qt_example -} -maemo5: CONFIG += qt_example - -symbian: warning(This example does not work on Symbian platform) diff --git a/examples/xml/rsslisting/main.cpp b/examples/xml/rsslisting/main.cpp index 7d2b4ca10f..a646c602db 100644 --- a/examples/xml/rsslisting/main.cpp +++ b/examples/xml/rsslisting/main.cpp @@ -58,10 +58,6 @@ int main(int argc, char **argv) { QApplication app(argc, argv); RSSListing *rsslisting = new RSSListing; -#if defined(Q_OS_SYMBIAN) - rsslisting->showMaximized(); -#else rsslisting->show(); -#endif return app.exec(); } diff --git a/examples/xml/rsslisting/rsslisting.cpp b/examples/xml/rsslisting/rsslisting.cpp index ba9ff28072..4fa160f9ed 100644 --- a/examples/xml/rsslisting/rsslisting.cpp +++ b/examples/xml/rsslisting/rsslisting.cpp @@ -74,23 +74,6 @@ its operation, and also allows very large data sources to be read. RSSListing::RSSListing(QWidget *parent) : QWidget(parent), currentReply(0) { -#ifdef Q_OS_SYMBIAN - // Set Internet Access Point - QNetworkConfigurationManager manager; - const bool canStartIAP = manager.capabilities() & QNetworkConfigurationManager::CanStartAndStopInterfaces; - - // Is there default access point, use it - QNetworkConfiguration cfg = manager.defaultConfiguration(); - if (!cfg.isValid() || !canStartIAP) { - // Available Access Points not found - QMessageBox::warning(this, "Error", "No access point"); - return; - } - - m_session = new QNetworkSession(cfg); - m_session->open(); - m_session->waitForOpened(); -#endif lineEdit = new QLineEdit(this); lineEdit->setText("http://labs.qt.nokia.com/blogs/feed"); @@ -122,9 +105,7 @@ RSSListing::RSSListing(QWidget *parent) layout->addWidget(treeWidget); setWindowTitle(tr("RSS listing example")); -#if !defined(Q_OS_SYMBIAN) && !defined(Q_WS_MAEMO_5) resize(640,480); -#endif } /* diff --git a/examples/xml/rsslisting/rsslisting.h b/examples/xml/rsslisting/rsslisting.h index 49c694092c..22d222e2b9 100644 --- a/examples/xml/rsslisting/rsslisting.h +++ b/examples/xml/rsslisting/rsslisting.h @@ -48,15 +48,6 @@ #include <QXmlStreamReader> #include <QUrl> -#ifdef Q_OS_SYMBIAN -// Bearer -#include <QNetworkConfigurationManager> -#include <QNetworkSession> -#include <QPointer> - -// QtMobility namespace -QTM_USE_NAMESPACE -#endif QT_BEGIN_NAMESPACE class QLineEdit; @@ -95,10 +86,6 @@ private: QTreeWidget *treeWidget; QPushButton *fetchButton; -#ifdef Q_OS_SYMBIAN - // for bearer management - QPointer<QNetworkSession> m_session; -#endif }; #endif diff --git a/examples/xml/rsslisting/rsslisting.pro b/examples/xml/rsslisting/rsslisting.pro index 551be70db7..b0920cc8e7 100644 --- a/examples/xml/rsslisting/rsslisting.pro +++ b/examples/xml/rsslisting/rsslisting.pro @@ -7,16 +7,3 @@ target.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/rsslisting sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS rsslisting.pro sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/rsslisting INSTALLS += target sources - -symbian { - CONFIG += qt_example - - # For QtMobility - CONFIG += mobility - MOBILITY = bearer - - # For QtMobility - TARGET.CAPABILITY = NetworkServices -} - -maemo5: CONFIG += qt_example diff --git a/examples/xml/saxbookmarks/main.cpp b/examples/xml/saxbookmarks/main.cpp index 5d70ec89a5..71ce6aec0b 100644 --- a/examples/xml/saxbookmarks/main.cpp +++ b/examples/xml/saxbookmarks/main.cpp @@ -46,11 +46,7 @@ int main(int argc, char *argv[]) { QApplication app(argc, argv); MainWindow mainWin; -#if defined(Q_OS_SYMBIAN) - mainWin.showFullScreen(); -#else mainWin.show(); -#endif mainWin.open(); return app.exec(); } diff --git a/examples/xml/saxbookmarks/mainwindow.cpp b/examples/xml/saxbookmarks/mainwindow.cpp index 93aae7f906..0f65c1f71c 100644 --- a/examples/xml/saxbookmarks/mainwindow.cpp +++ b/examples/xml/saxbookmarks/mainwindow.cpp @@ -65,15 +65,6 @@ MainWindow::MainWindow() void MainWindow::open() { -#if defined(Q_OS_SYMBIAN) - // Look for bookmarks on the same drive where the application is installed to, - // if drive is not read only. QDesktopServices::DataLocation does this check, - // and returns writable drive. - QString bookmarksFolder = - QDesktopServices::storageLocation(QDesktopServices::DataLocation).left(1); - bookmarksFolder.append(":/Data/qt/saxbookmarks"); - QDir::setCurrent(bookmarksFolder); -#endif QString fileName = QFileDialog::getOpenFileName(this, tr("Open Bookmark File"), QDir::currentPath(), diff --git a/examples/xml/saxbookmarks/saxbookmarks.pro b/examples/xml/saxbookmarks/saxbookmarks.pro index 22d96f5b96..4d2a2800fb 100644 --- a/examples/xml/saxbookmarks/saxbookmarks.pro +++ b/examples/xml/saxbookmarks/saxbookmarks.pro @@ -18,13 +18,3 @@ wince*: { addFiles.path = "\\My Documents" DEPLOYMENT += addFiles } - -symbian: { - TARGET.UID3 = 0xA000C60A - CONFIG += qt_example - addFiles.files = frank.xbel jennifer.xbel - addFiles.path = /data/qt/saxbookmarks - DEPLOYMENT += addFiles -} -maemo5: CONFIG += qt_example - diff --git a/examples/xml/streambookmarks/main.cpp b/examples/xml/streambookmarks/main.cpp index d909c01b51..c44e921e82 100644 --- a/examples/xml/streambookmarks/main.cpp +++ b/examples/xml/streambookmarks/main.cpp @@ -47,9 +47,6 @@ int main(int argc, char *argv[]) { QApplication app(argc, argv); MainWindow mainWin; -#ifdef Q_OS_SYMBIAN - mainWin.showFullScreen(); -#endif mainWin.show(); mainWin.open(); return app.exec(); diff --git a/examples/xml/streambookmarks/mainwindow.cpp b/examples/xml/streambookmarks/mainwindow.cpp index 780b2b82d1..ed765995e7 100644 --- a/examples/xml/streambookmarks/mainwindow.cpp +++ b/examples/xml/streambookmarks/mainwindow.cpp @@ -68,15 +68,6 @@ MainWindow::MainWindow() //! [1] void MainWindow::open() { -#if defined(Q_OS_SYMBIAN) - // Look for bookmarks on the same drive where the application is installed to, - // if drive is not read only. QDesktopServices::DataLocation does this check, - // and returns writable drive. - QString bookmarksFolder = - QDesktopServices::storageLocation(QDesktopServices::DataLocation).left(1); - bookmarksFolder.append(":/Data/qt/saxbookmarks"); - QDir::setCurrent(bookmarksFolder); -#endif QString fileName = QFileDialog::getOpenFileName(this, tr("Open Bookmark File"), QDir::currentPath(), @@ -112,15 +103,6 @@ void MainWindow::open() //! [2] void MainWindow::saveAs() { -#if defined(Q_OS_SYMBIAN) - // Look for bookmarks on the same drive where the application is installed to, - // if drive is not read only. QDesktopServices::DataLocation does this check, - // and returns writable drive. - QString bookmarksFolder = - QDesktopServices::storageLocation(QDesktopServices::DataLocation).left(1); - bookmarksFolder.append(":/Data/qt/saxbookmarks"); - QDir::setCurrent(bookmarksFolder); -#endif QString fileName = QFileDialog::getSaveFileName(this, tr("Save Bookmark File"), QDir::currentPath(), diff --git a/examples/xml/streambookmarks/streambookmarks.pro b/examples/xml/streambookmarks/streambookmarks.pro index de9b1ab5a1..3342d5ee35 100644 --- a/examples/xml/streambookmarks/streambookmarks.pro +++ b/examples/xml/streambookmarks/streambookmarks.pro @@ -12,11 +12,3 @@ target.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/streambookmarks sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS streambookmarks.pro *.xbel sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/streambookmarks INSTALLS += target sources - -symbian: { - CONFIG += qt_example - addFiles.sources = frank.xbel jennifer.xbel - addFiles.path = /data/qt/streambookmarks - DEPLOYMENT += addFiles -} -maemo5: CONFIG += qt_example diff --git a/examples/xml/xml.pro b/examples/xml/xml.pro index 3c93131aad..cb28fe31d1 100644 --- a/examples/xml/xml.pro +++ b/examples/xml/xml.pro @@ -9,7 +9,6 @@ SUBDIRS = htmlinfo \ streambookmarks } -symbian: SUBDIRS = htmlinfo saxbookmarks # install target.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml @@ -17,6 +16,4 @@ sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS xml.pro README sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml INSTALLS += target sources -symbian: CONFIG += qt_example QT += widgets -maemo5: CONFIG += qt_example diff --git a/examples/xml/xmlstreamlint/xmlstreamlint.pro b/examples/xml/xmlstreamlint/xmlstreamlint.pro index 32e95c5ce5..cfcecf0391 100644 --- a/examples/xml/xmlstreamlint/xmlstreamlint.pro +++ b/examples/xml/xmlstreamlint/xmlstreamlint.pro @@ -9,8 +9,5 @@ sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS xmlstreamlint.pro sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/xml/xmlstreamlint INSTALLS += target sources -symbian: CONFIG += qt_example -maemo5: CONFIG += qt_example -symbian: warning(This example does not work on Symbian platform) simulator: warning(This example does not work on Simulator platform) |