| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
| |
| |
| |
| | |
Change-Id: Ifaf87ba32f0c864ea264e78fba1ffc3d12c88a13
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Their use may trigger setting c->requiresExecutionContext on the module
context, which is correct. However, unlike functions, modules at
instantiation time always have their context created ahead of time (to
populate imports). Therefore we must not emit call context creating byte
code instructions where we'd end up storing exports in the wrong place.
Change-Id: Id1264f1cfa6a7f1cd94247ffe71938bc9c5c3ff9
Fixes: QTBUG-70632
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
Give Arrow functions their own representation. This also prepares
for further optimizations especially for the instanceof operator.
Change-Id: I1f70c0271169a237e1acdeb7fe855be957ba2ea5
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Rewrite the tests to not try to delete the cache, but operate
on sets of newly created files.
Task-number: QTBUG-70609
Change-Id: I63135794e2c52048da12977e5c40c0bcce5a24b1
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
componentComplete() is called on us after all static values
have been assigned, but before bindings to any ancestors
have been evaluated. Especially this means that if our size
is bound to the parents size, it will not be ready at that point.
Since we cannot build the table without knowing our own size, we
waited for the updatePolish() call before we started to build
the table.
The problem with that strategy, is that any asynchronous loaders that
TableView might be inside would already be finished by the time
we received the updatePolish() call. The result would be that we
ended up loading all the delegate items synchronously instead of
asynchronously. (As soon as a loader has finished loading the initial
item, async loading will no longer be used).
This patch will therefore add a componentFinalized function that gets
called after all bindings have been evaluated, but before the loader
has finished. When receiving this call, we load the delegate items (and
build the table).
A nice side effect is that the table will also be ready
by the time Component.onCompeted is emitted to the QML
app. This means that e.g contentWidth/Height has valid values.
Change-Id: Ief92d2fecfaea54f6191da116ed4ba79cc673b01
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This helps make that memory known to the GC as well, and makes
marking of internal classes much more efficient, as we don't
mark the property keys repeatedly (even if they are shared
between different internal classes)
Change-Id: Ibb7e5383672d7657926bd08bf13f73f7680a9f31
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
For whatever reason, it seems we have to be less strict about the exact
number of touchpoint movements that the TouchDragArea will see while
being dragged 8 times. Counting those is really far from the main
point of this test anyway.
Also removed blacklisting of macOS 10.10 tests since we don't
even support 10.11 anymore.
Task-number: QTBUG-36804
Task-number: QTBUG-59840
Fixes: QTBUG-68867
Change-Id: I8f856c5b29de08f55dcd0273cd99dcda77cdf2c3
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Doing (silly) things in the delegate, like:
Component.onCompleted: TableView.view.delegate = null
will lead to a crash. The same if you change the model.
The reason is that you end up changing the model
while e.g a row is half-way loaded. Information needed for
building the row, like model size, will then be invalid.
To protect against this, we insert a "sync" phase to the
code that takes any such changes into effect at a time
when we know it's safe to do so.
Change-Id: I85a992dfc0e04ec6635b10c9768a8ddc140e09da
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Flickable::fixup() will be called from Flickable::componentComplete().
fixup() is a virtual function that subclasses can override to e.g
ensure that cells snap to grid etc (which is not yet supported by
TableView). The default implementation will check if the assigned
contentX/Y is within the current content item size, and adjust it
back to 0,0 if not. The problem is that during componentComplete(), the
table has not yet been built. And we don't want Flickable to reset
any assignments to contentX/Y until that has happened. So override the
function and block it from doing any adjustments before the table has
been built.
Change-Id: Id6c5a3b5f053f71bf1854573cd5b9dc3ecc9f246
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Overriding contentWidth/Height was done to be able to force build the
table early if the app needed to know the size of the table already at
Component.onCompleted (to e.g center the viewport on the center of
the table). But now that we have a forceLayout() function, it's better
to require that that function should be called before querying
contentWidth/Height at this stage.
By not building the table on the fly, we allow the application to
bind expressions directly to contentWidth/Height, without being concerned
about potential binding loops that can occur as a result of us
rebuilding the whole table behind his back. The benefit of this overshadows
the need to call forceLayout() explicit for some corner cases.
Note that we still redefine the contentWidth/Height properties in TableView
so that we can catch if the application sets an explicit contentWidth/Height
(which is tested by checkExplicitContentWidthAndHeight()).
Change-Id: Ic4499b3939af1cb3a543e4c006023d0d6f12fd3b
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Just the number of frames per second doesn't tell us the reason for any
low frame rates. The problem could either be GPU-bound, and rendering
could take very long, or the problem could be CPU-bound, with
synchronizing or the gap between frames being very long.
Reporting the rendering and synchronization times in more detail gives
the client an idea of what is actually going on.
Change-Id: Ib2840a9e1aa9b9738e967730c668769946659be2
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
|
| |
| |
| |
| |
| |
| | |
Task-number: QTBUG-70450
Change-Id: Iece912a4184f28290d7a40f3d83253efd81559d2
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Don't reset the content item to 0,0 when we do a rebuild of the
table, since that will overwrite whatever the user has set to contentX/Y
explicitly. Doing the latter can be handy if he needs to flick the table
to a start position upon construction. If the user want's to move the
content item back to origin when changing the model, he can instead do
so manually.
Change-Id: Ic7bc424312569e49115dea5037dd1109261a3aff
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Flickable has a margins API with the exact same naming as
the margins API in TableView. This means that overriding those
properties in TableView was an oversight, and a mistake.
This patch will therefore remove the margins API from
TableView. However, since the API already exists is in
Flickable, the resulting API remains unchanged. But it
will ease the TableView implementation a bit, since we
can then remove code that takes margins into account (since
Flickable does this automatically for us).
The only real difference that will take effect from this
change, is that any overlay or underlay items inside the
flickable will need to have negative coordinates if you
want to position them on top of the margins (e.g to create
a header on top of the table).
Change-Id: I43af66e49f5ddff90739a1c789aacb77ed18b4ce
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I85d6cfa4b4652863cfafad4810176d99dccdabc9
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It should call hasProperty() on the proto if the property
wasn't found locally, instead of looping and calling getOwnProperty,
as this leads to subtly differences with Proxy objects.
Change-Id: I088b0522c621999b7991f9194f46eaa9f6e15206
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| | |
And fix getOwnPropertySymbols and getOwnPropertyDescriptors.
Change-Id: Ie0e4c3d308ffe8a904e9a6ab9242b2cda59d779f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: Iaed36da1284e6545a88eaa17d23fa2862fc611be
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I045a4844c06df9232cc8b04485ab0a39bb990e3f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I28c32f2bfdac8848baf82905fb04790f29451805
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I9c07a6b08e9029b893c28e7a945f839c0f0dda8d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
We don't support realms currently, and it's unclear whether
we'll ever need the support.
Change-Id: I023f84d477f374b3cef2590a78542c0c9408a144
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I40bc5ce2858ebfe1afb04a7957a53114b37ef50f
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: Ifb7159a3307c96b27530e001ab13bcd6ddd03d09
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I0743e9d7fdda0be7a8bb4f9fe3b8e195722c1c90
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I9dffaec95b01757fb21466617d055def2edeeb30
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: Iefba82adbf8f7b944079d165054e9dfe4461ac77
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
child
"isAncestorOf" will not include itself as an ancestor. So we need
to check if the delegate item has focus as well, since we also want
to remove focus for that case. This can e.g happen if the delegate
is a TextInput directly.
Change-Id: I5a5f5a7ec262eacdac64d72b0f41bca991dbab73
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I6cbe0610b65c9f9d7381bc1c70ae17e10486d5c3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| | |
Throw the correct error in all cases
Change-Id: Ic8f146cf13db605cb54cb8c96aaf0b3a1b9cca96
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I5b054b59519ed825459a5b0b0a7cd2c6fc8a3797
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: Id1bba1a729124bccb8a90dcf40252fe5c69d27a3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When an exception happens during destructuring, IteratorClose
needs to be called, unless the exception happened inside the
IteratorNext call (in that case the iterator is assumed to be
invalid and we shouldn't call close on it).
Implement this, by ensuring that we set the done return variable
of IteratorNext to true whenever IteratorNext throws an exception.
IteratorClose will check the done state and not do anything in that
case.
Change-Id: I73a27f855f2c4d3134b8cc8980e64bf797d03886
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This is not perfect yet, as the two regressions in TestExpectations
show, but it's an improvement over the current situation.
Change-Id: I82c0ef0f69619562037c573bea1026abc53c1ab3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I1855eb303225d1784b019f8eebab0ad8bf2cdf5e
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If we flick out a cell that has keyboard focus, we should clear
that focus. Otherwise, the item will be focused also when it
is later reused.
Change-Id: I0fb79b6d906c1907a352de4ec52e3b488064b55a
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If the application uses a DelegateChooser, but the chooser fails to
resolve a delegate for a certain index, it should not use itself
as the delegate instead. This will cause the application to crash.
Instead, we just print a warning, and return nullptr, which will let
TableView handle the situation gracefully.
Change-Id: Ibaf9da09fd11149362f5b674fc61db47593de10c
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If a delegate is using anchors, TableView will not be able
to layout the item. So issue a warning if that is the
case.
Change-Id: I358d981067c23fdab2fc486003afc8bd685f940d
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Instead of creating a new view for every test (which will open a
new window), it's better to reuse the same view. Especially since
there is a bug in AppKit (which has been reported by Tor-Arne, but
I could not find the rdar id) that can sometimes be hit when closing a
window, causing it to crash. So creating and closing almost 100 windows
in this test will sometimes trigger that bug.
Change-Id: If4d962e4b9aeea154d4cd764a5bc414bcd2995b7
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If the application uses a DelegateChooser, but the chooser fails to
resolve a delegate for a certain index, it should not use itself
as the delegate instead. This will cause the application to crash.
Instead, return nullptr (like we do in the function guard), which
will let the item views handle the situation gracefully.
Change-Id: I9b3b4aa2626d1f8521b4395096300ac12150c63f
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I4c0cfc3a120fc0b246760886b576e92d3f7623ff
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Don't return a name reference if we fail to lookup something in
the scope object, but rather continue trying in the context
object.
Task-number: QTBUG-70315
Change-Id: I73f8aa7b648320434ef0ef37a4c12dca1eb7b209
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
Handle property keys that are numeric strings, and implement
getOwnProperty.
Change-Id: I4c7ed21b6429b07f02a28bce537bcb7934a993d3
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I2e7aa05a340d54e2f34ec4e59a69f3ce66be75d9
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I481974c224f7fdb4df6b641e8dd550add96b4c08
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| | |
And return the correct this object from the subclass constructor.
Change-Id: I8d68f07c3080f8c5ff8b10ad2cc85e017bf710d8
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: Icbc25f1f723fe45a8c265f1b4bdf5f3fad3c4775
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I19eb4012c8fee51a7e5bf264d11ab5337ac2a88d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| | |
Only functions that are constructors should have a prototype
property.
Change-Id: Ifcf6f8b6c38de055d871d57ada38a23432974263
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| | |
Change-Id: I4215c215a28da6855d946dec8727c0c4f0acb933
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|