source: trunk/src/testlib/qtestevent.qdoc@ 938

Last change on this file since 938 was 846, checked in by Dmitry A. Kuminov, 15 years ago

trunk: Merged in qt 4.7.2 sources from branches/vendor/nokia/qt.

  • Property svn:eol-style set to native
File size: 6.6 KB
Line 
1/****************************************************************************
2**
3** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
4** All rights reserved.
5** Contact: Nokia Corporation ([email protected])
6**
7** This file is part of the documentation of the Qt Toolkit.
8**
9** $QT_BEGIN_LICENSE:FDL$
10** Commercial Usage
11** Licensees holding valid Qt Commercial licenses may use this file in
12** accordance with the Qt Commercial License Agreement provided with the
13** Software or, alternatively, in accordance with the terms contained in a
14** written agreement between you and Nokia.
15**
16** GNU Free Documentation License
17** Alternatively, this file may be used under the terms of the GNU Free
18** Documentation License version 1.3 as published by the Free Software
19** Foundation and appearing in the file included in the packaging of this
20** file.
21**
22** If you have questions regarding the use of this file, please contact
23** Nokia at [email protected].
24** $QT_END_LICENSE$
25**
26****************************************************************************/
27
28/*!
29 \class QTestEventList
30 \inmodule QtTest
31
32 \brief The QTestEventList class provides a list of GUI events.
33
34 QTestEventList inherits from QList<QTestEvent *>, and provides
35 convenience functions for populating the list.
36
37 A QTestEventList can be populated with GUI events that can be
38 stored as test data for later usage, or be replayed on any
39 QWidget.
40
41 Example:
42 \snippet doc/src/snippets/code/doc_src_qtestevent.qdoc 0
43
44 The example above simulates the user entering the character \c a
45 followed by a backspace, waiting for 200 milliseconds and
46 repeating it.
47*/
48
49/*! \fn QTestEventList::QTestEventList()
50
51 Constructs an empty QTestEventList.
52*/
53
54/*! \fn QTestEventList::QTestEventList(const QTestEventList &other)
55
56 Constructs a new QTestEventList as a copy of \a other.
57*/
58
59/*! \fn QTestEventList::~QTestEventList()
60
61 Empties the list and destroys all stored events.
62*/
63
64/*! \fn void QTestEventList::clear()
65
66 Removes all events from the list.
67*/
68
69/*! \fn void QTestEventList::addKeyClick(Qt::Key qtKey, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
70
71 Adds a new key click to the list. The event will simulate the key \a qtKey with the modifier \a modifiers and then wait for \a msecs milliseconds.
72
73 \sa QTest::keyClick()
74*/
75
76/*! \fn void QTestEventList::addKeyPress(Qt::Key qtKey, Qt::KeyboardModifiers modifiers = Qt::NoModifier, int msecs = -1)
77
78 Adds a new key press to the list. The event will press the key \a qtKey with the modifier \a modifiers and then wait for \a msecs milliseconds.
79
80 \sa QTest::keyPress()