From 129fc2c269813b7f12b55999649aaacdd25808e4 Mon Sep 17 00:00:00 2001 From: Bea Lam Date: Thu, 26 Nov 2009 16:17:27 +1000 Subject: Doc fixes --- doc/src/declarative/ecmascriptblocks.qdoc | 4 ++++ src/declarative/graphicsitems/qmlgraphicsflipable.cpp | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/src/declarative/ecmascriptblocks.qdoc b/doc/src/declarative/ecmascriptblocks.qdoc index 6ee5a8e..470d942 100644 --- a/doc/src/declarative/ecmascriptblocks.qdoc +++ b/doc/src/declarative/ecmascriptblocks.qdoc @@ -54,6 +54,10 @@ assigned to an object property or given an id. The included ECMAScript is evalu in a scope chain. The \l {QML Scope} documentation covers the specifics of scoping in QML. +Note that if you are adding a function that should be called by external elements, +you do not need the \l Script element. See \l {Extending types from QML#Adding new methods} +{Adding new methods} for information about adding slots that can be called externally. + \section1 Inline Script Small blocks of ECMAScript can be included directly inside a \l {QML Document} as diff --git a/src/declarative/graphicsitems/qmlgraphicsflipable.cpp b/src/declarative/graphicsitems/qmlgraphicsflipable.cpp index 9e48bf2..7719469 100644 --- a/src/declarative/graphicsitems/qmlgraphicsflipable.cpp +++ b/src/declarative/graphicsitems/qmlgraphicsflipable.cpp @@ -98,7 +98,7 @@ public: MouseRegion { anchors.fill: parent - onClicked: flipable.state = (flipable.state == 'back' ? 'front' : 'back') + onClicked: flipable.state = (flipable.state == 'back' ? '' : 'back') } } \endqml -- cgit v0.12