Fixes bug #755 - Method "void QInputContext::setFocusWidget(QWidget*)" missing
Also added an unit test. http://bugs.pyside.org/show_bug.cgi?id=755 Reviewed by Hugo Parente <hugo.lima@openbossa.org> Reviewed by Luciano Wolf <luciano.wolf@openbossa.org>
This commit is contained in:
parent
e24401e586
commit
2400157808
3 changed files with 23 additions and 2 deletions
|
|
@ -4142,8 +4142,6 @@
|
||||||
<include file-name="QTextFormat" location="global"/>
|
<include file-name="QTextFormat" location="global"/>
|
||||||
</extra-includes>
|
</extra-includes>
|
||||||
<enum-type name="StandardFormat"/>
|
<enum-type name="StandardFormat"/>
|
||||||
<!-- ### See bug 755 -->
|
|
||||||
<modify-function signature="setFocusWidget(QWidget*)" remove="all"/>
|
|
||||||
<modify-function signature="filterEvent(const QEvent*)">
|
<modify-function signature="filterEvent(const QEvent*)">
|
||||||
<modify-argument index="1" invalidate-after-use="yes"/>
|
<modify-argument index="1" invalidate-after-use="yes"/>
|
||||||
</modify-function>
|
</modify-function>
|
||||||
|
|
|
||||||
|
|
@ -81,6 +81,7 @@ PYSIDE_TEST(qgraphicsitem_test.py)
|
||||||
PYSIDE_TEST(qgraphicsproxywidget_test.py)
|
PYSIDE_TEST(qgraphicsproxywidget_test.py)
|
||||||
PYSIDE_TEST(qgraphicsscene_test.py)
|
PYSIDE_TEST(qgraphicsscene_test.py)
|
||||||
PYSIDE_TEST(qimage_test.py)
|
PYSIDE_TEST(qimage_test.py)
|
||||||
|
PYSIDE_TEST(qinputcontext_test.py)
|
||||||
PYSIDE_TEST(qinputdialog_get_test.py)
|
PYSIDE_TEST(qinputdialog_get_test.py)
|
||||||
PYSIDE_TEST(qitemselection_test.py)
|
PYSIDE_TEST(qitemselection_test.py)
|
||||||
PYSIDE_TEST(qlayout_ref_test.py)
|
PYSIDE_TEST(qlayout_ref_test.py)
|
||||||
|
|
|
||||||
22
tests/QtGui/qinputcontext_test.py
Normal file
22
tests/QtGui/qinputcontext_test.py
Normal file
|
|
@ -0,0 +1,22 @@
|
||||||
|
|
||||||
|
import unittest
|
||||||
|
|
||||||
|
from PySide.QtGui import QPushButton
|
||||||
|
from helper import UsesQApplication
|
||||||
|
|
||||||
|
class QInputContextTest(UsesQApplication):
|
||||||
|
|
||||||
|
def testSetFocusWidget(self):
|
||||||
|
widget = QPushButton()
|
||||||
|
widget.show()
|
||||||
|
|
||||||
|
context = self.app.inputContext()
|
||||||
|
self.assertEqual(context.focusWidget(), None)
|
||||||
|
|
||||||
|
context.setFocusWidget(widget)
|
||||||
|
self.assertEqual(context.focusWidget(), widget)
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
unittest.main()
|
||||||
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue