Index: src/mainwindow.cpp
===================================================================
--- src/mainwindow.cpp	(revision 1241232377a4b2410dbae7c90864eec2f15a3279)
+++ src/mainwindow.cpp	(revision 7ed8b57eea1113272fa18cf2d867190a7ae56df7)
@@ -149,4 +149,8 @@
     setAcceptDrops(true);
 
+#ifdef Q_OS_BLACKBERRY
+    taskView->setEditTriggers(QAbstractItemView::AllEditTriggers);
+#endif
+
     initDocStyleSheet();
 
@@ -182,5 +186,5 @@
     connect(actionFileSaveAsTask, SIGNAL(triggered()), SLOT(actionFileSaveAsTaskTriggered()));
     connect(actionFileSaveAsSolution, SIGNAL(triggered()), SLOT(actionFileSaveAsSolutionTriggered()));
-#ifndef QT_NO_PRINTER
+#ifndef QT_NO_PRINTDIALOG
     connect(actionFilePrintPreview, SIGNAL(triggered()), SLOT(actionFilePrintPreviewTriggered()));
     connect(actionFilePageSetup, SIGNAL(triggered()), SLOT(actionFilePageSetupTriggered()));
@@ -483,5 +487,5 @@
 }
 
-#ifndef QT_NO_PRINTER
+#ifndef QT_NO_PRINTDIALOG
 void MainWindow::actionFilePrintPreviewTriggered()
 {
@@ -541,5 +545,5 @@
     QApplication::restoreOverrideCursor();
 }
-#endif // QT_NO_PRINTER
+#endif // QT_NO_PRINTDIALOG
 
 void MainWindow::actionSettingsPreferencesTriggered()
@@ -744,4 +748,7 @@
     txtAbout->moveCursor(QTextCursor::Start);
     txtAbout->setFrameShape(QFrame::NoFrame);
+#ifdef Q_OS_BLACKBERRY
+    txtAbout->setAttribute(Qt::WA_InputMethodEnabled, false);
+#endif
 
 //	txtCredits->setWordWrapMode(QTextOption::NoWrap);
@@ -750,4 +757,7 @@
     txtCredits->moveCursor(QTextCursor::Start);
     txtCredits->setFrameShape(QFrame::NoFrame);
+#ifdef Q_OS_BLACKBERRY
+    txtCredits->setAttribute(Qt::WA_InputMethodEnabled, false);
+#endif
 
     txtLicense->setWordWrapMode(QTextOption::NoWrap);
@@ -756,4 +766,7 @@
     txtLicense->moveCursor(QTextCursor::Start);
     txtLicense->setFrameShape(QFrame::NoFrame);
+#ifdef Q_OS_BLACKBERRY
+    txtLicense->setAttribute(Qt::WA_InputMethodEnabled, false);
+#endif
 
     bb->button(QDialogButtonBox::Ok)->setCursor(QCursor(Qt::PointingHandCursor));
@@ -807,5 +820,5 @@
 #ifndef HANDHELD
     dlg->resize(450, 350);
-#elif defined(Q_OS_SYMBIAN)
+#elif defined(Q_OS_SYMBIAN) || defined(Q_OS_BLACKBERRY)
     dlg->setWindowState(Qt::WindowMaximized);
 #endif
@@ -857,4 +870,5 @@
     pd.setCancelButton(cancel);
     pd.setMaximum(n);
+    pd.setAutoClose(false);
     pd.setAutoReset(false);
     pd.setLabelText(tr("Calculating optimal route..."));
@@ -1737,8 +1751,12 @@
         Ui_MainWindow::retranslateUi(this);
 
+#ifdef Q_OS_BLACKBERRY
+    menuSettings->removeAction(menuSettingsStyle->menuAction());
+#else
     loadStyleList();
+#endif
     loadToolbarList();
 
-#ifndef QT_NO_PRINTER
+#ifndef QT_NO_PRINTDIALOG
     actionFilePrintPreview->setText(tr("P&rint Preview..."));
 #ifndef QT_NO_TOOLTIP
@@ -1764,6 +1782,8 @@
     actionFilePrint->setStatusTip(tr("Print current solution results"));
 #endif // QT_NO_STATUSTIP
+#ifndef QT_NO_SHORTCUT
     actionFilePrint->setShortcut(tr("Ctrl+P"));
-#endif // QT_NO_PRINTER
+#endif // QT_NO_SHORTCUT
+#endif // QT_NO_PRINTDIALOG
 
 #ifndef QT_NO_STATUSTIP
@@ -1846,10 +1866,10 @@
     actionFileOpen->setIcon(GET_ICON("document-open"));
     actionFileSave->setIcon(GET_ICON("document-save"));
-#ifndef HANDHELD
+#if !defined(HANDHELD) || defined(Q_OS_BLACKBERRY)
     menuFileSaveAs->setIcon(GET_ICON("document-save-as"));
 #endif
     actionFileExit->setIcon(GET_ICON("application-exit"));
     // Settings Menu
-#ifndef HANDHELD
+#if !defined(HANDHELD) || defined(Q_OS_BLACKBERRY)
     menuSettingsLanguage->setIcon(GET_ICON("preferences-desktop-locale"));
 #if QT_VERSION >= QT_VERSION_CHECK(4,6,0)
@@ -1862,5 +1882,5 @@
     actionSettingsPreferences->setIcon(GET_ICON("preferences-system"));
     // Help Menu
-#ifndef HANDHELD
+#if !defined(HANDHELD) || defined(Q_OS_BLACKBERRY)
     actionHelpContents->setIcon(GET_ICON("help-contents"));
     actionHelpContextual->setIcon(GET_ICON("help-contextual"));
@@ -1868,9 +1888,15 @@
     actionHelpReportBug->setIcon(GET_ICON("tools-report-bug"));
     actionHelpAbout->setIcon(GET_ICON("help-about"));
+#ifdef Q_OS_BLACKBERRY
+    // Qt about dialog is too big for the screen
+    // and it's impossible to close it.
+    menuHelp->removeAction(actionHelpAboutQt);
+#else // Q_OS_BLACKBERRY
 #if QT_VERSION < QT_VERSION_CHECK(5,0,0)
     actionHelpAboutQt->setIcon(QIcon(":/trolltech/qmessagebox/images/qtlogo-64.png"));
-#else
+#else // QT_VERSION < QT_VERSION_CHECK(5,0,0)
     actionHelpAboutQt->setIcon(QIcon(":/qt-project.org/qmessagebox/images/qtlogo-64.png"));
 #endif // QT_VERSION < QT_VERSION_CHECK(5,0,0)
+#endif // Q_OS_BLACKBERRY
 #endif // HANDHELD
     // Buttons
@@ -1922,5 +1948,5 @@
     solutionText->setWordWrapMode(QTextOption::WordWrap);
 
-#ifndef QT_NO_PRINTER
+#ifndef QT_NO_PRINTDIALOG
     actionFilePrintPreview = new QAction(this);
     actionFilePrintPreview->setObjectName("actionFilePrintPreview");
@@ -1948,5 +1974,5 @@
 
     toolBarMain->insertAction(actionSettingsPreferences, actionFilePrint);
-#endif // QT_NO_PRINTER
+#endif // QT_NO_PRINTDIALOG
 
     groupSettingsLanguageList = new QActionGroup(this);
@@ -2021,8 +2047,8 @@
     actionFileSaveAsSolution->setEnabled(enable);
     solutionText->setEnabled(enable);
-#ifndef QT_NO_PRINTER
+#ifndef QT_NO_PRINTDIALOG
     actionFilePrint->setEnabled(enable);
     actionFilePrintPreview->setEnabled(enable);
-#endif // QT_NO_PRINTER
+#endif // QT_NO_PRINTDIALOG
 }
 
