Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- image.onStatusChanged: {
- if (image.status == Image.Ready) {
- mouseArea.x = Math.round(.5 * (image.width - image.paintedWidth))
- mouseArea.y = Math.round(.5 * (image.height - image.paintedHeight))
- mouseArea.width = image.paintedWidth
- mouseArea.height = image.paintedHeight
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement