summaryrefslogtreecommitdiffstats
path: root/examples/bluetooth/pingpong/assets/Board.qml
Commit message (Collapse)AuthorAgeFilesLines
* Use SPDX license identifiersLucie Gérard2022-06-131-49/+2
| | | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. License files are organized under LICENSES directory. Task-number: QTBUG-67283 Change-Id: Ifc22d8ae24532e9a1093ca613ed6590a1992bc39 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io> (cherry picked from commit 664d2a1cf019f76adf433d41b1418e515ffce86c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Pingpong example: Gamelogic works on unit squareAndreas Buhr2021-03-051-12/+9
| | | | | | | | | | The two parties playing pingpong agreed on a screen size in the past. This patch changes the logic to work on the unit square (0,1)x(0,1). Visualization scales this up to window size. This patch also simplifies the position update loop Change-Id: Ie89b1eaa5fc14daf6b56cd42458a16ae0a923568 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Pingpong example: enlarge MouseArea for paddlesAndreas Buhr2021-03-031-2/+6
| | | | | | | | On some devices, it was hard to grab the paddles. This patch enlarges the mousearea to easier grab the paddles. Change-Id: I10d15b7605521d6a8d7775e5b6b96bce61e44de4 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Pingpong example: use square area for playingAndreas Buhr2021-03-031-73/+82
| | | | | | | This patch adds an extra rectangle to keep the playing area square. Change-Id: I79a80c511eab8f0af44a98e5ff2ee74a88781fad Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Pingpong example: nicer ball visualizationAndreas Buhr2021-03-031-9/+3
| | | | | | | | Increase the ball by a factor of 2. Also remove NumberAnimation which was not working anyway. Correct radius. Change-Id: I4f0e5d50a7eb192a0743533f35e77809be77186a Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Pingpong example: move properties and event handlersAndreas Buhr2021-03-031-37/+37
| | | | | | | | Reorganize code to have graphical elements and event handlers separated Change-Id: I64480649e7bf077b0e63193250a4cb0fe6be699d Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Pingpong example: make paddle shape independent of scaleAndreas Buhr2021-03-031-2/+2
| | | | | | | | This patch changes the paddle radius to be half of its width. This way, the shape is independent of the size of the window. Change-Id: I1a959293e7cab0fdf320e879f828592b2b3b5f1a Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Fix outdated BSD license headerKai Koehne2017-10-171-2/+12
| | | | | Change-Id: I28f5936913a6127806325df34af4bf71a142e72e Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Update copyright headersJani Heikkinen2015-02-161-3/+3
| | | | | | | | | 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: I3822a6484e8f7a420330de1cb1aeb0c3d1cf41b7 Reviewed-by: Sergio Ahumada <sahumada@texla.cl>
* QtBluetooth : pingpong example on OS XTimur Pocheptsov2014-09-261-12/+12
| | | | | | | Re-order some declarations to make the example work on OS X. Change-Id: I9e74ce7b19a3d749f6ba0f951c1ce013f42729f7 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* QML PingPong example addedNedim Hadzic2014-04-021-0/+180
Example presents the socket communication between two Bluetooth devices. The basic concept is the ping pong game, where coordinate updates of the ball and pedals are sent via socket. Change-Id: I61d8eb0baaa11c1485a923bb0a6ae6b89cd0e6a9 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>