]> git.mdlowis.com Git - proto/labwc.git/commit
rcxml: fix broken titlebar layout with multiple <layout> entries
authortokyo4j <hrak1529@gmail.com>
Sat, 12 Apr 2025 11:31:04 +0000 (20:31 +0900)
committerJohan Malm <johanmalm@users.noreply.github.com>
Sat, 12 Apr 2025 20:27:41 +0000 (21:27 +0100)
commitfcf230e692a2a060102440a5d93265d76378489f
treedbf20a6998a902c7a4d970fa0768e1cb96fcd03b
parentbe3ca8df7af5f4a73e85fecd6861c6db7322f63c
rcxml: fix broken titlebar layout with multiple <layout> entries

Before this commit, when we have multiple <theme><titlebar><layout>
entries like below, duplicated button types can be inserted to
rc.title_buttons_{left,right} and the button could go outside of the
window:
    <theme>
      <titlebar><layout>icon:iconify,max,close</layout></titlebar>
      <titlebar><layout>icon:iconify,max,close</layout></titlebar>
    </theme>

This commit fixes by clearing those lists when the parser encounters
<theme><titlebar><layout>.
src/config/rcxml.c