summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Add -fPIE to the Qt5Core_COMPILE_FLAGS with reduce-relocations.Stephen Kelly2012-02-101-0/+4
| | | | | | | | | | Qt requires this since 482d96a0c5d523ace63f56bda6851926b4469dd0 Change-Id: Iba783e283b17654abf46f11b81cc1641c3ce7d83 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Clinton Stimpson <clinton@elemtech.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Properly read back the actual format in xcb and xlib plugins.Samuel Rødal2012-02-108-18/+30
| | | | | Change-Id: Iccef2c4a87863b93914b84edf3a6015dad5e512a Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* More graceful handling of QSurfaceFormat::samples() with GLX.Samuel Rødal2012-02-101-1/+1
| | | | | | | | | | Earlier, if we asked for say 16 and the implementation only handled 4, we defaulted to 0 (no antialiasing). Now, we instead try a progressively lower number until we find a match. Task-number: QTBUG-22669 Change-Id: I3d89f2a302f9c6195e2d43827006fd015d981ce7 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* More graceful handling of QSurfaceFormat::samples() with EGL.Samuel Rødal2012-02-101-4/+10
| | | | | | | | | | Earlier, if we asked for say 16 and the implementation only handled 4, we defaulted to 0 (no antialiasing). Now, we instead try a progressively lower number until we find a match. Task-number: QTBUG-22669 Change-Id: I63f4b8aadf8e06713d19fdc9b9d73672162c816a Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Display QThread name for debugging.Leonard Lee2012-02-101-0/+18
| | | | | | | | Thanks to João's help. Change-Id: I9ad3035f016945bed9fdf425fc7b7edd5d20822d Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Make it possible to put QObject tracked with QWeakPointer inside QSharedPointerOlivier Goffart2012-02-102-17/+19
| | | | | | | | | | | | | | | | Do that by keeping the QWeakPointer that track QObject independent of the ones that track QSharedPointer. QSharedPointer do not touch the sharedRefCount in QObjectPrivate anymore When converting a QWeakPointer constructed from a QObject to a QSharedPointer, it will display a warning saying one should not do that. Task-number: QTBUG-22622 Change-Id: I3595e3e7401702410776c458687ab357ad9366ab Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Include winsock2.h for ntohl.Andreas Holzammer2012-02-101-0/+1
| | | | | | | | | | This fixes the compilation for Windows CE. Include Windock2.h before Windows.h. Change-Id: Iae1ab98239bb75b59c78460e0c0e48dfa1326032 Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Fix qlogging autotest for clangKai Koehne2012-02-101-0/+5
| | | | | | Change-Id: Iac82c4847554534174b5419ec78319c9ac381628 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Move all usages of Relation enum values to QAccessible::relations()Jan-Arve Saether2012-02-107-161/+117
| | | | | | | | Next step is to remove navigate(), but that has to be done in qtdeclarative first. Change-Id: I01ea1386c092446be04cc19d0f70adf53f094adc Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
* Force -fPIE on ELF if Qt is built with reduced relocationsOlivier Goffart2012-02-101-0/+6
| | | | | | | | | | | | | | | | Put in qconfig.h whether qt is compiled with reduced relocations. When using -Bsymbolic-functions (enabled by default on Qt) but not -fPIE, the comparison of the function pointers fail because the addresses are different in Qt, and in the executable. Hence we now enable -fPIE by default on qmake, and force a compilation error when it is not enabled and built with reduced relocations. Done-with: Sune Vuorela <sune@vuorela.dk> Change-Id: Ib3fdba06fab6e8a93b75b4c6cf16cc973ab335db Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Handle TouchCancel in gui and widgetsLaszlo Agocs2012-02-109-3/+109
| | | | | Change-Id: I31739840348d88ae408ac1aae2399f6328ccdd43 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Remove no longer needed ifdef Q_OS_WINCE.Andreas Holzammer2012-02-101-8/+0
| | | | | | | | There is now an implementation to qt_pixmapFromWinHICON. So use it for Windows CE too. Change-Id: Ie2f3cacd4be9209e33d49e53703c5abc95d98d09 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Add qt_pixmapFromWinHICON again for Windows CE.Andreas Holzammer2012-02-101-0/+179
| | | | | | | | | | qt_pixmapFromWinHICON is used by qfileiconprovider and qwindowsstyle. So use this one from Qt 4.8. Also put functions of qguifunctions_wince in here, because this was splitted. Change-Id: I00ffb9d66a84884f7338648982e516ca016b9bd6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Clean up qguifunctions_wince includes.Andreas Holzammer2012-02-109-14/+190
| | | | | | | | | There are leftovers from Qt 4.8 in regards of the qguifunctions_wince. The parts which where needed in widgets have been taken over into qwidgetsfunctions_wince. Change-Id: I737684a7f56ba356df89c1be77ab776bca034ae9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Add support for xlib backend X Event filtersJohn Stanley2012-02-106-5/+29
| | | | | Change-Id: Id1e7995f98395de748ce47a27365e4bdd564ea49 Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
* Add socketOptions flags to QLocalServerAndrew Stanley-Jones2012-02-104-3/+145
| | | | | | | | | | QLocalServer had no way to set socket options that more complicated servers require. The first set of options allow setting of access control on the sockets. Change-Id: If4268c66462fc2e6cf1e70b1d5f56c76d2c69228 Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>
* Update docs for QAccessibleEvent.Frederik Gladhorn2012-02-101-46/+10
| | | | | | | | This class completely changed, the old docs were still around. Change-Id: Ice7b106b33ffc60f45f7af1b4f44dc01462ee0da Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* Improvement to font database cleanupjian liang2012-02-104-33/+57
| | | | | | | | | | | | | | | | | | This patch do the following things: 1) Call QFontDatabasePrivate::free() to clean up font database before destroying the platform integration object. This is to prevent object leak which is allocated by platform plugin. 2) Allocate FontFile structure for each font registered in windows platform to prevent double free of FontFile structure. 3) qt_registerFont() will release the old handle of the registered font and replace it with the new handle. This is to prevent FontFont structure leak. Change-Id: Ib5ca20c695e1e365689fd8554f7caff6ee77a0b1 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* Compile fix QWindowsMobileStyleAndreas Holzammer2012-02-101-1/+0
| | | | | | Change-Id: Idb3f8b3cb19b0ed1f49245fa7e43f26f6faa174d Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* QHeaderView - minor bug in visualIndexAtThorbjørn Lund Martsum2012-02-101-2/+2
| | | | | | | | | | | | | | | This fixes a minor bug in VisualIndex triggered when calling resizeSection with size 0 (but not hideSection). It is mostly cosmetics - however hopefully there will soon be a minor refactoring and there is really no need to make strange code to keep a semantic bug. However it is also doubtful to make a semantic change while refactoring. Change-Id: Ide153e421fd7a634062cb74867f4a49da4bf9cd6 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Dont build printer support for Windows CE.Andreas Holzammer2012-02-101-3/+6
| | | | | | | | | Windows CE has no printing support, so we can disable this. Change-Id: I0ec83dff2d045de56d613cd676e9eb290145bf41 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Introduce QScreen::grabWindow(), deprecate QPixmap::grabWindow().Friedemann Kleint2012-02-095-54/+64
| | | | | | | WId can be local to a screen. Change-Id: I09ca71313836a34dbf33289b254c80207a956bb1 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Allow customization of qDebug output at runtimeKai Koehne2012-02-093-21/+337
| | | | | | | | | | | | | Check the QT_OUTPUT_PATTERN environment variable in the default message handler to customize the output of messages. Following place holders are right now supported: %{message}, %{type}, %{file}, %{line}, %{function} The original cleanupFuncinfo was written by Thiago Macieira. Change-Id: I6ad25baaa0e6a1c9f886105d2a93ef3310e512a9 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: David Faure <faure@kde.org>
* Initializes seqDumpPos on qiodevice.cppNick Ratelle2012-02-091-1/+2
| | | | | | | | | | | | | This was spotted by RIM static code checking team. seqDumpPos is a dummy variable which is only used on sequential mode. It is used as a simultaneous storage area of both pPos and pDevicePos when in sequential mode, to keep both in sync. They just suggested that it would be a good practice to initialize the variable, since it does not have any side effect, and there's not much value on not doing it. Change-Id: I8138729eb31df5779c91b368c2cfaecd39788f29 Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
* Add event type for TouchCancel.Laszlo Agocs2012-02-093-3/+12
| | | | | | Change-Id: Id8b68e5cb19a2a325139e3241647cc36581cf6f8 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Preserve weight and style request for multi font enginesJiang Jiang2012-02-092-5/+7
| | | | | | | | So that fallback fonts can pickup the weight/style requested instead of using the weight and style of the primary font. Change-Id: Ia592e079cad61334f21e0453412b198a900bb6b6 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
* Various documentation fixes ported from 4.8Teemu Katajisto2012-02-0910-11/+38
| | | | | | | | | | | | | | | | | | | Selected documentation fixes for qtbase from 4.8 commit 40fb4750910e23d3e7128ca8e0f1c5920b05bd5a Task-number: QTBUG-8625 Task-number: QTBUG-19808 Task-number: QTBUG-1231 Task-number: QTBUG-21073 Task-number: QTBUG-8939 Task-number: QTBUG-20399 Task-number: QTBUG-20944 Task-number: QTBUG-22095 Task-number: QTBUG-11278 Task-number: QTBUG-15653 Change-Id: Ia4f59fce7c85f04b6da953a3988f705d9d9a658a Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* Take into account shaping in findRealWindowAlbert Astals Cid2012-02-091-3/+25
| | | | | | | | | | | | | | It can happen that there is a window covering all the screen but it is shaped to only take part of the screen. If that happens, besides the condition of QRect(attr.x,attr.y,attr.width,attr.height).contains(pos) we also need to query the server for its region rectangles and make sure the cursor is inside one of those rectangles. If that does not happen we have to return 0 so the hierarchical xcb_query_tree_children xcb_query_tree_childrenntinues Change-Id: I67327672e3d854d064190b55a07bd56ade4dfddb Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Uli Schlachter <psychon@znc.in> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Eliminate a warningJiang Jiang2012-02-091-2/+2
| | | | | Change-Id: I984821d90df272b85d02c6ee0db5a89174d80873 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
* Replace Q_WS_WINCE against Q_OS_WINCE.Andreas Holzammer2012-02-092-2/+2
| | | | | | | | | | Window system Macros where deprecated so use Q_OS_WINCE for now. This code will need some refactoring, but this is the first step to it. Change-Id: I5876b80ee45d4b38ac63fc7d51e775dc70bbd485 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QSqlTableModel::insertRecord(): clean up after failed setRecord()Mark Brand2012-02-091-1/+4
| | | | | Change-Id: Ic9f314144bd3ccf4b59b9cb3f0d79f8d6f97a824 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* Remove leftover show() prototype.Andreas Holzammer2012-02-091-4/+0
| | | | | | | | | | | | In Qt4.8 this was declared in qwidget_wince.cpp. It was for auto maximizing. This would need to go into lighthouse if needed. This fixes the Windows CE compile. Change-Id: I6fe8361f745e16d9e8053ab58eb76ead0b22d261 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QSqlTableModel::setRecord(): improve handling of field mappingMark Brand2012-02-091-12/+22
| | | | | | | | | | -Only use fields where generated flag is set to true. -Require all fields to map correctly. If fields don't map, that is a sign of a programming or user error. Change-Id: Ie8474393005de6c9926b4e46985d62b194eafde2 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* QSqlTableModel::insertRecord(): correct documentationMark Brand2012-02-091-3/+3
| | | | | Change-Id: I35680f842a650493cf530c0b74894e2b45aa3c6e Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* Don't link shell32 for Windows CE.Andreas Holzammer2012-02-091-1/+3
| | | | | | | | | Windows CE normally don't come with a shell32, so its better to don't use it. Change-Id: I7198b5fadb0dfe37d1321800371110b7b407f577 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Avoid advancing animations outside the animation "tick"Gunnar Sletta2012-02-093-2/+9
| | | | | | | | | | | | | | | We have logic to prevent animations from starting in the middle of an animation as a result of a previously slow frame. This was based on current time, not the animation driver time and would cause severe jumping when custom animation drivers were being used. Also, this logic would trigger multiple animation runs per frame, which is very bad for performance, so this change introduces a threshold of 50ms to compensate for that. 50ms because that is triplebuffer limit. Change-Id: I1c7ebac30060e849d03c14d62411c2b953854d98 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Fix compile with QT_NO_OPENGL.Andreas Holzammer2012-02-093-0/+9
| | | | | | Change-Id: Icade54a6e3b43fdc9c151efbc25adcef6b7e41d6 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Introduce Q_DECLARE_OPAQUE_POINTERJoão Abecasis2012-02-096-40/+40
| | | | | | | | | | | | To hide the IsPointerToTypeDerivedFromQObject monstruosity :-) Documentation for Q_DECLARE_METATYPE and qRegisterMetaType was updated to mention requirements on registered types and how they can be circumvented for pointer types with the new macro. Change-Id: If83b037a8e2f28761eb903525e87008107298801 Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Build with QT_NO_CAST_FROM_BYTEARRAYStephen Kelly2012-02-081-1/+1
| | | | | | Change-Id: I9069b61c6247bdff323e2e5e93b70e42c3504201 Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com> Reviewed-by: David Faure <faure@kde.org>
* Fix compilation of Menubar for Windows CE.Andreas Holzammer2012-02-083-4/+7
| | | | | | | | | | | Use QApplicationPrivate::getHWNDForWidget for getting the HWND for Widgets. The Menubar needs refactoring, but the API for native Menubars is not in place yet, so fix it temporarily. Change-Id: I090cca99d19aa881c2f41b54005a65f3ae67ae68 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Add missing include of qdrawutil.hAndreas Holzammer2012-02-081-0/+1
| | | | | | Change-Id: Ifda1e3a0fbe1ee3431374722878d5cde86ef3916 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* realpath(X,0) IS supported on QNX.Nick Ratelle2012-02-081-1/+1
| | | | | | | | | Adds check for Q_OS_QNX to force QFileSystemEntry QFileSystemEngine::canonicalName() use realpath(X, 0) on QNX as well. Change-Id: Id0a32277e6d043753c42101c91a393ebedb48a0a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fixed CustomDashLine drawing bug.Samuel Rødal2012-02-081-1/+3
| | | | | | | | | | | The bug was caused by attempting to stroke an empty subpath. If there have been no line-to's emitted we should not try to join the start and end of that line segment. Task-number: QTBUG-23248 Change-Id: I38b7e955ed6683f8fc25f9551e93b4f472c022bf Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com> (cherry picked from commit 593947ba70188df3d33efe031fab2fd255faa8b9)
* Use qgetenv instead of getenv.Andreas Holzammer2012-02-081-1/+1
| | | | | | | | | Use the Qt Version because platforms like Windows CE don't support getenv. Change-Id: I95ca4d7194e09889ab228af80e679a3c34479e41 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Treat pointers to QObject derived types in QVariant specially.Stephen Kelly2012-02-081-10/+62
| | | | | | | | | | | | | | | | It is possible to do this for example: QVariant v = QVariant::fromValue<MyCustomQObject*>(); QObject *object = v.value<QObject*>(); This means that if a QVariant contains a pointer to a QObject derived type, third parties can extract a QObject* and use its properties without knowing the concrete type. This is a source compatible change. Change-Id: Iee9a9437e99cc2f40d1a4bfea47275482ef7161f Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
* Mac: Fix compilation with -qtnamespaceKai Koehne2012-02-081-0/+4
| | | | | Change-Id: I85559b6698103eef865464a355d9b00012dcbd5f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QSqlTableModel::setRecord(): emit dataChanged() consistentlyMark Brand2012-02-081-10/+5
| | | | | | | | | | | | | | | Previously, if any fields in the supplied record could not be matched with a column in the target table, dataChanged() was supressed for all columns for OnManualSubmit. This is not good because it prevents other views from noticing the fields that *do* change. It's simplest and probably more efficient just to emit dataChanged() once for the whole row. Fewer signals need to be processed and in typical cases much or all of the row is likely to be changed anyway. Change-Id: Ib56bf9a18e51b9cb85771acefcb2bf26e295a54e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* QSqlTableModel::setRecord(): do not try to detect value changesMark Brand2012-02-081-9/+2
| | | | | | | | | | | | | | | | | | | | | | | In an apparent attempt to be economical with emitting dataChanged() and submitting SQL to the databse, setRecord() compares each field value of the record with the old value, taking action only when a difference is detected. Several complaints against this code are: -The comparision does not work on float type. -It is really up to the application and database to decide this. The model should make few assumptions. The application has the option to omit fields from the record that should be ignored. -The current behavior seems to assume that the "old" values are the current state of the database, but the database may have changed since the model was last refreshed. -The code compares the value from record(), which probably corresponds to the EditRole, with the DisplayRole value from data(). Change-Id: I11477c185eb411d442144dc682893d0df12d03d5 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* QSqlTableModel::setData(): submit() instead of updateRowInTable()Mark Brand2012-02-081-10/+3
| | | | | | | | | | Use submit() instead of calling updatRowInTable(). The effect is exactly the same. Submit() invokes submitAll() which invokes updateRowInTable(). The cache is purged and select() is called only on success. Change-Id: I3de9a3d6acf802ee6594d034a9e261e53637995d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* QSqlTableModel::setData(): call dataChanged() before select()Mark Brand2012-02-081-2/+1
| | | | | | | | | Emit dataChanged() before a possible new select instead of after. The select reinserts all the rows, emitting signals for that, so there isn't any point to dataChanged() afterwards. Change-Id: I698a0d385f97104891343d94cc27e4ecf3a7233c Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>