Version: (using KDE 3.3.1, (3.1)) Compiler: gcc version 3.3.5 (Debian 1:3.3.5-3) OS: Linux (i686) release 2.6.9 Switching styles with Widget Style slelection gadget triggers preview refresh no matter if user really changed previewed style say from "A" to "B" or just picked "A" again while "A" being previously selected. This causes unnecesary preview refresh and may also badly flicker on slower machines
CVS commit by tibirna: CT: don't flicker style preview if same style chosen in the combobox. This patch was checked and fixed by Maksim Orlovich. Thank you. BUGS:95925 M +4 -0 kcmstyle.cpp 1.83 --- kdebase/kcontrol/style/kcmstyle.cpp #1.82:1.83 @@ -838,4 +838,8 @@ void KCMStyle::styleChanged() void KCMStyle::switchStyle(const QString& styleName) { + // Don't flicker the preview if the same style is chosen in the cb + if (appliedStyle && appliedStyle->name() == styleName) + return; + // Create an instance of the new style... QStyle* style = QStyleFactory::create(styleName);