Skip to content
  • Martin Flöser's avatar
    Do not save kwinrulesrc on every window opening/closing · 9a02ed4d
    Martin Flöser authored
    Summary:
    Our rule handling has had a grave error for years. Whenever a window
    with a rule was openend or closed the kwinrulesrc was written back to
    disk.
    
    The reason for this behavior is that temporary rules need to be discarded
    once they were used. For that there is a method discardUsed which invokes
    requestDiskStorage whenever a rule for the window was found. But it did
    not check whether there was a rule requiring this.
    
    This change modifies the discardUsed to track whether it changed a rule
    and only writes back in case there was a change.
    
    BUG: 393911
    FIXED-IN: 5.12.6
    
    Test Plan: Only compile tested
    
    Reviewers: #kwin, #plasma
    
    Subscribers: kwin
    
    Tags: #kwin
    
    Differential Revision: https://phabricator.kde.org/D12749
    9a02ed4d