~ubuntu-branches/ubuntu/oneiric/pyside/oneiric

« back to all changes in this revision

Viewing changes to tests/qtgui/qmainwindow_test.py

  • Committer: Bazaar Package Importer
  • Author(s): Didier Raboud
  • Date: 2010-09-27 21:01:06 UTC
  • mfrom: (1.2.1 upstream) (6.1.3 experimental)
  • Revision ID: james.westby@ubuntu.com-20100927210106-m1nrq8vmd3exqb9o
Tags: 0.4.1-0ubuntu1
* New 0.4.1 upstream release. (LP: #648612)
  - Add some 0.4.1 symbols.

* Patches:
  - u_c130273_fix_py25_QtScript_property.patch
    Remove, was from upstream.
  - u_20e226b_fix_missing_qcoreapplication_arguments_method.patch
    Remove, was from upstream.
  - u_268bf77_fixed_signal_signature_parser.patch
    Remove, was from upstream.
  + libPythonVersionPostfix.patch: Refresh
  + usePySpecificShiboken.patch: Refresh
  + lessBuildVerbosity.patch: Refresh

* Bump the B-D chain versions.
* Make sure the private.py is installed in QtCore module.
* Build against Qt 4.7.
  - Add libqtwebkit-dev
  - Drop QtMultimedia module.
  - Add the QtDeclarative package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
import unittest
2
 
import sys
3
 
 
4
 
from PySide import QtGui
5
 
from PySide import QtCore
6
 
 
7
 
from helper import UsesQApplication
8
 
 
9
 
class MainWindow(QtGui.QMainWindow):
10
 
    def __init__(self):
11
 
        QtGui.QMainWindow.__init__(self)
12
 
 
13
 
        self.createToolbar()
14
 
 
15
 
    def createToolbar(self):
16
 
        pointerButton = QtGui.QToolButton()
17
 
        pointerToolbar = self.addToolBar("Pointer type")
18
 
        pointerToolbar.addWidget(pointerButton)
19
 
 
20
 
 
21
 
class TestMainWindow(UsesQApplication):
22
 
 
23
 
    def testCreateToolbar(self):
24
 
        w = MainWindow()
25
 
        w.show()
26
 
        QtCore.QTimer.singleShot(1000, self.app.quit)
27
 
        self.app.exec_()
28
 
 
29
 
 
30
 
if __name__ == '__main__':
31
 
    unittest.main()
32