summaryrefslogtreecommitdiffstats
path: root/examples/draganddrop
diff options
context:
space:
mode:
Diffstat (limited to 'examples/draganddrop')
-rw-r--r--examples/draganddrop/delayedencoding/delayedencoding.pro2
-rw-r--r--examples/draganddrop/draganddrop.pro2
-rw-r--r--examples/draganddrop/draggableicons/draggableicons.pro5
-rw-r--r--examples/draganddrop/draggabletext/draggabletext.pro5
-rw-r--r--examples/draganddrop/dropsite/dropsite.pro1
-rw-r--r--examples/draganddrop/dropsite/dropsitewindow.cpp6
-rw-r--r--examples/draganddrop/fridgemagnets/dragwidget.cpp3
-rw-r--r--examples/draganddrop/fridgemagnets/fridgemagnets.pro7
-rw-r--r--examples/draganddrop/fridgemagnets/main.cpp9
-rw-r--r--examples/draganddrop/puzzle/mainwindow.cpp4
-rw-r--r--examples/draganddrop/puzzle/puzzle.pro7
11 files changed, 43 insertions, 8 deletions
diff --git a/examples/draganddrop/delayedencoding/delayedencoding.pro b/examples/draganddrop/delayedencoding/delayedencoding.pro
index c7b95b6..7315ac5 100644
--- a/examples/draganddrop/delayedencoding/delayedencoding.pro
+++ b/examples/draganddrop/delayedencoding/delayedencoding.pro
@@ -12,3 +12,5 @@ target.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/delayedencoding
sources.files = $$SOURCES $$HEADERS *.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/itemviews/delayedencoding
INSTALLS += target sources
+
+symbian:TARGET.UID3 = 0xA000C614 \ No newline at end of file
diff --git a/examples/draganddrop/draganddrop.pro b/examples/draganddrop/draganddrop.pro
index 0cd881a..fa857db 100644
--- a/examples/draganddrop/draganddrop.pro
+++ b/examples/draganddrop/draganddrop.pro
@@ -8,7 +8,7 @@ SUBDIRS = draggableicons \
contains(QT_CONFIG, svg): SUBDIRS += delayedencoding
wince*: SUBDIRS -= dropsite
-
+symbian: SUBDIRS -= dropsite
# install
sources.files = README *.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/draganddrop
diff --git a/examples/draganddrop/draggableicons/draggableicons.pro b/examples/draganddrop/draggableicons/draggableicons.pro
index 74cfda9..f177bd6 100644
--- a/examples/draganddrop/draggableicons/draggableicons.pro
+++ b/examples/draganddrop/draggableicons/draggableicons.pro
@@ -8,3 +8,8 @@ target.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/draggableicons
sources.files = $$SOURCES $$HEADERS $$RESOURCES *.pro images
sources.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/draggableicons
INSTALLS += target sources
+
+symbian {
+ include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+ TARGET.UID3 = 0xA000C615
+}
diff --git a/examples/draganddrop/draggabletext/draggabletext.pro b/examples/draganddrop/draggabletext/draggabletext.pro
index 07c7c24..19fee2d 100644
--- a/examples/draganddrop/draggabletext/draggabletext.pro
+++ b/examples/draganddrop/draggabletext/draggabletext.pro
@@ -10,3 +10,8 @@ target.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/draggabletext
sources.files = $$SOURCES $$HEADERS $$RESOURCES *.txt *.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/draggabletext
INSTALLS += target sources
+
+symbian {
+ include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+ TARGET.UID3 = 0xA000CF64
+}
diff --git a/examples/draganddrop/dropsite/dropsite.pro b/examples/draganddrop/dropsite/dropsite.pro
index 29dd0fd..5f81b09 100644
--- a/examples/draganddrop/dropsite/dropsite.pro
+++ b/examples/draganddrop/dropsite/dropsite.pro
@@ -10,3 +10,4 @@ sources.files = $$SOURCES $$HEADERS $$RESOURCES *.pro images
sources.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/dropsite
INSTALLS += target sources
+symbian: include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
diff --git a/examples/draganddrop/dropsite/dropsitewindow.cpp b/examples/draganddrop/dropsite/dropsitewindow.cpp
index 51fd8ff..d4227f9 100644
--- a/examples/draganddrop/dropsite/dropsitewindow.cpp
+++ b/examples/draganddrop/dropsite/dropsitewindow.cpp
@@ -119,10 +119,8 @@ void DropSiteWindow::updateFormatsTable(const QMimeData *mimeData)
text = mimeData->html().simplified();
} else if (format == "text/uri-list") {
QList<QUrl> urlList = mimeData->urls();
- for (int i = 0; i < urlList.size() && i < 32; ++i) {
- QString url = urlList.at(i).path();
- text.append(url + " ");
- }
+ for (int i = 0; i < urlList.size() && i < 32; ++i)
+ text.append(urlList[i].toString() + " ");
} else {
QByteArray data = mimeData->data(format);
for (int i = 0; i < data.size() && i < 32; ++i) {
diff --git a/examples/draganddrop/fridgemagnets/dragwidget.cpp b/examples/draganddrop/fridgemagnets/dragwidget.cpp
index a50bdb0..a619d5c 100644
--- a/examples/draganddrop/fridgemagnets/dragwidget.cpp
+++ b/examples/draganddrop/fridgemagnets/dragwidget.cpp
@@ -75,9 +75,12 @@ DragWidget::DragWidget(QWidget *parent)
//! [1]
//! [2]
+ #ifndef Q_WS_S60
+ //Fridge magnets is used for demoing Qt on S60 and themed backgrounds look better than white
QPalette newPalette = palette();
newPalette.setColor(QPalette::Window, Qt::white);
setPalette(newPalette);
+ #endif
setMinimumSize(400, qMax(200, y));
setWindowTitle(tr("Fridge Magnets"));
diff --git a/examples/draganddrop/fridgemagnets/fridgemagnets.pro b/examples/draganddrop/fridgemagnets/fridgemagnets.pro
index f1baaef..b8388cf 100644
--- a/examples/draganddrop/fridgemagnets/fridgemagnets.pro
+++ b/examples/draganddrop/fridgemagnets/fridgemagnets.pro
@@ -10,3 +10,10 @@ target.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/fridgemagnets
sources.files = $$SOURCES $$HEADERS $$RESOURCES *.pro *.txt
sources.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/fridgemagnets
INSTALLS += target sources
+
+symbian {
+ include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+ TARGET.UID3 = 0xA000C610
+}
+
+
diff --git a/examples/draganddrop/fridgemagnets/main.cpp b/examples/draganddrop/fridgemagnets/main.cpp
index 69ea367..959f303 100644
--- a/examples/draganddrop/fridgemagnets/main.cpp
+++ b/examples/draganddrop/fridgemagnets/main.cpp
@@ -45,9 +45,16 @@
int main(int argc, char *argv[])
{
Q_INIT_RESOURCE(fridgemagnets);
+ bool smallScreen = false;
+ for (int i=0; i<argc; i++)
+ if (QString(argv[i]) == "-small-screen")
+ smallScreen = true;
QApplication app(argc, argv);
DragWidget window;
- window.show();
+ if (smallScreen)
+ window.showFullScreen();
+ else
+ window.show();
return app.exec();
}
diff --git a/examples/draganddrop/puzzle/mainwindow.cpp b/examples/draganddrop/puzzle/mainwindow.cpp
index 359a245..a037df2 100644
--- a/examples/draganddrop/puzzle/mainwindow.cpp
+++ b/examples/draganddrop/puzzle/mainwindow.cpp
@@ -120,10 +120,10 @@ void MainWindow::setupMenus()
QMenu *fileMenu = menuBar()->addMenu(tr("&File"));
QAction *openAction = fileMenu->addAction(tr("&Open..."));
- openAction->setShortcut(QKeySequence(tr("Ctrl+O")));
+ openAction->setShortcuts(QKeySequence::Open);
QAction *exitAction = fileMenu->addAction(tr("E&xit"));
- exitAction->setShortcut(QKeySequence(tr("Ctrl+Q")));
+ exitAction->setShortcuts(QKeySequence::Quit);
QMenu *gameMenu = menuBar()->addMenu(tr("&Game"));
diff --git a/examples/draganddrop/puzzle/puzzle.pro b/examples/draganddrop/puzzle/puzzle.pro
index 26d2350..20080e9 100644
--- a/examples/draganddrop/puzzle/puzzle.pro
+++ b/examples/draganddrop/puzzle/puzzle.pro
@@ -13,6 +13,13 @@ sources.files = $$SOURCES $$HEADERS $$RESOURCES *.pro *.jpg
sources.path = $$[QT_INSTALL_EXAMPLES]/draganddrop/puzzle
INSTALLS += target sources
+symbian:{
+ include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+ addFile.sources = example.jpg
+ addFile.path = .
+ DEPLOYMENT += addFile
+ TARGET.UID3 = 0xA000CF65
+}
wince*: {
addFile.sources = example.jpg
addFile.path = .