amhndu added a comment.

  Sorry about the delay, got caught up in things.
  
  So here's the situation: Currently, the menu's actions store the scheme path 
as the data and applications that currently use this menu (eg. KDevelop and 
Kate), just store this scheme path in their config. So if we were to add 
another action whose data is the system's theme, on triggering this action, the 
path to the then current scheme will be saved and if the system theme is 
changed again, the application will continue use the old theme, going out of 
sync with the system. Thus, there needs to be a way to distinguish the reset 
action with the other actions. Since it's impossible to this without breaking 
the applications that use it, I made this as an entirely new function.
  My (admittedly not a very good) solution to distinguish the actions were to 
store the //index// instead of of the scheme path. That way, you can use the 
index to get the name of the scheme and check if it matches the action's text.
  
  I've thought of creating a subclass of KActionMenu which has two signals - 
one for reset and one for setting a scheme and returning that, but that seems a 
little too complicated.
  
  Is there a simpler solution to this that I'm overlooking?

REPOSITORY
  R265 KConfigWidgets

REVISION DETAIL
  https://phabricator.kde.org/D15645

To: amhndu, #frameworks, broulik, cfeck, elvisangelaccio, ngraham, pino
Cc: pino, ngraham, broulik, kde-frameworks-devel, LeGast00n, michaelh, bruns

Reply via email to