Skip to content

[ui] Edge: Workaround on the Crash due to Edge Connections#2663

Closed
waaake wants to merge 2 commits intodevelopfrom
fix/CrashingEdgeQMLComponent
Closed

[ui] Edge: Workaround on the Crash due to Edge Connections#2663
waaake wants to merge 2 commits intodevelopfrom
fix/CrashingEdgeQMLComponent

Conversation

@waaake
Copy link
Contributor

@waaake waaake commented Feb 3, 2025

Description

This PR addresses a crash issue by working around the issue of querying buttons for the MouseEvent.
MouseEvent::button() or MouseEvent::buttons() on the mousePressEvent or in the Custom MouseEvent was causing crashes some times when an event provided has issues.
While the underlying issues at this point are not clear, it is evident that the crash is happening due to the PySide binding.
A similar implementation was tested on the C++ side which seems to be working fine.

Features list

[X] Workaround for edge crashing by implementing a Mouse Area which checks the pressed point to exist on the edge before emitting a pressed/released event.

Implementation remarks

  • This PR introduces a MouseArea which follows the edge, any clicks on the mouse area checks if the point exists on the edgeArea, if so a relevant pressed/released event gets triggered, else the event is ignored.

Removed mousePress and mouseReleased events

Invoking custom Event or querying mouse buttons from the provided QMouseEvent crashes meshroom, this comes as first part of the workaround for querying when a point exists on the path
The workaround on edge crashing is to use the mouse area around the edge and query if the click exists in the edge to accept pressed or released signal
@waaake waaake self-assigned this Feb 3, 2025
@codecov
Copy link

codecov bot commented Feb 3, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 69.95%. Comparing base (91885af) to head (efb13f1).
Report is 165 commits behind head on develop.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #2663   +/-   ##
========================================
  Coverage    69.95%   69.95%           
========================================
  Files          122      122           
  Lines         7106     7106           
========================================
  Hits          4971     4971           
  Misses        2135     2135           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@fabiencastan
Copy link
Member

Resolved with qt >= 6.7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants