ci: allow Slint royalty-free license in cargo-deny, fix Slint binding loop

cargo-deny rejected Slint's license expression (GPL-3.0-only OR
LicenseRef-Slint-Royalty-free-2.0 OR ...) and ksni's Unlicense. We use Slint
under the royalty-free license, whose attribution is in the About page.

The main window's `narrow` flag was bound to its own width and panes bound
their width to the parent, which Slint reports as a binding loop. The flag is
now set from a change handler and panes use stretch/min/max widths.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NJvYyRmTjKcb9i8eyYXK5G
This commit is contained in:
Claude committed 2026-09-25 19:21:56 +00:00
1 parent baa88dc082
commit 4c5f90b66b
2 files changed
+17 -4

No files matched your search

+12 -4
View File
@@ -385,8 +385,11 @@ export component MainWindow inherits Window {
property <bool> editing: false;
property <bool> show-about: false;
property <BookmarkForm> form;
// Phones and narrow windows show one pane at a time.
property <bool> narrow: self.width < 800px;
// Phones and narrow windows show one pane at a time. Set from a change
// handler: a binding on `width` would loop through the layout.
property <bool> narrow: false;
changed width => { narrow = self.width < 800px; }
init => { narrow = self.width < 800px; }
property <int> pane: 1;
VerticalLayout {
@@ -463,7 +466,10 @@ export component MainWindow inherits Window {
}
HorizontalLayout {
if !narrow || pane == 2: ServerList {
width: narrow ? parent.width : 230px;
// Fixed width beside the other panes, all the space alone.
min-width: narrow ? 0px : 230px;
max-width: narrow ? 100000px : 230px;
horizontal-stretch: narrow ? 1 : 0;
add => {
form = Bridge.edit-bookmark(-1);
editing = true;
@@ -474,7 +480,9 @@ export component MainWindow inherits Window {
}
}
if !narrow || pane == 0: ChannelTree {
width: narrow ? parent.width : 360px;
min-width: narrow ? 0px : 360px;
max-width: narrow ? 100000px : 360px;
horizontal-stretch: narrow ? 1 : 0;
}
if !narrow || pane == 1: ChatPanel { }
}
+5
View File
@@ -29,6 +29,11 @@ allow = [
"CDLA-Permissive-2.0",
"MPL-2.0",
"BSL-1.0",
"Unlicense",
# Slint is triple licensed (GPL-3.0-only OR royalty-free OR commercial); we
# use the royalty-free license, which requires the attribution shown in the
# app's About page and the README.
"LicenseRef-Slint-Royalty-free-2.0",
]
confidence-threshold = 0.9