Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • VLC VLC
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 3.8k
    • Issues 3.8k
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 287
    • Merge requests 287
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • VideoLANVideoLAN
  • VLCVLC
  • Merge requests
  • !3593

qml: fix annoying drag item position overriding

  • Review changes

  • Download
  • Patches
  • Plain diff
Merged Fatih Uzunoğlu requested to merge fuzun/vlc:qml-fix-drag-override-pos into master Apr 26, 2023
  • Overview 21
  • Commits 14
  • Pipelines 8
  • Changes 9
  • Currently, the way drag positioning works is that Qt adjusts the position when drag is active and then this position is overridden immediately by the mouse area. This is quite ugly workaround, and it has been annoying me for a long time let alone the issues it caused.
  • Proposal: set the drag item position before drag starts and let Qt make the drag item follow the cursor.

I'm not happy with qml: disable selective drop indicator visibility, as I believe it is a useful indication from the UI side. However, it seems it can not work reliable since selection is asynchronous. I believe there is the same problem with drag item itself, however I added indexes.length > 0 condition for its visibility so that even if selection is asynchronous, the only problem would be delayed visibility. One workaround for drop indicators might be checking if drop is acceptable on position change as opposed to onEntered, but I did not find this nice.

I proposed to make certain stuff regarding UI/backend integration synchronous, but I have not found enough supporters for making the change. I don't think Qt Quick is designed to handle everything asynchronously.

Edited Jun 02, 2023 by Fatih Uzunoğlu
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: qml-fix-drag-override-pos

VideoLAN code repository instance