mirror of
https://github.com/swaywm/sway.git
synced 2026-07-10 00:06:59 -04:00
copy config references for input and seat
This commit is contained in:
parent
eb0f432a84
commit
9f54cd8935
6 changed files with 37 additions and 7 deletions
|
|
@ -99,6 +99,17 @@ void merge_seat_config(struct seat_config *dest, struct seat_config *source) {
|
|||
}
|
||||
}
|
||||
|
||||
struct seat_config *copy_seat_config(struct seat_config *seat) {
|
||||
struct seat_config *copy = new_seat_config(seat->name);
|
||||
if (copy == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
merge_seat_config(copy, seat);
|
||||
|
||||
return copy;
|
||||
}
|
||||
|
||||
void free_seat_config(struct seat_config *seat) {
|
||||
if (!seat) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue