Add xkb config options
parent
d0aa51aa6e
commit
b9142a94ae
|
@ -28,6 +28,11 @@
|
|||
X(string, address) \
|
||||
X(uint, port) \
|
||||
X(bool, enable_pam) \
|
||||
X(string, xkb_rules) \
|
||||
X(string, xkb_model) \
|
||||
X(string, xkb_layout) \
|
||||
X(string, xkb_variant) \
|
||||
X(string, xkb_options) \
|
||||
|
||||
struct cfg {
|
||||
#define string char*
|
||||
|
|
|
@ -946,9 +946,12 @@ int main(int argc, char* argv[])
|
|||
self.keyboard_manager, self.selected_seat->wl_seat);
|
||||
|
||||
struct xkb_rule_names rule_names = {
|
||||
.layout = self.kb_layout,
|
||||
.model = "pc105",
|
||||
.variant = self.kb_variant,
|
||||
.rules = self.cfg.xkb_rules,
|
||||
.layout = self.kb_layout ? self.kb_layout : self.cfg.xkb_layout,
|
||||
.model = self.cfg.xkb_model ? self.cfg.xkb_model : "pc105",
|
||||
.variant = self.kb_variant ? self.kb_variant :
|
||||
self.cfg.xkb_variant,
|
||||
.options = self.cfg.xkb_options,
|
||||
};
|
||||
|
||||
keyboard_init(&self.keyboard_backend, &rule_names);
|
||||
|
|
Loading…
Reference in New Issue