| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
The latter has the advantage of allowing the use of a real type for the
tag, instead of the generic flag/flag2 boolean accessors.
Change-Id: Icc9e854ce4af3eb5808a4bed45aa22f377e223da
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
| |
clang-tidy -p compile_commands.json $file -checks='-*,modernize-use-default-member-init,readability-redundant-member-init'
-config='{CheckOptions: [{key: modernize-use-default-member-init.UseAssignment, value: "1"}]}' -header-filter='qtdeclarative' -fix
Change-Id: I705f3235ff129ba68b0d8dad54a083e29fcead5f
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
|
|
|
|
|
|
|
|
| |
This helps in making it clear when an index is a plain old number and
when it consists of an encoded value type index.
Change-Id: Ic50d95caf244ed0ee2d62bdba53910a371cfee04
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
Pass property reads/writes through utility functions in QQmlProperty,
which in turn will try to use accessors when available (and no
interceptors have to be called).
Change-Id: I60ecfc202b6024bfe4a33206a46299787b152546
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Same idea as the read accessors, but with a slight difference: the
property setters do emit signals, so we can't do a direct property write
and have to call the setter. However, it does circumvent the meta-calls.
There is one gotcha: if a property is intercepted (e.g. by a Behavior),
we still have to do the meta-call in order to dispatch the write to the
interceptor.
According to valgrind, this saves 138 instructions on x86 for every
"accessible" property write.
Change-Id: I07dbac95613415559ffa1691734a5af7c84721fc
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
| |
Change-Id: I93bc5951d555f799bb956020433d3087504e8f9f
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
| |
From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see
http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/
Updated license headers to use new LGPL header instead of LGPL21 one
(in those files which will be under LGPL v3)
Change-Id: Ic36f1a0a1436fe6ac6eeca8c2375a79857e9cb12
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
Fold the isAddedToObject flag into the nextBinding pointer.
Reorder the members to avoid holes in the data.
Change-Id: I0a216940f52020a5d48a6ed05cc236c248161b08
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Refcounting our bindings greatly simplifies our memory management
of the objects and ensures we safely clean them all up. In addition,
it allows us to remove the m_mePtr and weak reference handling from
QQmlAbstractBinding as we can safely handle this through the same
mechanism.
Change-Id: If23ebc8be276096146952b0008b62018f5d57faf
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
|
| |
This removes the need to save some bits in the abstract binding
object, and should make it easier to move QQmlAbstractBinding
over to be reference counted.
Change-Id: Ib46cb3217f3dc462f1dcaa6153d90ea2f7401f48
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
This unifies some more code between the different binding
classes
Change-Id: I891dc9358cf9598a0c1e21df8a62d6f8a4193985
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
| |
Change-Id: I912d7665b49c8e9b2d38e78bfcfc4b3d39ca7459
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
| |
Change-Id: Ib8a222c26316ad31699d3becaa945ac4035e437b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
| |
It's only ever called on QQmlBinding objects.
Change-Id: I50dd2996db9644e0df14ec930de17a7e621a0f47
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
Reduce the number of setBinding/removeBinding overloads and
simplify their internal handling.
Change-Id: I87174a3b2dc0ecb8380e8fc28f8969fbf475c728
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
Instead call setTarget directly and properly resolve the required
QQmlPropertyData. Saves some memory for bindings to value types.
Change-Id: I542b456685955add7d395764ff85cb3098b3f208
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
Rename QQmlAbstractBinding::object() and propertyIndex() to
targetObject() and targetPropertyIndex()
Change-Id: Ic50da69e7a7c6412b5abb36f433be046e6566763
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
|
| |
it's rather hard to maintain, and not really worth it. I believe
we can more easily save the one pointer in other places with
easier to maintain code.
Change-Id: Iaba2d62b82ebe58947fa35b0812b4c70f318007a
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
| |
The DestroyMode was not used at all anymore.
Change-Id: I04b7fa2282d8257af55062a20c647ea3229a27b5
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
|
| |
Qt copyrights are now in The Qt Company, so we could update the source
code headers accordingly. In the same go we should also fix the links to
point to qt.io.
Change-Id: I61120571787870c0ed17066afb31779b1e6e30e9
Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
|
|
|
|
|
|
|
|
|
| |
- Renamed LICENSE.LGPL to LICENSE.LGPLv21
- Added LICENSE.LGPLv3 & LICENSE.GPLv2
- Removed LICENSE.GPL
Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0
Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
|
|
|
|
|
|
|
|
|
| |
* Get rid of members in QQmlCompiledData that were used by the VME
and are now unused
* Get rid of QQmlVME friend declarations that are not needed anymore
Change-Id: I11b4b6f0b4b0b60edf92a1256be3d0d44d76bbc9
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
| |
QmlObjectCreator -> QQmlObjectCreator
Change-Id: I23da2d9c7fa0dcd760f5cc695c1759b44d1e72f0
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Errors for example in signal declarations are usually reported in the loader
thread, during property cache construction. This patch separates out the
property cache population into QQmlPropertyCacheCreator, runs it from the
loader thread and reduces the QQmlObjectCreator to merely set the properties/bindings/
functions on the object.
This also enables location tracking for signal declarations and their error reporting.
Change-Id: Ief1ffbb3113f8279a50d1a12dab8dbe096702a60
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The goal is to parse QML and JavaScript binding expressions/functions in one
go and generate data structures that allow for the parsing to happen in a thread
and the instantiation of the object tree in another thread, just reading from
the generated data structures. This will replace qqmlcompiler and the VME.
This new way of loading QML is currently hidden behind the QML_NEW_COMPILER=1
environment variable. There's lots of work left to fill in the gaps in object
construction, Component support, Component.onComplete, error messages, etc. etc.
Change-Id: I5e40643cff169f469f0b6ce151584ffee5ca5e90
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Only 2010 and newer ship stdint.h, so for 2008 we have to provide a little
stdint.h compat header, for some of the third-party code we import. Our own
Qt code this patch changes to use quint* types instead.
* Include math.h and float.h for some math functions.
* disable the JIT on Windows CE for now.
* Change use of intptr_t to qintptr in Qt code. intptr_t is in inttypes.h,
except that with VS 2008 it is indirectly available through stdio.h. Let's
avoid the mess and just use the qt type, that's always available.
Change-Id: I19055edd89e0a6b147d9edbb3b711798ed3c05a5
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
| |
Change-Id: I2ab2818159c60b199cae4f7573ea47b01a178e7b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
| |
This class tries to optimise binding compilation with v8. With the
approach in v4 where we don't rewrite binding expressions anymore,
this is not required anymore.
Change-Id: I616aeeba85bc17a950d4c7341b3042ed8aa42bff
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
| |
A few things overlooked. Also adjust the numbering in one enum
to fix a crash.
Change-Id: Iedf641452f6f14ffc36d548d970079f0d6024bb6
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
| |
Change-Id: I6c3bd7bebe3d62d1cfd0fa6334544c9db8398c76
Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
|
|
|
|
|
|
|
| |
Change copyrights and license headers from Nokia to Digia
Change-Id: Ie7f5d49ed8235d7a7845ab68f99ad1c220e64d5c
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of just evaluating bindings in a fixed order, and possibly
having to evaluate a single binding multiple times, prior to reading
a property, we check if there are any bindings "pending" on it and
evaluate them then. A pending binding is one that has been assigned
to the property, but not yet evaluated.
To minimize side effects we only do this for "safe" bindings. A
safe binding is one that has no side effects, which we currently
define as not calling functions or otherwise assigning values during
its evaluation. This isn't an entirely foolproof way to ensure that
the evaluation has no side effects, but it should be good enough.
Change-Id: I98aa76a95719e5d182e8941738d64f8d409f404a
Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
|
|
|
|
|
|
|
| |
This was not immediately obvious, so better document this clever trick.
Change-Id: I0d4a06396b9a709b29b46726d9a65d53600e3fa2
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
| |
This saves us the space of the virtual table pointer, but does
somewhat limit us to the 4 QQmlAbstractBinding types that we
have today.
Change-Id: I03d06ef2ec0c51271c28e7a5aab6dc689d369da4
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
|
|
|
|
|
|
|
|
|
|
| |
The doubly-linked list is unnecessary. Most bindings are created at
startup, and removed only when the object is destroyed. In these cases
the double-link buys nothing other than wasted space. Even when the
bindings are removed earlier, searching the list is not that slow.
Change-Id: I22e1376b78ba712dafd171c7447fbc6ed212b891
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
|
|
|
|
|
|
|
|
| |
V4 bindings must be able to be retargetted for them to be assignable
to aliases.
Change-Id: I4d3addd0fdc90b9bf472c781d316f7f406eaf1d7
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
|
|
|
|
|
|
|
|
| |
This is the first step to creating much lighter weight bindings that
are tuned for the specific scenario in which they're used.
Change-Id: Ib985dcff25679b711b5c634bbc891aa7902bf405
Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
|
|
Change-Id: Ia9c6996a606e140f31681ecd26d93b1b0fdedf02
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
|