Opened 15 years ago

Last modified 15 years ago

#4339 closed bug

Screen saver settings are lost when switching tabs — at Version 3

Reported by: VinDuv Owned by: axeld
Priority: normal Milestone: R1
Component: Preferences/ScreenSaver Version: R1/Development
Keywords: Cc: stimut@…
Blocked By: Blocking:
Platform: All

Description (last modified by axeld)

This is hrev32648. To reproduce:

  • Open the ScreenSaver preflet, click on Modules, then on a screen saver which has settings (e.g. IFS, Spider).
  • Change the settings.
  • Click on the Fade tab then go back to Modules.

The settings are reset to their previous values.

Change History (4)

comment:1 by stimut, 15 years ago

Cc: stimut@… added

This seems to be because the settings panel is actually generated by the screen saver itself (and not the ScreenSaver preflet), so we can't hook into any of the messages that would be caused when a setting is changed.

I have therefore created a patch which uses the ModulesView::DetachedFromWindow() function to save the settings. This caused a crash when quitting from the modules view though (presumably because the settings object has already been deleted by the time the DetachedFromWindow() function is called), so I had to add a variable which is set in QuitRequested() so that we don't try and save in DetachedFromWindow() when we are quitting (the settings are already saved in QuitRequested()).

It doesn't feel like the cleanest solution to me, but I couldn't think of another way.

by stimut, 15 years ago

Attachment: ScreenSaverWindew.cpp.diff added

ScreenSaver preflet patch

comment:2 by axeld, 15 years ago

Status: newin-progress

comment:3 by axeld, 15 years ago

Description: modified (diff)
Note: See TracTickets for help on using tickets.