Changes: Deprecate MDeclarativeCache::applicationDirPath() and

MDeclarativeCache::applicationFilePath().
         Modify examples to use the QCoreApplication members.
RevBy: Juha Lintula
pull/1/head
Pertti Kellomäki 15 years ago
parent 2e4b3f5d6a
commit 1c93b10b0a

1
debian/changelog vendored

@ -1,5 +1,6 @@
applauncherd (0.30.1) unstable; urgency=low
* Changes: Deprecate MDeclarativeCache::applicationDirPath() and MDeclarativeCache::applicationFilePath().
* Changes: Modify test applications to use _exit().
-- Pertti Kellomaki <pertti.kellomaki@nokia.com> Wed, 8 Jun 2011 13:36:37 +0300

@ -25,10 +25,7 @@ Q_DECL_EXPORT int main(int argc, char **argv)
QApplication *app = MDeclarativeCache::qApplication(argc, argv);
QDeclarativeView *window = MDeclarativeCache::qDeclarativeView();
// Use MDeclarativeCache::applicationDirPath()
// instead of QCoreApplication::applicationDirPath()
// because the latter does not work with the booster.
QDir::setCurrent(MDeclarativeCache::applicationDirPath());
QDir::setCurrent(QCoreApplication::applicationDirPath());
window->setSource(QUrl::fromLocalFile("main.qml"));
window->showFullScreen();

@ -25,10 +25,7 @@ Q_DECL_EXPORT int main(int argc, char **argv)
QApplication *app = MDeclarativeCache::qApplication(argc, argv);
QDeclarativeView *window = MDeclarativeCache::qDeclarativeView();
// Use MDeclarativeCache::applicationDirPath()
// instead of QCoreApplication::applicationDirPath()
// because the latter does not work with the booster.
QDir::setCurrent(MDeclarativeCache::applicationDirPath());
QDir::setCurrent(QCoreApplication::applicationDirPath());
window->setSource(QUrl::fromLocalFile("main.qml"));

@ -60,17 +60,17 @@ public:
//! Returns the directory that contains the application executable.
/*!
* Workaround for QApplication::applicationDirPath() that does not
* work on linux with qdeclarativebooster and Qt 4.7.
* This function is deprecated. It used to be a workaround for QApplication::applicationDirPath()
* not working on harmattan with qdeclarativebooster and Qt 4.7, but this has been fixed.
*/
static QString applicationDirPath();
static QString applicationDirPath() __attribute__ ((deprecated));
//! Returns the file path of the application executable.
/*!
* Workaround for QApplication::applicationFilePath() that does not
* work on linux with qdeclarativebooster and Qt 4.7.
* This function is deprecated. It used to be a workaround for QApplication::applicationFilePath()
* not working on harmattan with qdeclarativebooster and Qt 4.7, but this has been fixed.
*/
static QString applicationFilePath();
static QString applicationFilePath() __attribute__ ((deprecated));
protected:

Loading…
Cancel
Save