mirror of
https://github.com/slint-ui/slint.git
synced 2025-07-19 02:55:53 +00:00

* Update api/cpp/include/slint_window.h Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update docs/reference/src/language/builtins/elements.md Co-authored-by: Simon Hausmann <simon.hausmann@slint.dev> * Update internal/core/window.rs Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update internal/interpreter/eval.rs Co-authored-by: Simon Hausmann <simon.hausmann@slint.dev> * Update internal/backends/qt/qt_window.rs Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update internal/interpreter/dynamic_item_tree.rs Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update internal/compiler/passes/materialize_fake_properties.rs Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Simon Hausmann <simon.hausmann@slint.dev>
20 lines
659 B
Text
20 lines
659 B
Text
// Copyright © SixtyFPS GmbH <info@slint.dev>
|
|
// SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0
|
|
|
|
|
|
export component Bar {
|
|
in property <PopupClosePolicy> external;
|
|
xx := PopupWindow {
|
|
close-policy: PopupClosePolicy.close-on-click;
|
|
init => {
|
|
xx.close-policy = PopupClosePolicy.close-on-click;
|
|
// ^error{The property must be known at compile time and cannot be changed at runtime}
|
|
}
|
|
}
|
|
PopupWindow {
|
|
close-policy: root.external;
|
|
// ^error{The close-policy property only supports constants at the moment}
|
|
}
|
|
|
|
|
|
}
|