From fbd07cf7b756b903ab888785eb520cdbf64f38d4 Mon Sep 17 00:00:00 2001 From: Andrew den Exter Date: Tue, 15 Feb 2011 16:05:35 +1000 Subject: Document the TextInput accepted() signal. Change-Id: I30a36ba2724c9641e9cfe5ceafa651728907ef63 --- src/declarative/graphicsitems/qdeclarativetextinput.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/declarative/graphicsitems/qdeclarativetextinput.cpp b/src/declarative/graphicsitems/qdeclarativetextinput.cpp index dce7346..ddfa3aa 100644 --- a/src/declarative/graphicsitems/qdeclarativetextinput.cpp +++ b/src/declarative/graphicsitems/qdeclarativetextinput.cpp @@ -776,6 +776,15 @@ bool QDeclarativeTextInput::hasAcceptableInput() const } /*! + \qmlsignal TextInput::accepted() + + This signal is emitted when the Return or Enter key is pressed. + Note that if there is a \l validator or \l inputMask set on the text + input, the accepted signal will only be emitted if the input + is in an acceptable state. +*/ + +/*! \qmlproperty enumeration TextInput::echoMode Specifies how the text should be displayed in the TextInput. -- cgit v0.12 From 3997977cdb712042c540b143f2ce2f5376e9d1e0 Mon Sep 17 00:00:00 2001 From: Andrew den Exter Date: Tue, 15 Feb 2011 16:14:29 +1000 Subject: Use QML notation for documenting TextInput::accepted() signal. Use the name onAccepted() and refer to it as a handler rather than a signal. Change-Id: Ibd4144aa809e6d9db136187a07e9a660afa5df1b --- src/declarative/graphicsitems/qdeclarativetextinput.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/declarative/graphicsitems/qdeclarativetextinput.cpp b/src/declarative/graphicsitems/qdeclarativetextinput.cpp index ddfa3aa..88f36b4 100644 --- a/src/declarative/graphicsitems/qdeclarativetextinput.cpp +++ b/src/declarative/graphicsitems/qdeclarativetextinput.cpp @@ -776,12 +776,12 @@ bool QDeclarativeTextInput::hasAcceptableInput() const } /*! - \qmlsignal TextInput::accepted() + \qmlsignal TextInput::onAccepted() - This signal is emitted when the Return or Enter key is pressed. + This handler is called when the Return or Enter key is pressed. Note that if there is a \l validator or \l inputMask set on the text - input, the accepted signal will only be emitted if the input - is in an acceptable state. + input, the handler will only be emitted if the input is in an acceptable + state. */ /*! -- cgit v0.12