summaryrefslogtreecommitdiff
path: root/alf/alfbutton.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'alf/alfbutton.cpp')
-rw-r--r--alf/alfbutton.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/alf/alfbutton.cpp b/alf/alfbutton.cpp
index 17ff1b0..2bc6bc4 100644
--- a/alf/alfbutton.cpp
+++ b/alf/alfbutton.cpp
@@ -907,14 +907,14 @@ ALF_NtButton_WndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
ALFColor newcolor = (ALFColor)lParam;
if (priv->bgcolor != newcolor) {
priv->bgcolor = newcolor;
- // FIXME! optimize classic button which is not transparent
- InvalidateRect(hwnd, NULL, TRUE);
+ if (priv->hTheme) {
+ InvalidateRect(hwnd, NULL, TRUE);
+ }
}
} else if (uMsg == ALF_WM_GETBGCOLOR) {
return (LRESULT)priv->bgcolor;
} else if (uMsg == ALF_WM_BACKGROUNDCHANGE) {
- if (priv->bgcolor == ALF_COLOR_TRANSPARENT) {
- // FIXME! optimize classic button which is not transparent
+ if (priv->bgcolor == ALF_COLOR_TRANSPARENT && priv->hTheme) {
InvalidateRect(hwnd, NULL, TRUE);
}
} else if (uMsg == WM_SIZE) {