aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* Immediatley delete QV8QObjectResource objects to reduce memory leaksThomas McGuire2012-08-241-2/+6
| | | | | | | | | | This reduces memory leaks when deleting the v8 engine. Otherwise, the memory would only be reclaimed during a full GC run, which might not happen at all. Change-Id: Iac34bad1f2280adc530d3b3d7a074c5d022005a4 Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com> Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Document the vTable hack.Thomas McGuire2012-08-241-0/+8
| | | | | | | This was not immediately obvious, so better document this clever trick. Change-Id: I0d4a06396b9a709b29b46726d9a65d53600e3fa2 Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Fix warnings in QtQmlMatthew Vogt2012-08-245-11/+14
| | | | | Change-Id: Ibba3b8e878257f7019bdc90a1344462b77f95a21 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Fix doc linksBea Lam2012-08-243-8/+9
| | | | | Change-Id: Iafbcd39472f3e6f12169ae1a17b4a040dbb9a8a4 Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Improvements for coding conventions docsBea Lam2012-08-242-63/+3
| | | | | | | | | | | | Shouldn't advise using "__" for "private" properties since this mightn't be the best solution. This doesn't work with the onXChanged handler syntax. Also grouped and dot property syntax are both valid. We use both throughout our code. Change-Id: Ibd86f20136dc0e7225558e234afb79f566ca1039 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Link to Coding Conventions pageBea Lam2012-08-242-3/+4
| | | | | Change-Id: I4c2870bf37ea1f9f110ced4120d4a622096d8dfe Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
* Fix assert when a VisualDataModels context has been invalidated.Andrew den Exter2012-08-241-2/+9
| | | | | | | | | | | Verify the context is valid before attempting to access its engine. The context should normally be valid but there is a small window between a delegate item being released and the DeferredDelete event being processed when it is not. Task-number: QTBUG-26949 Change-Id: I79f3affaed8904cbe0974476010b68305666cd29 Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Avoid dynamic lookup of signal handler argumentsMichael Brasser2012-08-2416-289/+472
| | | | | | | | | | | Rewrite signal handlers to include the parameters in the rewrite. Also check whether parameters are actually used when possible, and if not don't provide them to the expression. Change-Id: I7d65c05f4639979dd61035cf7478119ef7647c25 Reviewed-by: Matthew Vogt <matthew.vogt@nokia.com> Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Increase test coverage for V4Matthew Vogt2012-08-235-4/+48
| | | | | | | | Add test for integer operations, Math functions and exercise some previously uncovered code. Change-Id: Idff3f3672498775ac117ca98bf34b0fe96cbf760 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Doc: Tidied links, titles, and HTML pages.Jerome Pasion2012-08-239-59/+38
| | | | | | | | -used "Qt Quick" and "Qt QML" to refer to the module -qtquick-index.html and qtqml-index.html for the landing pages Change-Id: I1569949f7875ac6008a5b80a169e327f93f330ae Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Fixes a reference in the Animation docs.Alan Alpert2012-08-231-1/+1
| | | | | | | repeat was renamed to loops long ago Change-Id: Iaaabc155aa16e92367dee2082974856769bad90a Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Remove some incorrect animation docsBea Lam2012-08-231-17/+13
| | | | | | | Task-number: QTBUG-23233 Change-Id: I2f0b65ff4553f49e9248ead33a6a06f2076e9a25 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Document various undocumented attributes of QQuickItemBea Lam2012-08-231-101/+951
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add docs for various properties and methods that are public but weren't documented. Also marked various things that shouldn't be documented as \internal. Newly documented attributes in C++ API include: - x, y, z, implicitWidth/Height, baselineOffset - transformOrigin, rotation, scale - stackBefore(), stackAfter() - mapTo*(), mapFrom*(), mapRectTo*(), mapRectFrom*() - childItems(), childAt() - updatePolish() and polish() - state - opacity, visible, enabled - mouse, hover, wheel, key, touch and grab event handlers - drag and drop event handlers - acceptedMouseButtons(), filtersChildMouseEvents(), acceptHoverEvents(), grabMouse, ungrabMouse() - focus, activeFocus, isFocusScope(), scopedFocusItem() - methodInputEvent(), inputMethodQuery() - Flag enum, setFlags(), flags() - window() Newly documented attributes in QML API include: - smooth, antialiasing - baselineOffset Change-Id: If8596b2a488e6ae37a3eb1f7d6dd0911479e9c0e Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
* Make connectNotify() work with QMLThomas McGuire2012-08-2210-45/+122
| | | | | | | | | Call connectNotify() and disconnectNotify() in QQmlNotifierEndPoint, which works for QML signal handlers and for QML bindings. Task-number: QTBUG-11284 Change-Id: Ic9a08ee6687e5c7e606f315c8fb30eec1493cd83 Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Trim trailing whitespace.Stephen Kelly2012-08-226-73/+73
| | | | | Change-Id: I3d268d3ce8d73c7287f51abe9a28c165cb75acb9 Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Fix signal offset in dynamic sig param lookupChris Adams2012-08-221-3/+2
| | | | | | | Related to 4317c442fd492121e2fc037a39b40653bbc34294 Change-Id: I6aa505b9dc13813d4996c0b5761e9c3e5eea0292 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Export QV8ValueTypeWrapper.Aaron McCarthy2012-08-221-1/+2
| | | | | | | This is required to implement value types in other modules. Change-Id: I0d59abb321b046efbaa73a5dcd24b72ee343fba7 Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Fix snippets to compile to ensure they are validBea Lam2012-08-2221-851/+20
| | | | | | | | | Also deletes snippets that are no longer used by docs. Task-number: QTBUG-26637 Change-Id: I63e129f3169ae78aeb7ac840b6f5b5925dbd06b4 Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
* Link to "Deploying QML Applications"Bea Lam2012-08-221-0/+1
| | | | | Change-Id: Ic5403ac972ff71648a8f957baec292a0a207b00c Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Fix V4 calculations that vary from V8 resultsMatthew Vogt2012-08-222-8/+100
| | | | | | Task-number: QTBUG-24706 Change-Id: I4475a772c5cd92776f2cb73dab9bc06ae4c019fa Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Fix compilation on Linux with gcc-4.6Sean Harmer2012-08-211-7/+10
| | | | | | | | | Also make use of the seed. Change-Id: I03bd961489d95504bf973c02d51979904fbd9b1c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Kent Hansen <kent.hansen@nokia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Fix compilation on OSX 10.6Sean Harmer2012-08-211-2/+2
| | | | | | | OS X 10.6 does not support the GL_ARB_framebuffer_sRGB extension. Change-Id: Ifea8eaf3ffca6242d908538afeb983131a113c73 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Use object identity to detect cycles in JS-to-C++ type conversionKent Hansen2012-08-204-34/+39
| | | | | | | | | | | | | | | | | | | | | | | | The documentation for v8::Object::GetIdentityHash() states that the hash value is not guaranteed to be unique (the current implementation just returns a random number). Hence, the hash value should not be used to determine whether an object has already been visited during type conversion; in the worst (and non-deterministic) case, the conversion will be "cut off" prematurely (due to identical hash values for two different objects), resulting in data loss. Instead, represent the visited objects as a set of V8 object handles. This is safe since the type conversion is always done on the stack, within a handle scope. Use v8::Object::GetIdentityHash() merely to implement the qHash() specialization needed for the set. V8 already provides an operator==() for handles, and it is documented to return true "if the objects to which they refer are identical", which is the behavior required by the set implementation. Task-number: QTBUG-21681 Change-Id: I1f2a1eee8f7c197c02c2ffeaaa1fc0274e8ab740 Reviewed-by: Michael Brasser <michael.brasser@nokia.com> Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
* Get rid of engine-wide state of visited objects for type conversionKent Hansen2012-08-204-42/+58
| | | | | | | | Pass the state through to internal conversion functions instead. Change-Id: Ifab9a9472d7271ee5da103ed915427dfd4f2b15b Reviewed-by: Michael Brasser <michael.brasser@nokia.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
* Add internal documentation and comments to QQuickListCompositor.Andrew den Exter2012-08-201-0/+341
| | | | | Change-Id: Idc140a8a83502a9d2d10591d8f3179f130dca53a Reviewed-by: Bea Lam <bea.lam@nokia.com>
* setImplicitWidth/Height should be publicBea Lam2012-08-201-2/+2
| | | | | | | They are used as property setters. Change-Id: Id7461277f19b495cced04e7919f234b0917eca80 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Add missing QT_{BEGIN,END}_NAMESPACEKent Hansen2012-08-171-0/+4
| | | | | Change-Id: Id924df99bd000ca5e7ffbef122c0087733f53685 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
* Reduce memory consumption in QV4Bindings::BindingMatthew Vogt2012-08-174-64/+54
| | | | | | | | As with QV8Bindings::Binding, access details from the QML IR instruction object rather than storing a copy of the values. Change-Id: I2b629ee1b06ed74c7b38e6d047ef6a98acd45086 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Compile on OpenGL ES2 when using Khronos headersSean Harmer2012-08-162-1/+24
| | | | | | | | | | | | | | This change is needed to allow qtdeclarative to build with change https://codereview.qt-project.org/#change,28334 as OpenGL ES 2 and the EXT_sRGB do not define the symbol GL_FRAMEBUFFER_SRGB. Also use symbols defined by OES extensions where needed. The #defines will be removed in a follow-up commit once 28334 has been merged. Change-Id: I1c4e5297c29ecf723463da7fbfe353628c4c35ef Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Document QJSEngine's lack of exception handling APIKent Hansen2012-08-161-3/+7
| | | | | | | | | | | | Since we consider throwing non-Error values an edge case, we decided not to add a an exception handling API (like QScriptEngine::hasUncaughtException() or v8::TryCatch) yet. Document this limitation in QJSEngine::evaluate(). Task-number: QTBUG-25857 Change-Id: I7f4869a152f176e613e3e8d2f81efeae198bd560 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
* Remove redundant QT_NO_ACCESSIBILTY.Frederik Gladhorn2012-08-162-6/+0
| | | | | | | The whole file is already ifdef'ed out. Change-Id: I0456fcb8bd1440787aa5a16ca4c0c0234aea594c Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* Fix crash in signal change notification overrideChris Adams2012-08-161-7/+45
| | | | | | | | | | | | | | | Manual overrides of automatically generated property change notification signals can cause crashes. They also don't work properly in the situations where they don't crash. This patch ensures that it is now a compile error to attempt to override a signal with a manual signal or slot. Note that this includes signals defined in superclasses. Task-number: QTBUG-26723 Task-number: QTBUG-26818 Change-Id: I4ecf448ce9de5d97526606126991e280debea2d6 Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Move docs closer to the members that they documentBea Lam2012-08-162-717/+694
| | | | | | | | | | This will make it easier to add docs for undocumented members in a later change. Includes some minor doc improvements. Change-Id: I809e1382297af604f7cac3abd4fed4a8e4e55967 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Reduce memory consumption of source coordinatesMatthew Vogt2012-08-1636-156/+186
| | | | | | | | | | Reduce memory consumption by storing source location coordinates as 16-bit variables (in run-time structures). Also modify qmlmin to restrict line lengths so that the column bound is not normally exceeded. Change-Id: I08605626ffbdf081b6da2aea1116bdfe24998572 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Remove the use of QWidgetStar from QtQml.Stephen Kelly2012-08-153-14/+3
| | | | | | | | | The enum value can be removed so that it can be replaced in functionality with QMetaType::PointerToQObject. There is no advantage to QtDeclarative knowing that a value is a QWidget pointer. Change-Id: I14530132bc37fbb0dc55ba8aaa5bb68db0d87bad Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Three scene graph examples with docs.Gunnar Sletta2012-08-134-4/+9
| | | | | | | | How to make a custom QSGGeometry, how to use QSGSimpleMaterial and how to use render with raw GL. Change-Id: I3e5a32b6ae12d7d781c11050ed26a54845e92cca Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Fix the dependencies of QQuickTest.Stephen Kelly2012-08-111-1/+2
| | | | | | | | | | It consists of only one public method whose API only depends on QtCore headers. Make everything else 'private' in the sense of what is communicated by the buildsystem. Task-number: QTBUG-26753 Change-Id: Id9d78339173c8f3f733103325c6593b8960a0585 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* make use of QT_PRIVATE to specify private Qt dependenciesOswald Buddenhagen2012-08-113-9/+3
| | | | | Change-Id: Ia6bf273ff8ed63e13ea9f5c469b5f8e2702a4ee7 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* follow rename of qt_module_config.prf to qt_module.prfOswald Buddenhagen2012-08-115-5/+5
| | | | | Change-Id: I8a13b3aca195b9e8331478d73cd338ab66d65d1f Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Permit value types with metatype IDs >= QMetaType::UserMatthew Vogt2012-08-1019-207/+201
| | | | | | | | | Remove the assumption that value types must be types defined by Qt, having metatype IDs below QMetaType::User. Task-number: QTBUG-26352 Change-Id: Ib5a56ff2e7892e82adf17a3a1e7517a0c9fe0534 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Remove remnants of QQmlImageProviderKent Hansen2012-08-092-2/+1
| | | | | | | | QQmlImageProvider was renamed to QQuickImageProvider quite some time ago. Change-Id: I2f737f1e2a543c0abb0f45170499c41de25cf696 Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Improve main QtQml and QtQuick doc pagesBea Lam2012-08-094-119/+76
| | | | | | | | | | | Make the content of the two pages more consistent with one another. Also improve the reference documentation sections and fix some links. Also the apireferences.qdoc page is not necessary. Change-Id: I01c5b3757c2ec03b1365e4c9c348e33e06f8315f Reviewed-by: Chris Adams <christopher.adams@nokia.com>
* Fix default property docsBea Lam2012-08-091-8/+5
| | | | | | | Item's default property is data. Change-Id: I60577f4cfbe954ab3311703915f43fecf4ed9bf2 Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Change error messages to reflect new module terminologyChris Adams2012-08-092-6/+6
| | | | | | | | | | | | | Previously, modules which registered types into a protected type namespace were known as "strict" modules; now they are known as "identified" modules. This commit also adds a unit test to ensure that the module identifier directive is the first command in the qmldir file. Change-Id: I90e9d2c5b51ecb2b9d058c9fe9d9310fd3cd4f45 Reviewed-by: Matthew Vogt <matthew.vogt@nokia.com> Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Allow invokable functions of value-type classes to be calledChris Adams2012-08-097-29/+936
| | | | | | | | | | | | Previously, invokable functions of value-type classes were returned as properties. This commit fixes that bug by allowing such functions to be invoked normally. It also improves copy-value type handling. This commit also ensures that QMatrix4x4 value types are constructed with qreal values as this is the storage type used internally. Change-Id: Iab0fe4c522ed53d60154e8a8d46dda925fb9f4de Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Ensure that copy sequences can be passed as argumentsChris Adams2012-08-093-1/+18
| | | | | | | | | | | | Previously, automatic conversion from JS array to sequence copy resource was not performed in the case where the array was passed as a parameter to a QObject function invocation. This commit adds code to check if the parameter type is a sequence type - and if so, and if the value is a variantlist, we convert it to a sequence of the appropriate type. Change-Id: I3cc3e2f95604bc71d1d8d237e1acffa1e03b78ba Reviewed-by: Glenn Watson <glenn.watson@nokia.com>
* Fix test failures in Qt Location with string lists.Glenn Watson2012-08-092-3/+12
| | | | | | | | | | | | | Cloning the V8 prototype introduces some unexpected behaviour in the way string lists are used in Qt Location. Instead, leave the prototype intact and used a named property accessor to return the sort method for sequence wrappers. A test case will be added to declarative once a more isolated test case has been created. Change-Id: I533a66f60af4394a2cc8c938fdfc13bd193f0065 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* canvas-related doc fixesBea Lam2012-08-092-170/+179
| | | | | | | | | | - Fully qualify names in \qml* commands - Remove unnecessary 'void' return types in \qmlmethod commands - Remove unnecessary module and type qualifiers from links - Document Canvas::onImageLoaded() Change-Id: I32d1a7a54c407ae98b60857780f5536c6d52fca2 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* Document some undocumented AnimatedSprite functionsBea Lam2012-08-091-0/+27
| | | | | Change-Id: If6ac34a989d5770b1f3e2481a01ee57ad89f7707 Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
* Various small doc fixes and improvementsBea Lam2012-08-096-33/+21
| | | | | | | | | | Adds some missing docs and fixes some incorrect doc references. Also removes AnimatedImage docs that were exactly the same as those in base Image type docs. Change-Id: I1357d3c00e63f1b08683bb78246de93dcc0dac7f Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>