summaryrefslogtreecommitdiffstats
path: root/demos
diff options
context:
space:
mode:
Diffstat (limited to 'demos')
-rw-r--r--demos/declarative/minehunt/minehunt.qml33
-rw-r--r--demos/declarative/twitter/TwitterCore/FatDelegate.qml2
2 files changed, 18 insertions, 17 deletions
diff --git a/demos/declarative/minehunt/minehunt.qml b/demos/declarative/minehunt/minehunt.qml
index 4e384c0..98955e2 100644
--- a/demos/declarative/minehunt/minehunt.qml
+++ b/demos/declarative/minehunt/minehunt.qml
@@ -86,19 +86,20 @@ Item {
field.clicky = flipable.parent.y
var row = Math.floor(index / 9)
var col = index - (Math.floor(index / 9) * 9)
- if (mouse.button == undefined || mouse.button == Qt.RightButton)
+ if (mouse.button == undefined || mouse.button == Qt.RightButton) {
flag(row, col)
- else
- flip(row, col)
- }
- onPressAndHold: {
- field.clickx = flipable.parent.x
- field.clicky = flipable.parent.y
- var row = Math.floor(index / 9)
- var col = index - (Math.floor(index / 9) * 9)
- flag(row, col)
- }
+ } else {
+ flip(row, col)
}
+ }
+ onPressAndHold: {
+ field.clickx = flipable.parent.x
+ field.clicky = flipable.parent.y
+ var row = Math.floor(index / 9)
+ var col = index - (Math.floor(index / 9) * 9)
+ flag(row, col)
+ }
+ }
}
}
@@ -136,13 +137,13 @@ Item {
Image {
anchors.bottom: field.bottom; anchors.bottomMargin: 15
anchors.right: field.right; anchors.rightMargin: 20
- source: isPlaying ? 'MinehuntCore/pics/face-smile.png'
- : hasWon ? 'MinehuntCore/pics/face-smile-big.png': 'MinehuntCore/pics/face-sad.png'
+ source: isPlaying ? 'MinehuntCore/pics/face-smile.png' :
+ hasWon ? 'MinehuntCore/pics/face-smile-big.png': 'MinehuntCore/pics/face-sad.png'
- MouseArea { anchors.fill: parent; onPressed: reset() }
- }
+ MouseArea { anchors.fill: parent; onPressed: reset() }
+ }
Text {
- anchors.fill: parent; wrap: true
+ anchors.fill: parent; wrapMode: Text.WordWrap
text: "Minehunt will not run properly if the C++ plugin is not compiled.\nPlease see README."
color: "white"; font.bold: true; font.pixelSize: 14
visible: tiles == undefined
diff --git a/demos/declarative/twitter/TwitterCore/FatDelegate.qml b/demos/declarative/twitter/TwitterCore/FatDelegate.qml
index 3eabd9d..e999bb4 100644
--- a/demos/declarative/twitter/TwitterCore/FatDelegate.qml
+++ b/demos/declarative/twitter/TwitterCore/FatDelegate.qml
@@ -37,7 +37,7 @@ Component {
+ '<a href="app://@'+userScreenName+'"><b>'+userScreenName + "</b></a> from " +source
+ "<br /><b>" + addTags(statusText) + "</b></html>";
textFormat: Qt.RichText
- color: "#cccccc"; style: Text.Raised; styleColor: "black"; wrap: true
+ color: "#cccccc"; style: Text.Raised; styleColor: "black"; wrapMode: Text.WordWrap
anchors.left: whiteRect.right; anchors.right: blackRect.right; anchors.leftMargin: 6; anchors.rightMargin: 6
onLinkActivated: handleLink(link)
}