summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-03-16 08:42:32 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-03-16 08:42:32 (GMT)
commit071d4bf6b871a353350dfd7448255ca23ce13c68 (patch)
tree2f89458a4392ac6b78f95d93b8d0c9ec615cb0f4
parent83e321747920c31d6fa4c860de3683630fbedb5d (diff)
parent9931ceb49685fde68f623ae18d4497273162cf76 (diff)
downloadQt-071d4bf6b871a353350dfd7448255ca23ce13c68.zip
Qt-071d4bf6b871a353350dfd7448255ca23ce13c68.tar.gz
Qt-071d4bf6b871a353350dfd7448255ca23ce13c68.tar.bz2
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt-s60-public into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/qt-s60-public: Make sure target path exists in qmake_extra_pre_targetdep.flm Added close button to Anomaly demo browser
-rw-r--r--demos/embedded/anomaly/src/BrowserView.cpp1
-rw-r--r--demos/embedded/anomaly/src/ControlStrip.cpp15
-rw-r--r--demos/embedded/anomaly/src/ControlStrip.h2
-rw-r--r--demos/embedded/anomaly/src/anomaly.qrc1
-rw-r--r--demos/embedded/anomaly/src/images/button-close.pngbin0 -> 1833 bytes
-rw-r--r--mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm2
6 files changed, 18 insertions, 3 deletions
diff --git a/demos/embedded/anomaly/src/BrowserView.cpp b/demos/embedded/anomaly/src/BrowserView.cpp
index 0945b89..41318ad 100644
--- a/demos/embedded/anomaly/src/BrowserView.cpp
+++ b/demos/embedded/anomaly/src/BrowserView.cpp
@@ -82,6 +82,7 @@ void BrowserView::initialize()
connect(m_controlStrip, SIGNAL(menuClicked()), SIGNAL(menuButtonClicked()));
connect(m_controlStrip, SIGNAL(backClicked()), m_webView, SLOT(back()));
connect(m_controlStrip, SIGNAL(forwardClicked()), m_webView, SLOT(forward()));
+ connect(m_controlStrip, SIGNAL(closeClicked()), qApp, SLOT(quit()));
QPalette pal = m_webView->palette();
pal.setBrush(QPalette::Base, Qt::white);
diff --git a/demos/embedded/anomaly/src/ControlStrip.cpp b/demos/embedded/anomaly/src/ControlStrip.cpp
index 265d9a0..dc6d5c2 100644
--- a/demos/embedded/anomaly/src/ControlStrip.cpp
+++ b/demos/embedded/anomaly/src/ControlStrip.cpp
@@ -50,6 +50,7 @@ ControlStrip::ControlStrip(QWidget *parent)
menuPixmap.load(":/images/edit-find.png");
backPixmap.load(":/images/go-previous.png");
forwardPixmap.load(":/images/go-next.png");
+ closePixmap.load(":/images/button-close.png");
}
QSize ControlStrip::sizeHint() const
@@ -74,12 +75,18 @@ void ControlStrip::mousePressEvent(QMouseEvent *event)
}
if (x > width() - h) {
- emit forwardClicked();
+ emit closeClicked();
event->accept();
return;
}
if ((x < width() - 2 * h) && (x > width() - 3 * h)) {
+ emit forwardClicked();
+ event->accept();
+ return;
+ }
+
+ if ((x < width() - 3 * h) && (x > width() - 5 * h)) {
emit backClicked();
event->accept();
return;
@@ -95,7 +102,9 @@ void ControlStrip::paintEvent(QPaintEvent *event)
p.fillRect(event->rect(), QColor(32, 32, 32, 192));
p.setCompositionMode(QPainter::CompositionMode_SourceOver);
p.drawPixmap(s, s, menuPixmap);
- p.drawPixmap(width() - 3 * h + s, s, backPixmap);
- p.drawPixmap(width() - h + s, s, forwardPixmap);
+ p.drawPixmap(width() - h + s, s, closePixmap);
+ p.drawPixmap(width() - 3 * h + s, s, forwardPixmap);
+ p.drawPixmap(width() - 5 * h + s, s, backPixmap);
+
p.end();
}
diff --git a/demos/embedded/anomaly/src/ControlStrip.h b/demos/embedded/anomaly/src/ControlStrip.h
index bbaea87..b6003a1 100644
--- a/demos/embedded/anomaly/src/ControlStrip.h
+++ b/demos/embedded/anomaly/src/ControlStrip.h
@@ -58,6 +58,7 @@ signals:
void menuClicked();
void backClicked();
void forwardClicked();
+ void closeClicked();
protected:
void paintEvent(QPaintEvent *event);
@@ -67,6 +68,7 @@ private:
QPixmap menuPixmap;
QPixmap backPixmap;
QPixmap forwardPixmap;
+ QPixmap closePixmap;
};
#endif // CONTROLSTRIP_H
diff --git a/demos/embedded/anomaly/src/anomaly.qrc b/demos/embedded/anomaly/src/anomaly.qrc
index 601a34e..d8ea630 100644
--- a/demos/embedded/anomaly/src/anomaly.qrc
+++ b/demos/embedded/anomaly/src/anomaly.qrc
@@ -5,5 +5,6 @@
<file>images/edit-find.png</file>
<file>images/list-add.png</file>
<file>images/list-remove.png</file>
+ <file>images/button-close.png</file>
</qresource>
</RCC>
diff --git a/demos/embedded/anomaly/src/images/button-close.png b/demos/embedded/anomaly/src/images/button-close.png
new file mode 100644
index 0000000..7a7b048
--- /dev/null
+++ b/demos/embedded/anomaly/src/images/button-close.png
Binary files differ
diff --git a/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm b/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm
index daf33d4..1338515 100644
--- a/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm
+++ b/mkspecs/symbian-sbsv2/flm/qt/qmake_extra_pre_targetdep.flm
@@ -10,6 +10,8 @@
SINGLETON:=$(call sanitise,TARGET_$(PREDEP_TARGET))
+$(call makepathfor,$(PREDEP_TARGET))
+
define qmake_extra_pre_targetdep
EXPORT:: $(PREDEP_TARGET)