summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* Fixes warnings in QMapOlivier Goffart2009-09-221-5/+4
| | | | | | | | | | Get rid of the pages of warning you get when compiling code that uses QtConcurrent::map for instance. qmap.h:607: warning: dereferencing pointer 'y' does break strict-aliasing rules qmap.h:605: note: initialized from here Reviewed-by: Peter Hartmann
* Fix QScriptValue::strictlyEqualsSimon Hausmann2009-09-221-1/+8
| | | | | | | | strictlyEquals has to continue to work if one of the values has an engine and the other one doesn't. Use the other value's engine to construct a JSValue if possible and use JSC::JSValue::strictEqual. Reviewed-by: Kent Hansen
* Fix QScriptValue constructors without a QScriptEngineSimon Hausmann2009-09-221-36/+9
| | | | | | | Don't create JSC types as the conversion back to a string now requires an ExecState. Reviewed-by: Kent Hansen
* Merge commit 'origin/4.5' into 4.6Andreas Aardal Hanssen2009-09-222-3/+5
|\ | | | | | | | | | | Conflicts: src/corelib/kernel/qcoreapplication.cpp tests/auto/windowsmobile/test/tst_windowsmobile.cpp
| * Cached clip path not cleared correctly for ancestor that clips to shapeAndrew Christian2009-09-221-2/+4
| | | | | | | | | | | | | | | | | | Fix QGraphicsItem to clear clip path for items with an ancestor that clips to shape. Added autotest to demonstrate clipping path problem. Merge-request: 810 Reviewed-by: Alexis Reviewed-by: Andreas
| * QCoreApplicationPrivate::appendApplicationPathToLibraryPaths WinCE fixJoerg Bornemann2009-09-211-1/+1
| | | | | | | | | | | | | | | | | | | | On Windows CE the plugin path is likely to be the same as the application directory. That's why we must not compare app_location with the plugins path. The check app_libpaths->contains(app_location) should be enough. Autotest: tst_QApplication::libraryPaths Reviewed-by: thartman
* | Cleanup convertHIconToPixmap() & loadIconFromShell32()miniak2009-09-224-55/+44
| | | | | | | | | | | | | | | | Replace convertHIconToPixmap() by QPixmap::fromWinHICON() Move loadIconFromShell32() to qwindowsstyle.cpp Merge-request: 1570 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
* | * QPixmap: Add toWinHICON() & fromWinHICON() methodminiak2009-09-225-72/+80
| | | | | | | | | | | | | | | | | | | | Duplicate QPixmap <-> HICON conversion code removed from qwidget_win.cpp & qsystemtrayicon_win.cpp. Task-number: 218533 Merge-request: 1570 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
* | Remove key accelerators from Softkeys and Menus in S60.Sami Merilä2009-09-222-23/+7
| | | | | | | | | | | | | | | | | | In S60 softkeys and menu items do not support key accelerators (i.e. CTRL+X). Therefore, removing the accelerator characters from both softkey and menu item texts. Related to task QT-1505 "Make Qt dialogs look native" Reviewed by Jason Barron
* | Fix tst_QScriptEngine::throwErrorFromProcessEventsOlivier Goffart2009-09-222-2/+3
| | | | | | | | | | | | | | | | | | | | The problem is that the interpreter did not check for exception while running the "while(true){}" loop, as it deduced that none of the generated opcode would possibly generate an exception. The solution is to force a check right after we come from a timeout. Reviewed-by: Kent Hansen
* | Resubmit support for subpixel antialiasing on text in the GL2 engine.Kim Motoyoshi Kalland2009-09-228-25/+186
| | | | | | | | | | | | | | The antialiasing is currently not gamma corrected and is disabled on OpenGL ES 2.0. Reviewed-by: Samuel
* | Move 3rdparty fonts into repository.Jason McDonald2009-09-2239-0/+986075
| | | | | | | | | | | | | | | | | | | | These fonts used to be added to the qt-embedded-linux source package by the packaging scripts. As we no longer make platform-specific source packages, these files now belong in the Qt repository from which they will be added to all source packages. Reviewed-by: Trust Me Acked-by: Thiago Macieira
* | Remove remaining instances of THISYEAR placeholder.Jason McDonald2009-09-221-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Rhys Weatherley2009-09-222-0/+14
|\ \
| * | Add reconnection option to the mysql driver.Bill King2009-09-222-0/+14
| | | | | | | | | | | | | | | | | | adds MYSQL_OPT_RECONNECT to the mysql driver options. Task-number: QTBUG-4510
* | | QMatrix4x4::mapVector() to transform by top-left 3x3Rhys Weatherley2009-09-222-1/+33
|/ / | | | | | | | | | | | | | | It is useful to be able to map direction vectors by the top-left 3x3 component of a 4x4 matrix, ignoring the translation and projection components. Reviewed-by: Sarah Smith
* | Revert "Resubmit support for subpixel antialiasing on text in the GL2 engine."Rhys Weatherley2009-09-218-186/+25
| | | | | | | | This reverts commit 1b34feacef7a2d3ac005449a7cfbcb08a6bbf947.
* | Calculate scissor correctly in OpenVG engineRhys Weatherley2009-09-211-1/+1
| | | | | | | | Reviewed-by: trustme
* | The firstTimeObserver is not released if the event loop is never runBenjamin Poulain2009-09-212-8/+11
| | | | | | | | | | | | | | Previously, the firstTimeObserver was released by the event loop. This do not work if the event loop is never run. This commit amend b0016ea9a6b225757e3ee06b50e8f7d05463ddf7.
* | Clean upJoão Abecasis2009-09-213-6/+0
| |
* | Optimized GL2 engine to use scissor clipping more aggressively.Samuel Rødal2009-09-212-95/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There's no reason to stop using a scissor clip when a more complex clip is set. Instead, we can use a combination of scissoring and depth clipping to represent the final clip. When intersecting with a new clip path, if the clip path is a rectangle we simply intersect it against the scissor clip, and otherwise we intersect its bounding rect against the scissor clip and write the actual path to the depth buffer. The patch simplifies the logic in clip() quite a bit, except in the UniteClip case in which we don't care about performance anyways. It also fixes a bug which could cause rendering errors if the stencil buffer contains junk before painting. Reviewed-by: Gunnar Sletta
* | Made subpixel antialiasing in the GL2 engine work on X11 as well.Samuel Rødal2009-09-212-0/+23
| | | | | | | | | | | | Need to add alphaRGBMapForGlyph to the Freetype font engine. Reviewed-by: Kim
* | QtScript: Fix comparing QVariant and QObject.Olivier Goffart2009-09-218-1/+50
| | | | | | | | | | | | | | This add a hook inside JSC to be able to implement our own comparison function when comparing objects. Reviewed-by: Kent Hansen
* | Resubmit support for subpixel antialiasing on text in the GL2 engine.Kim Motoyoshi Kalland2009-09-218-25/+186
| | | | | | | | | | | | | | The antialiasing is currently not gamma corrected and is disabled on OpenGL ES 2.0. Reviewed-by: Samuel
* | When using Plastique style, changing the background style sheet property of aGabriel de Dietrich2009-09-212-1/+4
| | | | | | | | | | | | | | | | spinbox wouldn't set the correct background for the embedded line edit. Reviewed-by: Olivier Task-number: 232085 Task-number: QTBUG-3013
* | Doc: Indicated that press and release events occur with double clicks.David Boddie2009-09-211-5/+7
| | | | | | | | | | Task-number: 255118 Reviewed-by: Trust Me
* | Doc: Tidied up the QDesktopWidget documentation.David Boddie2009-09-211-28/+47
| | | | | | | | Reviewed-by: Trust Me
* | qdoc: Added \brief texts to all the since 4.6 functions.Martin Smith2009-09-219-17/+50
| |
* | Fix printing with glyph substitutionEskil Abrahamsen Blomfeldt2009-09-211-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If a font has substituted any of the glyphs in the string, then we cannot convert it to a string, as the glyph positions will no longer match the positions of the characters. E.g. in the case of the MS Calibri font, two subsequent t's are represented by a single glyph. Printing text in Calibri with subsequent t's will thus cause the first t to be position and sized based on the glyph representing "tt" and glyphs after this to be position based on the wrong advance and the text will look mangled, with some glyphs overlapping. Task-number: QTBUG-4445 Reviewed-by: Gunnar
* | Ensure that the menu only shows when clicking on the menu buttonAndy Shaw2009-09-211-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | In Qt 3 clicking on the toolbutton would not popup the menu, only when clicking on the arrow for the menu popup would this appear if the toolbutton had MenuPopup mode set. When a Q3ActionGroup is used and added to a toolbar then it will give a toolbutton with such a button. This patch fixes the behaviour so that only clicking on the arrow button will cause the menu to appear in this mode. Reviewed-by: Thierry
* | Refactored gl window surface a bit.Gunnar Sletta2009-09-211-37/+43
| | | | | | | | | | | | | | | | | | | | | | | | The logic was a bit messy and didn't work on Mac OS X. On Linux we also had issues with 8xxx nvidia cards which didn't render properly. The FBO is now unbound between calls to beginPaint(), which prevents other gl calls from messing it up, which is probably what was the error in the first place. In addition, on Mac OS X, we also call the upatePaintDevice() as a result of setGeometry() to force-update the dimensions of the context. Reviewed-by: Trond
* | Fix QPrintDialog with no parent and no active windowEskil Abrahamsen Blomfeldt2009-09-211-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | PrintDlgEx requires an non-null owner handle, otherwise it will fail with an "Invalid Handle" error. This caused code which popped up a print dialog as the only window in the application to fail silently and immediately return Rejected from the exec() function. To continue support for this somewhat unusual use case, we fall back to using the print dialog itself as the owner of the print dialog sheet if all else fails. Reviewed-by: Trond
* | On Mac, the posted events are processed on the first time in the loopBenjamin Poulain2009-09-212-2/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Mac OS X, we use a custom source for posted events. The first time the event loop is entered, the custom source is added to the native event dispatcher but the events are not processed. In Qt, we expect those events to be processed. To work around the problem, a new observer is added to the event loop. This observer is only triggered the first time the event loop is entered. When the observer is triggered, the posted events are sent. Task-number: QTBUG-4521 Reviewed-by: Richard Moe Gustavsen Reviewed-by: João Abecasis
* | use JSObject::inherits() instead of JSObject::isObject()Kent Hansen2009-09-216-15/+15
| | | | | | | | | | | | The functions are identical, but in recent WebKit trunk isObject() doesn't exist anymore. So this renaming is done to prepare for the import of a more recent JavaScriptCore.
* | Compile fix for non-Symbian.Alessandro Portale2009-09-211-1/+1
| | | | | | | | | | | | updateSoftKeys_sys() is now a member of QSoftKeyManagerPrivate Reviewed-by: Jason Barron
* | Get menubars working again with new softkey API.Jason Barron2009-09-212-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is an unfortunate workaround to get the menu bars working again. Previously we used the soft key role to determine what action command we should use for the softkey. Now we only use the role to determine the position (as we should) and ideally the command would be determined by checking if the action has a menu() and then forcing the command to EAknSoftkeyOptions. This would have enabled any softkey with a menu to work, but unfortunately this would require considerable effort in the menu implementation and time is short. So the workaround is to abuse object name to tell the softkey system that this key is special and should get EAknSoftkeyOptions. Reviewed-by: Alessandro Portale
* | Introduce MenuSoftKey as a standard key to the internal enum.Jason Barron2009-09-213-1/+6
| | | | | | | | | | | | | | | | QMainWindow was using the 'Done' standard softkey to represent the action for the menu bar, but that was obviously wrong and pointed out that one of hte needed standard softkeys was needed. Reviewed-by: Alessandro Portale
* | Introduce a d-pointer to QSoftKeyManager.Jason Barron2009-09-212-18/+31
| | | | | | | | | | | | | | | | Originally this was supposed to be a mostly static API, but now it looks like some more non-static members will be needed so introduce a d-pointer to store them. Reviewed-by: Alessandro Portale
* | Add a new compressable event QEvent::UpdateSoftKeys.Jason Barron2009-09-215-25/+41
| | | | | | | | | | | | | | | | | | | | | | Now that the softkey framework triggers updates on focus changed, window activated, and action added/removed/changed the softkey bar was updating many times resulting in flicker. Solve that by introducing a new event type that is posted to the softkey framework. Since we only need to update the softkeys once per event loop iteration, the event is compressible in the event loop. Reviewed-by: Alessandro Portale
* | Simplify the soft key roles of QAction.Jason Barron2009-09-2112-107/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously there were many options here that were inherited from the Qtopia implementation. It was not clear to developers which value they actually should use. A good example was the 'Next' value. In a typical wizard application, next would be on the right and 'Previous' would be on the left. However, it is also common to have 'Next' on the left and have 'Cancel' on the right. Basically what people really wanted was a way to explicitly set the right and left soft keys, but since this relies on form factor and is wrong if the screen is rotated, we choose positive and negative actions as the values for these such that they still make sense when the screen is rotated. Also this helps people who don't know if a particular action should be on the left or right, but they *do* know if their action has destructive characterisitics (negative). As a convenience for widgets in Qt that use softkeys, we create a standard softkey enumeration. That maps the actions to the correct role and has default text. Reviewed-by: Alessandro Portale
* | QWizard changed to use the new soft key API.Jason Barron2009-09-211-42/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Created an array of soft key actions that are created on the fly as buttons are needed. This moved the allocations for the actions out of the updateButtonStates() function which is called quite often so allocations should happen less often now. The signals and text should are kept in sync with the buttons. Controlling which soft keys are currently available is done when the buttons states are updated by calling addAction or removeAction. The soft key framework then picks up on these changes. Reviewed-by: Alessandro Portale
* | Change QDialogButtonBox to use the new soft key API.Jason Barron2009-09-211-106/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This simplifies the implementation of the soft keys. Introduce a hash for storing the mapping between the buttons and the actions that they represent. This allows for easy translation of the strings when the language changes. Use setFixedSize instead of hide to make the buttons invisible. This allows us to put some code in the handling of the show event and add the actions here. This should be fairly safe since even if we get multiple show events, it is still safe to add the same action again. Reviewed-by: Alessandro Portale
* | Change QProgressDialog to use the new soft key API.Jason Barron2009-09-211-9/+26
| | | | | | | | | | | | | | | | | | | | | | | | The previous version created a new QAction every time setCancelButton was called without deleting the previous instance. This version stores the action pointer in the d-ptr, but still recreates it everytime the button is changed. Also, make sure the text is updated if setCancelText is called by the user. Reviewed-by: Alessandro Portale
* | Change QErrorMessage to use the new soft key API.Jason Barron2009-09-211-30/+15
| | | | | | | | | | | | | | | | | | | | | | | | With the new softkey API it is not necessaery to call setSoftKeys with the actions you want and then to set it to 0 to clear them. The way to use the API is just call addAction() and this soft key will be valid while this is the active window. Also make sure that the text of the action is updated when retranslateUi() is called. Reviewed-by: Alessandro Portale
* | Give the soft key functionality it's own macro.Jason Barron2009-09-216-14/+18
| | | | | | | | | | | | | | | | | | Re-using QT_KEYPAD_NAVIGATION for soft keys is wrong since the two are independant concepts. This puts everything in a new macro called QT_SOFTKEYS_ENABLED. This will also insulate the embedded customers who use keypad navigation from the soft key changes. Reviewed-by: Alessandro Portale
* | Refactor soft keys implementation.Jason Barron2009-09-2120-334/+387
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Alessandro Portale Squashed commit of the following: commit dae5eda6996d48c12c4a5efd3f6042eb293bacbf Author: Jason Barron <jbarron@trolltech.com> Date: Fri Sep 18 10:32:26 2009 +0200 Only update soft keys when KEYPAD_NAVIGATION is enabled. For 4.6, let's just call these functions when keypad navigation is defined to minimize the impact on other platforms. They should probably get thier own define some day. commit 30a730553531f0f138de5eddb30413936a34fa36 Author: Jason Barron <jbarron@trolltech.com> Date: Fri Sep 18 10:30:23 2009 +0200 Add/remove the menu bar action when menu bar is added/removed. commit a83343a2870b34c228c8bc5e6274607b0e97baf6 Author: Jason Barron <jbarron@trolltech.com> Date: Fri Sep 18 10:28:55 2009 +0200 Compile fix for other platforms commit 39c9e3a0a1d3d62bf6ebd3212cfd2a81b86b9b2a Author: Jason Barron <jbarron@trolltech.com> Date: Thu Sep 17 21:37:59 2009 +0200 Fix 'softkeys' example after API re-factoring. Clean up this example and use the simplified soft key API. Now the actions are only allocated in the constructor and dynamically updated by calling addAction and removeAction. commit 314e45c33f40552db74e61755c2a3b0f8c77a41a Author: Jason Barron <jbarron@trolltech.com> Date: Thu Sep 17 21:30:32 2009 +0200 Re-factor and simplify the soft keys API. Several things here: - Move all the logic into QSoftKeyManager - Move the files into 'kernel' since it is not a widget - Remove QWidget::setSoftKey*(). Use addAction/removeAction instead - Made soft keys update on focus, window activation, and action changes. - Fixed several memory leaks where QAction's were created too often - QAction ownership pushed out to widget's - Added Select/Cancel soft keys for comboboxes and menus to be more consistent to platform look-and-feel. commit fb4c240d970262e9872dc5737df6808879143c75 Author: Jason Barron <jbarron@trolltech.com> Date: Mon Sep 7 15:49:31 2009 +0200 Merge the Symbian implementation with the other platforms nativeMenuBar It seems this has been refactored to share more code across the various platforms that support native menubars so the Symbian code can be mostly removed. commit aa55e4bcd1f009ab35c9519e18aa325fd212dd23 Author: Jason Barron <jbarron@trolltech.com> Date: Wed Aug 26 17:00:34 2009 +0200 Change filenames and move softkey stuff from 'widgets' to 'kernel'. This thing isn't a widget and therefore should not be in the 'widgets' subdirectory of gui. Also rename the files in preparation for refactoring and extending.
* | S60 native looking dialog support.Sami Merilä2009-09-219-26/+513
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Related to QTSSIXTY-63 "Make Qt dialogs look native" S60 dialog support: * Positioning according S60 rules: - in portrait dialogs at the bottom of the screen, - in landscape positioned in the center of the screen [unless device supports bottom softkeys], so that softkeys are not covered by the dialog * If dialog shows extension, then dialog is re-positioned * Dialog size: - in portrait screen wide dialog, height can change - in landscape width is the same size as width in portrait (some dialogs are maximized) * No push buttons or DialogButtonBoxes in internal qt dialogs (QWizard, QInputDialog, QFileDialog, QFontDialog, QColorDialog, QProgressDialog, QErrorMessage, QMessageBox), instead signals are remapped to softkeys. * Globally, dialogbuttonboxes are converted automatically to softkeys. OPEN: * Needs to be re-factored slightly after softkey API refactoring is finished. BUGS: QWizard layout switch is wonky - dialog is not re-sized correctly. QFontDialog will not fit into device screen (too much widgets in it). Some effort needed to be make it smaller. Cannot set one softkey at the time softkeys => Options menu and right softkey cannot be set separately [SoftKey re-factoring will help] Dialogs cannot get touch events to softkeys [SoftKey re-factoring will help] Reviewed-by: Alessandro Portale Reviewed-by: Jason Barron Reviewed-by: mread Reviewed-by: Shane Kearns
* | Performance: reduce overhead of updateMatrix() in GL2 paint engineRhys Weatherley2009-09-211-32/+45
| | | | | | | | | | | | | | | | | | | | | | The original code was performing 40 floating-point multiplications, 40 additions, and 2 divisions every time the matrix was changed. Because most of the components in the orthographic projection matrix are trivial, we can implement the same transformation with only 6 multiplications, 6 additions, and 2 divisions. Reviewed-by: Sarah Smith
* | Increase precision when normalizing vectorsRhys Weatherley2009-09-214-8/+34
| | | | | | | | | | | | | | | | | | QVector3D::normalize() and other similar functions were losing precision when qreal was float, causing vectors with small lengths to normalize to (0, 0, 0). Do the length calculations with double precision to avoid this problem. Reviewed-by: Sarah Smith
* | Accelerate drawRoundedRect() for the OpenVG paint engineRhys Weatherley2009-09-202-0/+100
| | | | | | | | | | | | | | | | Previously rounded rectangles were converted into a QVectorPath and then a VGPath. This change creates the VGPath directly without an intermediate step and was made possible by change dd3e4308. Reviewed-by: trustme