-Add missing imports
-Bind ids inside of Components
-Explicitly require implcitly depended on index property
-Qualify lookups
-Cast reading as AccelerometerReading until it is exposed as the proper
type
Also fix a binding loop when setting the die's position.
Fixes: QTBUG-138165
Pick-to: 6.10
Change-Id: I691d4a5bbf4cfbd8f7a6af0e837c15319f60343d
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
The project name is used in Qt Creator as root name for the project.
Using the same name as the documentation/example name makes it
clearer which example is actually open. Only drop prefixes like
'Qt Quick Demo - '.
Pick-to: 6.10
Change-Id: I863a23e26307a973bb04ce879d0c95c3731cdc53
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
This patch
-enables qmltooling in non release builds
-this will allow QML debugging to start and work
-this patch will do this to following examples:
-calqlatr, coffee machine and dice
Task-number: QTBUG-136794
Pick-to: 6.9 6.8
Change-Id: I4699285fa20021ec9d6e29c86a7a16516af085fa
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This change ensures proper initial distance of dices based
on their size. It also distributes them horizontally so that
they hit each other later at different angles.
Pick-to: 6.8 6.9 6.9.0
Change-Id: I7f8d2ab0c9b7b6b00996cae8fb121de950b68ca4
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
Although the SoundEffect type has lower latency, it is
more resource intensive and shows lower performance and
makes the UI stuttering in some desktop or mobile target
devices.
In this change, we replace SoundEffect with MediaPlayer to
get better visual performance.
Pick-to: 6.8 6.9 6.9.0
Change-Id: Ib5f4d8fe6efb726e341481af9a3aaf2d1f4f1515
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This change enhances the readability of the code and improves the
behavior of triggering a roll. It adds a small delay to prevent
multiple rolls from occurring in short intervals.
Pick-to: 6.8 6.9 6.9.0
Change-Id: I657450be50742d9b6236e2c29cf365b04349f191
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
The user could not see actual values that are set with
sliders. This change appends those values to their related
labels.
Pick-to: 6.8 6.9 6.9.0
Change-Id: I0683a2765368e8385e103639695f7f337902e996
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This removes the hide() function and the manual animation
from the tapLabel and uses Behavior as an alternative.
Pick-to: 6.8 6.9 6.9.0
Change-Id: Ib4cb924ff1ac3dce70dfde3a80e00efa39a5799a
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
The OrbitCameraController inside the Scene, steals gestures from
the Flickable inside the drawer.
This change disables the camera controller when drawer is shown.
Pick-to: 6.8 6.9 6.9.0
Change-Id: I557f1196db0da2d1b30ddbfbe804585de2519f1a
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
atRest property should be true while the motionTimeout timer
is running.
This change remove a function binding and directly aliases the
atRest property to running property of the timer.
TODO: atRest is unused based on a previous change. If we decide
to keep the logic in the previous patch, then we can remove
this timer and also the property.
Pick-to: 6.8 6.9 6.9.0
Change-Id: I9d0c58f192251621cb3e691cf431366eb6b1dd68
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
This change replaces the imperative logic of DiceSpawner
with a more declarative approach using Repeater3D.
It also replaces sending properties via functions, with
property binding and property aliases.
Pick-to: 6.8 6.9 6.9.0
Change-Id: Ic5c166fb50b0ede393cc72411f1a4a7e08a6ccd7
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
DirectionalLight shows performance issues on some targets.
We can achieve a similar visual result with a PointLight.
Pick-to: 6.8 6.9 6.9.0
Change-Id: I39708d2179782f8643ede39e970f47337cae507f
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
Setting this to 35 is not going to work properly as edge-to-edge is not
working properly yet in Qt for Android 15.
See https://developer.android.com/develop/ui/views/layout/edge-to-edge
Fixes: QTBUG-132360
Pick-to: 6.9 6.8
Change-Id: I46020d07e3aea59d57ebf1bef1b25f1f90971827
Reviewed-by: Petri Virkkunen <petri.virkkunen@qt.io>
There is no point in being able to make the camera not focused on the
table since there is nothing else to see in the example.
Change-Id: I6fc0df5619080165ea147ce870065b2cae12e371
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
REUSE.toml files are read by reuse to complement or override the
copyright and licensing information found in file.
The use of REUSE.toml files was introduced in REUSE version 3.1.0a1.
This reuse version is compatible with reuse specification
version 3.2 [1].
With this commit's files,
* The SPDX document generated by reuse spdx conforms to SPDX 2.3,
* The reuse lint command reports that the Qt project is reuse compliant.
In order to be reuse compliant all the licenses referenced in file
or within a REUSE.toml file must be present in the LICENSES
directory at the base of the module.
The missing licenses are added.
Also, all the licenses present in the LICENSES directory must be used.
License files not used are removed.
[1]: https://reuse.software/spec-3.2/
Task-number: QTBUG-124453
Task-number: QTBUG-125211
Pick-to: 6.8
Change-Id: I1dabbf6f13c2ae5ad73dc8c7df9108c160e1dc2b
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
There was a bug previously causing the shadowBias to be 2x its specified
value, so update the value to account for this fix.
Change-Id: I980993eb3a798755ede736d6b20537ed4f23186c
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
Now, the camera position is set too close so that not the whole view
is shown on portrait mode. So set the camera position close or far based
on the orientation.
Increase the default size of the dice so it's more visible and not tiny.
Don't move/shift the whole scene when the drawer is opened, this just
causes huge drop in fps on Android devices, instead the drawer opens
without affecting the scene's postion or dimentions.
Pick-to: 6.8
Task-number: QTBUG-127813
Change-Id: I3c7c54e4a1dbb3378045d86debaa21c8e50e8e94
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
The dice shadows are now only enabled when they are close enough to the
table. This will keep shadow map bounds smaller and reduce graphical
artifacts.
Pick-to: 6.8
Change-Id: I4664e4d6d825f0dd01ebb65e1180cb28155cb890
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
Use qt_add_qml_module for the dice demo.
Make the demo qmllint clean by removing unused imports, unqualified
accesses and more.
Use loadFromModule instead of load, and rename main.qml to Main.qml to
be loadable. Also add a missing qmldir file for the qmake project to
work with loadFromModule, and fix the prefixes in the .pro file.
Pick-to: 6.8
Task-number: QTBUG-100100
Change-Id: I786dcb971980f48e91b0aeaf9d65f285a78c260e
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Projects were modified using the tool at:
https://git.qt.io/alcroito/cmake_refactor
Some examples had to be adapted manually, mostly those that build
additional qml modules / plugins.
documentviewer did not get the deployment api, because it's trickier.
Pick-to: 6.7
Task-number: QTBUG-101340
Task-number: QTBUG-102056
Task-number: QTBUG-102057
Change-Id: I76322185fc824c112d77e077ee39e7ccbc193a4c
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
According to QUIP-18 [1] all files under examples
should be licensed
LicenseRef-Qt-Commercial OR BSD-3-Clause
[1]: https://contribute.qt-project.org/quips/18
Pick-to: 6.7 6.7.0
Task-number: QTBUG-121787
Change-Id: Ia2e8f62af64a384196a9b0c02ac5b2fbf5404a8b
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
Added the required modules to the note, updated the brief.
Pick-to: 6.7 6.7.0
Change-Id: I2515aaeec95dd7825794b784d7799920a2624b43
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
Put the column of controls in a flickable and set the scroll-bar
to always on if the UI's height is greater than the screen height.
This way the the user knows they can scroll if they start
the application in a landscape orientation. Should see no change in
on desktops, unless you resize the application window smaller than
the menu height.
Fixes: QTBUG-122444
Pick-to: 6.7 6.7.0
Change-Id: Ic49c7b0acdb8f71723925441af5dfbaa8793b67e
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This is to meet the requirement that the app have a different name on
the app store.
Task-number: QTBUG-115724
Pick-to: 6.7
Change-Id: Ia5b657b7a9f363a5c4ca1e7c27f75daa07d5c689
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
"Injection of parameters into signal handlers is deprecated"
Change-Id: I12f6257b4cf2f5b79d9ba7153ad256292eebc0fd
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
Add metadata about build time / runtime dependencies in the form
of Qt documentation modules. This should allow Qt Creator to hide
examples where needed Qt modules are not installed (because they
are optional in the Qt Online Installer).
Pick-to: 6.7
Task-number: QTBUG-120759
Change-Id: I03d8d75b273fe497803b9af9783b90e397b0638d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
There is a problem in QQ3DPhysics. onBodyContact may still refer to
already deleted object - which causes the application to crash.
It happens when Accelerometer spam a lot with scene.spawnDice(...)
calls.
To avoid this crash, the timer-guard for rolling dices was added.
Pick-to: 6.7 6.6
Fixes: QTBUG-120364
Change-Id: I3ca3811662fb2400d61cb256c8b34885a6fe028a
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
The menu button icon did not appear on Android with the text method, so
added an icon svg to use on all platforms.
The initial label pop up was not wrapping on small screens so added a
height, modified properties to keep the original text size but wrap the
text.
Fixes: QAA-2183
Pick-to: 6.6 6.7
Change-Id: I2265e7558dfec839530b5f9b6a7a4129d7b081b2
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Rami Potinkara <rami.potinkara@qt.io>
Added target SDK 33 with CMake and added icon for Android target,
using Qt creator to generate icons and the AndroidManifest xml
file. Gradle files were excluded.
Task-number: QTBUG-118513
Pick-to: 6.6
Change-Id: I57953099350017975702309496e4e4f1a87e9d1f
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
A had initially intended to expand this documentation more exhaustively,
however, I decided that example documentation that describes each discrete feature already exists.
Added sections, expanded a bit, referenced existing applicable example
documents, and the fact that this example will be available already
built for Android in the Google Play Store.
Fixes: QTBUG-114599
Pick-to: 6.6
Change-Id: Id989d82a40fb95808a42aa1b497b4d76161b5d74
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Added the features in line with the spike outcome.
In addition, I modified the spawnDice function to
estimate if all dice are at rest before enabling spawning.
This prevents duplicate shake events and double tap
fumbles.
Task-number: QTBUG-116491
Pick-to: 6.6
Change-Id: Ia0dc59e469e008da5fc3afe2a7342381eadc1008
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Don't calculate this inside the for loop.
Pick-to: 6.5 6.6
Change-Id: I09d46e363325071086332d901235f0feeabbb474
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
Quick3D is an optional component in the online installer. As the examples are part of qtdoc,
they are however installed & available also if Quick3D is missing.
Let's at least mention the dependency in the respective examples' documentation.
Add a general 'Running the Example' section if missing, too.
Pick-to: 6.5 6.6
Fixes: QTBUG-114998
Change-Id: If4d3b48b3d0352a0359f6962d4eb1bc2e1e67c95
Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io>
The bug is fixed but the workaround was actually not needed to begin
with since the bug only affects nodes with a position and a parent with
scale which is not the case here.
Pick-to: 6.5 6.6
Change-Id: I99766586d2671b3286085d54c7cf8cca7e0f9b7b
Reviewed-by: Kai Köhne <kai.koehne@qt.io>