mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-03 18:29:09 +00:00

This is commit is just the output of running the syntax updater on the files in the internal/compiler/widgets directory. No extra manual steps were done. Note: In order to run the updater, I did a hack so that the updater wouldn't choke on internal item used by the styles by commenting out the check in ElementType::lookup_type_for_child_element
20 lines
920 B
Text
20 lines
920 B
Text
// Copyright © SixtyFPS GmbH <info@slint-ui.com>
|
|
// SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-commercial
|
|
|
|
import { StyleMetrics, Button } from "std-widgets-impl.slint";
|
|
|
|
export component StandardButton inherits Button {
|
|
in property <StandardButtonKind> kind;
|
|
text:
|
|
root.kind == StandardButtonKind.ok ? "OK" :
|
|
root.kind == StandardButtonKind.cancel ? "Cancel" :
|
|
root.kind == StandardButtonKind.apply ? "Apply" :
|
|
root.kind == StandardButtonKind.close ? "Close" :
|
|
root.kind == StandardButtonKind.reset ? "Reset" :
|
|
root.kind == StandardButtonKind.help ? "Help" :
|
|
root.kind == StandardButtonKind.yes ? "Yes" :
|
|
root.kind == StandardButtonKind.no ? "No" :
|
|
root.kind == StandardButtonKind.abort ? "Abort" :
|
|
root.kind == StandardButtonKind.retry ? "Retry" :
|
|
root.kind == StandardButtonKind.ignore ? "Ignore" : "";
|
|
}
|