Support File Settings #26
|
@ -1,5 +1,5 @@
|
||||||
import { VRAMArea } from "../vram-components.slint";
|
import { VRAMArea } from "../vram-components.slint";
|
||||||
import { Button, ComboBox, GroupBox, StandardListView, LineEdit, ScrollView, Slider } from "std-widgets.slint";
|
import { Button, CheckBox, ComboBox, GroupBox, StandardListView, LineEdit, ScrollView, Slider } from "std-widgets.slint";
|
||||||
|
|
||||||
struct VRAMImgData {
|
struct VRAMImgData {
|
||||||
full_image: image,
|
full_image: image,
|
||||||
|
@ -299,11 +299,33 @@ export component MainTab inherits Rectangle {
|
||||||
title: "File settings";
|
title: "File settings";
|
||||||
enabled: false;
|
enabled: false;
|
||||||
|
|
||||||
|
VerticalLayout {
|
||||||
|
alignment: start;
|
||||||
|
lz4_check_box := CheckBox {
|
||||||
|
text: "Compress (lz4)";
|
||||||
|
enabled: file_settings_box.enabled;
|
||||||
|
}
|
||||||
|
|
||||||
|
GroupBox {
|
||||||
|
title: "Transparency:";
|
||||||
|
enabled: file_settings_box.enabled;
|
||||||
|
VerticalLayout {
|
||||||
|
alignment: start;
|
||||||
|
trans_combo_box := ComboBox {
|
||||||
|
model: ["No transparency", "First color transparent", "PSX semi-transparency", "Both"];
|
||||||
|
enabled: file_settings_box.enabled;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public function set_active(item: int) {
|
public function set_active(item: int) {
|
||||||
self.enabled = true;
|
self.enabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function set_inactive() {
|
public function set_inactive() {
|
||||||
|
lz4_check_box.checked = false;
|
||||||
|
trans_combo_box.current-index = 0;
|
||||||
self.enabled = false;
|
self.enabled = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue