Index: src/mainwindow.cpp
===================================================================
--- src/mainwindow.cpp	(revision c039ebbe827ae1ba92ae89b2e9caef549a96547c)
+++ src/mainwindow.cpp	(revision 2512bd5a48d086ea03092bc4bdb368c58fc82854)
@@ -31,4 +31,10 @@
 #include "_.h"
 _C_ _R_ _Y_ _P_ _T_
+#endif
+
+#ifdef Q_OS_BLACKBERRY
+#   include <bb/ApplicationSupport>
+#   include <bb/cascades/pickers/FilePicker>
+using namespace bb::cascades::pickers;
 #endif
 
@@ -172,4 +178,16 @@
 }
 
+#ifdef Q_OS_BLACKBERRY
+void MainWindow::setWindowModified(bool modified)
+{
+    QMainWindow::setWindowModified(modified);
+    bb::ApplicationSupport app;
+    if (modified)
+        app.setClosePrompt(tr("Unsaved Changes"), tr("The task has unsaved changes. Would you really like to close the application?"));
+    else
+        app.clearClosePrompt();
+}
+#endif
+
 /* Privates **********************************************************/
 
@@ -194,13 +212,18 @@
         return;
 
-QStringList filters(tr("All Supported Formats") + " (*.tspt *.zkt)");
+    QStringList filters;
+#ifdef Q_OS_BLACKBERRY
+    filters << "*.tspt" << "*.zkt";
+#else
+    filters.append(tr("All Supported Formats") + " (*.tspt *.zkt)");
     filters.append(tr("%1 Task Files").arg("TSPSG") + " (*.tspt)");
     filters.append(tr("%1 Task Files").arg("ZKomModRd") + " (*.zkt)");
     filters.append(tr("All Files") + " (*)");
+#endif
 
 QString file;
     if ((fileName == tr("Untitled") + ".tspt") && settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool())
 #ifdef Q_OS_BLACKBERRY
-        file = settings->value(OS"/LastUsed/TaskLoadPath", "/accounts/1000/shared").toString();
+        file = settings->value(OS"/LastUsed/TaskLoadPath", "/accounts/1000/shared/documents").toString();
 #else
         file = settings->value(OS"/LastUsed/TaskLoadPath").toString();
@@ -208,8 +231,28 @@
     else
         file = QFileInfo(fileName).path();
-QFileDialog::Options opts = settings->value("UseNativeDialogs", DEF_USE_NATIVE_DIALOGS).toBool() ? QFileDialog::Options() : QFileDialog::DontUseNativeDialog;
+#ifdef Q_OS_BLACKBERRY
+    FilePicker fd;
+    fd.setType(FileType::Document | FileType::Other);
+    fd.setDefaultType(FileType::Document);
+    fd.setTitle(tr("Task Load"));
+    fd.setFilter(filters);
+    fd.setDirectories(QStringList(file));
+    fd.open();
+
+    QEventLoop loop;
+    connect(&fd, SIGNAL(pickerClosed()), &loop, SLOT(quit()));
+    loop.exec();
+
+    if (fd.selectedFiles().count() < 1)
+        return;
+    file = fd.selectedFiles().at(0);
+    if (!QFileInfo(file).isFile())
+        return;
+#else
+    QFileDialog::Options opts = settings->value("UseNativeDialogs", DEF_USE_NATIVE_DIALOGS).toBool() ? QFileDialog::Options() : QFileDialog::DontUseNativeDialog;
     file = QFileDialog::getOpenFileName(this, tr("Task Load"), file, filters.join(";;"), NULL, opts);
     if (file.isEmpty() || !QFileInfo(file).isFile())
         return;
+#endif
     if (settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool())
         settings->setValue(OS"/LastUsed/TaskLoadPath", QFileInfo(file).path());
