summaryrefslogtreecommitdiffstats
path: root/examples/script/context2d
diff options
context:
space:
mode:
Diffstat (limited to 'examples/script/context2d')
-rw-r--r--examples/script/context2d/context2d.pro9
-rw-r--r--examples/script/context2d/main.cpp3
-rw-r--r--examples/script/context2d/qcontext2dcanvas.cpp5
3 files changed, 16 insertions, 1 deletions
diff --git a/examples/script/context2d/context2d.pro b/examples/script/context2d/context2d.pro
index 30ec9a7..be14272 100644
--- a/examples/script/context2d/context2d.pro
+++ b/examples/script/context2d/context2d.pro
@@ -21,3 +21,12 @@ target.path = $$[QT_INSTALL_EXAMPLES]/script/context2d
sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS context2d.pro scripts
sources.path = $$[QT_INSTALL_EXAMPLES]/script/context2d
INSTALLS += target sources
+
+include($$QT_SOURCE_TREE/examples/examplebase.pri)
+symbian:{
+ TARGET.UID3 = 0xA000C608
+ TARGET.EPOCHEAPSIZE = 0x200000 0xA00000
+ contextScripts.path = .
+ contextScripts.sources = scripts
+ DEPLOYMENT += contextScripts
+} \ No newline at end of file
diff --git a/examples/script/context2d/main.cpp b/examples/script/context2d/main.cpp
index dedaa4a..977cd45 100644
--- a/examples/script/context2d/main.cpp
+++ b/examples/script/context2d/main.cpp
@@ -48,6 +48,7 @@ int main(int argc, char **argv)
QApplication app(argc, argv);
Window win;
- win.show();
+ //win.show();
+ win.showFullScreen();
return app.exec();
}
diff --git a/examples/script/context2d/qcontext2dcanvas.cpp b/examples/script/context2d/qcontext2dcanvas.cpp
index 5e97242..f735908 100644
--- a/examples/script/context2d/qcontext2dcanvas.cpp
+++ b/examples/script/context2d/qcontext2dcanvas.cpp
@@ -85,6 +85,11 @@ void QContext2DCanvas::contentsChanged(const QImage &image)
void QContext2DCanvas::paintEvent(QPaintEvent *e)
{
QPainter p(this);
+#ifdef Q_WS_S60
+// Draw white rect first since in with some themes the js-file content will produce black-on-black.
+ QBrush whiteBgBrush(Qt::white);
+ p.fillRect(e->rect(), whiteBgBrush);
+#endif
p.setClipRect(e->rect());
p.drawImage(0, 0, m_image);
}