void BookView::mousePressEvent(QMouseEvent *e)
{
QWebView::mousePressEvent(e);
-#if defined(Q_WS_MAEMO_5) || defined(Q_OS_SYMBIAN)
+#if defined(Q_WS_MAEMO_5)
// Start monitoring kinetic scroll
if (scrollerMonitor) {
killTimer(scrollerMonitor);
scrollerMonitor = -1;
}
}
-#elif defined(Q_OS_SYMBIAN)
- if (e->timerId() == scrollerMonitor) {
- if (charm && charm->)
- }
#endif
QWebView::timerEvent(e);
}
}
symbian {
- ICON = $$PWD/pkg/symbian/book.svg
+ TARGET = Dorian
TARGET.UID3 = 0xEA633557
TARGET.CAPABILITY = NetworkServices ReadUserData WriteUserData
TARGET.EPOCHEAPSIZE = 0x080000 0x4000000
+ ICON = $$PWD/pkg/symbian/book.svg
+ packageheader = "$${LITERAL_HASH}{\"Dorian\"}, (0xEA633557), 0, 3, 4"
+ vendorinfo = \
+ "%{\"Nokia Betalabs \"}" \
+ ":\"Nokia Betalabs \""
+ my_deployment.pkg_prerules = packageheader vendorinfo
+ DEPLOYMENT += my_deployment
+
INCLUDEPATH += $(QTDIR)/src/3rdparty/zlib
HEADERS += widgets/flickcharm.h
SOURCES += widgets/flickcharm.cpp
#include <QDir>
#include <QtGui>
-#ifdef Q_WS_MAEMO_5
-#include <QtMaemo5/QMaemo5InformationBox>
-#endif
-
#include "librarydialog.h"
#include "library.h"
#include "sortedlibrary.h"
// Add book to library
QModelIndex index = library->find(path);
if (index.isValid()) {
-#ifdef Q_WS_MAEMO_5
- QMaemo5InformationBox::information(this,
- tr("This book is already in the library"),
- QMaemo5InformationBox::DefaultTimeout);
-#else
- (void)QMessageBox::information(this, tr("Dorian"),
- tr("This book is already in the library"), QMessageBox::Ok);
-#endif // Q_WS_MAEMO_5
+ Platform::information(tr("This book is already in the library"), this);
setSelected(index);
}
else {
progress->reset();
qDebug() << "LibraryDialog::onRefreshDone:" << msg;
-#ifdef Q_WS_MAEMO_5
- QMaemo5InformationBox::information(this, msg);
-#else
- QMessageBox::information(this, tr("Done adding books"), msg);
-#endif
+ Platform::information(msg, this);
}
void LibraryDialog::onAddFromFolder(const QString &path)
#include <QtGui>
#ifdef Q_WS_MAEMO_5
-# include <QtMaemo5/QMaemo5InformationBox>
# include <QtDBus>
# include <QtGui/QX11Info>
# include <X11/Xlib.h>
{
TRACE;
view->addBookmark(note);
-#ifdef Q_WS_MAEMO_5
- QMaemo5InformationBox::information(this,
- tr("Bookmarked current position"), QMaemo5InformationBox::DefaultTimeout);
-#else
- (void)QMessageBox::information(this, tr("Dorian"),
- tr("Bookmarked current position"), QMessageBox::Ok);
-#endif // Q_WS_MAEMO_5}
+ Platform::information(tr("Bookmarked current position"), this);
}
void MainWindow::onGoToBookmark(int index)
+dorian (0.3.4-1) unstable; urgency=low
+
+ * On Symbian, display confirmation after downloading a book
+
+ -- Akos Polster <akos@pipacs.com> Fri, 5 Nov 2010 02:00:00 +0100
+
dorian (0.3.3-1) unstable; urgency=low
* Fix font scaling on Symbian
#include "pkg/version.txt"
;
+#ifdef Q_WS_MAEMO_5
+# include <QtMaemo5/QMaemo5InformationBox>
+#else
+# include <QMessageBox>
+#endif
+
QString Platform::dbPath()
{
QString base(QDir::home().absoluteFilePath(DORIAN_BASE));
return QString("Times New Roman");
#endif
}
+
+void Platform::information(const QString &label, QWidget *parent)
+{
+#ifdef Q_WS_MAEMO_5
+ QMaemo5InformationBox::information(parent, label,
+ QMaemo5InformationBox::DefaultTimeout);
+#else
+ (void)QMessageBox::information(parent, QObject::tr("Dorian"), label,
+ QMessageBox::Ok);
+#endif
+}
#include <QString>
+class QWidget;
+
/** Platform abstractions. */
class Platform
{
static QString version();
static QString downloadDir();
static QString defaultFont();
+ static void information(const QString &label, QWidget *parent = 0);
};
#endif // PLATFORM_H
#include <QDir>
#include <QFile>
-#ifdef Q_WS_MAEMO_5
-#include <QtMaemo5/QMaemo5InformationBox>
-#endif
-
#include "listview.h"
#include "searchresultsdialog.h"
#include "searchresultinfodialog.h"
if (-1 != row) {
list->model()->removeRow(row);
}
-#ifdef Q_WS_MAEMO_5
- QMaemo5InformationBox::information(this,
- tr("Downloaded \"%1\"\nand added to the library").arg(result.title),
- QMaemo5InformationBox::DefaultTimeout);
-#endif
+ Platform::information(tr("Downloaded \"%1\"\nand added to the library").
+ arg(result.title), this);
}
}