@@ -247,5 +290,5 @@
         if (settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool()) {
 #ifdef Q_OS_BLACKBERRY
-            selectedFile = settings->value(OS"/LastUsed/SolutionSavePath", "/accounts/1000/shared").toString();
+            selectedFile = settings->value(OS"/LastUsed/SolutionSavePath", "/accounts/1000/shared/documents").toString();
 #else
             selectedFile = settings->value(OS"/LastUsed/SolutionSavePath").toString();
@@ -271,4 +314,7 @@
 
 QStringList filters;
+#ifdef Q_OS_BLACKBERRY
+    filters << "*.pdf" << "*.html" << "*.htm" << "*.odf";
+#else
 #ifndef QT_NO_PRINTER
     filters.append(tr("PDF Files") + " (*.pdf)");
@@ -277,10 +323,32 @@
     filters.append(tr("OpenDocument Files") + " (*.odt)");
     filters.append(tr("All Files") + " (*)");
-
-QFileDialog::Options opts(settings->value("UseNativeDialogs", DEF_USE_NATIVE_DIALOGS).toBool() ? QFileDialog::Options() : QFileDialog::DontUseNativeDialog);
-QString file = QFileDialog::getSaveFileName(this, QString(), selectedFile, filters.join(";;"), NULL, opts);
+#endif
+
+#ifdef Q_OS_BLACKBERRY
+    FilePicker fd;
+    fd.setMode(FilePickerMode::Saver);
+    fd.setType(FileType::Document | FileType::Other);
+    fd.setDefaultType(FileType::Document);
+    fd.setAllowOverwrite(true);
+    fd.setTitle(tr("Solution Save"));
+//    fd.setDirectories(QStringList(QFileInfo(selectedFile).path()));
+    fd.setDefaultSaveFileNames(QStringList(selectedFile));
+    fd.setFilter(filters);
+    fd.open();
+
+    QEventLoop loop;
+    connect(&fd, SIGNAL(pickerClosed()), &loop, SLOT(quit()));
+    loop.exec();
+
+    if (fd.selectedFiles().count() < 1)
+        return;
+    selectedFile = fd.selectedFiles().at(0);
+#else
+    QFileDialog::Options opts(settings->value("UseNativeDialogs", DEF_USE_NATIVE_DIALOGS).toBool() ? QFileDialog::Options() : QFileDialog::DontUseNativeDialog);
+    QString file = QFileDialog::getSaveFileName(this, QString(), selectedFile, filters.join(";;"), NULL, opts);
     if (file.isEmpty())
         return;
     selectedFile = file;
+#endif
     if (settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool())
         settings->setValue(OS"/LastUsed/SolutionSavePath", QFileInfo(selectedFile).path());
@@ -1631,11 +1699,17 @@
 }
 
-bool MainWindow::saveTask() {
-QStringList filters(tr("%1 Task File").arg("TSPSG") + " (*.tspt)");
+bool MainWindow::saveTask()
+{
+    QStringList filters;
+#ifdef Q_OS_BLACKBERRY
+    filters << "*.tspt";
+#else
+    filters.append(tr("%1 Task File").arg("TSPSG") + " (*.tspt)");
     filters.append(tr("All Files") + " (*)");
+#endif
 QString file;
     if ((fileName == tr("Untitled") + ".tspt") && settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool()) {
 #ifdef Q_OS_BLACKBERRY
-        file = settings->value(OS"/LastUsed/TaskSavePath", "/accounts/1000/shared").toString();
+        file = settings->value(OS"/LastUsed/TaskSavePath", "/accounts/1000/shared/documents").toString();
 #else
         file = settings->value(OS"/LastUsed/TaskSavePath").toString();
@@ -1649,9 +1723,30 @@
         file = QFileInfo(fileName).path() + "/" + QFileInfo(fileName).completeBaseName() + ".tspt";
 
-QFileDialog::Options opts = settings->value("UseNativeDialogs", DEF_USE_NATIVE_DIALOGS).toBool() ? QFileDialog::Options() : QFileDialog::DontUseNativeDialog;
+#ifdef Q_OS_BLACKBERRY
+    FilePicker fd;
+    fd.setMode(FilePickerMode::Saver);
+    fd.setType(FileType::Document | FileType::Other);
+    fd.setDefaultType(FileType::Document);
+    fd.setAllowOverwrite(true);
+    fd.setTitle(tr("Task Save"));
+//    fd.setDirectories(QStringList(QFileInfo(file).path()));
+    fd.setDefaultSaveFileNames(QStringList(file));
+    fd.setFilter(filters);
+    fd.open();
+
+    QEventLoop loop;
+    connect(&fd, SIGNAL(pickerClosed()), &loop, SLOT(quit()));
+    loop.exec();
+
+    if (fd.selectedFiles().count() < 1)
+        return false;
+    file = fd.selectedFiles().at(0);
+#else
+    QFileDialog::Options opts = settings->value("UseNativeDialogs", DEF_USE_NATIVE_DIALOGS).toBool() ? QFileDialog::Options() : QFileDialog::DontUseNativeDialog;
     file = QFileDialog::getSaveFileName(this, tr("Task Save"), file, filters.join(";;"), NULL, opts);
     if (file.isEmpty())
         return false;
-    else if (settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool())
+#endif
+    if (settings->value("SaveLastUsed", DEF_SAVE_LAST_USED).toBool())
         settings->setValue(OS"/LastUsed/TaskSavePath", QFileInfo(file).path());
     if (QFileInfo(file).suffix().isEmpty()) {
Index: src/mainwindow.h
===================================================================
--- src/mainwindow.h	(revision c039ebbe827ae1ba92ae89b2e9caef549a96547c)
+++ src/mainwindow.h	(revision 2512bd5a48d086ea03092bc4bdb368c58fc82854)
@@ -54,4 +54,9 @@
     MainWindow(QWidget *parent = 0);
     ~MainWindow();
+
+#ifdef Q_OS_BLACKBERRY
+public slots:
+    void setWindowModified(bool modified);
+#endif
 
 private slots:
