in darkroom don't allow dragging libs to right or iops to left #17462
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When a lib's header is dragged into an empty panel, it is responsible for moving itself there. It would happily put itself in the right panel in the darkroom if it is empty (for example because the search box has nonsense in it), but then crash on switching to lighttable. Similarly, when an iop is dragged into an empty panel it cannot be the right one (because that's where you're dragging it from, so it isn't empty), so it is the left one and the drop must be blocked. Before this fix, the cursor would indicate that a drop is allowed and actually dropping an iop on the left side would generate a bunch of Gtk-CRITICALS.
Also, since it is now possible to hide the iop-order module (bottom right), first check that there actually is an expander before trying to set its second label.