LRESULT DrawBackground(HDC hdc)
{
+ HRESULT res;
RECT rect;
GetClientRect(&rect);
DrawThemeParentBackground(m_hWnd, hdc, &rect);
}
- DrawThemeBackground(TrayTheme, hdc, TNP_BACKGROUND, 0, &rect, 0);
+ res = DrawThemeBackground(TrayTheme, hdc, TNP_BACKGROUND, 0, &rect, 0);
}
- return TRUE;
+ return res;
}
LRESULT OnEraseBackground(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
RECT rect;
int partId;
+ HRESULT res;
GetClientRect(&rect);
partId = TBP_BACKGROUNDBOTTOM;
break;
}
-
- DrawThemeBackground(m_Theme, hdc, partId, 0, &rect, 0);
+ res = DrawThemeBackground(m_Theme, hdc, partId, 0, &rect, 0);
}
- return TRUE;
+ return res;
}
LRESULT OnEraseBackground(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
rect.bottom = rect.top + GetSystemMetrics(SM_CYSIZEFRAME);
break;
}
-
+ if (IsThemeBackgroundPartiallyTransparent(m_Theme, backoundPart, 0))
+ {
+ DrawThemeParentBackground(m_hWnd, hdc, &rect);
+ }
DrawThemeBackground(m_Theme, hdc, backoundPart, 0, &rect, 0);
ReleaseDC(m_hWnd, hdc);
HRGN hrgn;
GetClientRect (infoPtr->hwndSelf, &cr);
+
+#ifdef __REACTOS__
+ if (theme)
+ {
+ if (IsThemeBackgroundPartiallyTransparent(theme, RP_BACKGROUND, 0))
+ {
+ DrawThemeParentBackground (infoPtr->hwndSelf, hdc, &cr);
+ }
+ DrawThemeBackground (theme, hdc, 0, 0, &cr, NULL);
+ }
+#endif
hrgn = CreateRectRgn(cr.left, cr.top, cr.right, cr.bottom);
oldrow = -1;
#endif
}
+#ifdef __REACTOS__
+ if (!theme)
+#else
if (theme)
{
/* When themed, the background color is ignored (but not a
DrawThemeBackground (theme, hdc, 0, 0, &cr, &rcBand);
}
else
+#endif
{
old = SetBkColor (hdc, new);
TRACE("%s background color=0x%06x, band %s\n",
}
#if 1
+#ifdef __REACTOS__
+ if (!theme)
+#endif
{
//FIXME: Apparently painting the remaining area is a v6 feature
HBRUSH hbrush = CreateSolidBrush(new);
else if ((theme = GetWindowTheme (infoPtr->hwndSelf)))
{
/* FIXME: should use GetThemeInt */
+#ifdef __REACTOS__
+ rect->top = (rect->top + 1 < rect->bottom) ? rect->top : rect->bottom;
+#else
rect->top = min(rect->top + 1, rect->bottom);
+#endif
}
TRACE("new client=(%s)\n", wine_dbgstr_rect(rect));
return 0;
GetThemeEnumValue(hTheme, iPartId, iStateId, TMT_BGTYPE, &bgtype);
+#ifdef __REACTOS__
+ if (bgtype == BT_NONE) return TRUE;
+#endif
if (bgtype != BT_IMAGEFILE) return FALSE;
if(FAILED (UXTHEME_LoadImage (hTheme, 0, iPartId, iStateId, &rect, FALSE,
PTHEME_CLASS MSSTYLES_OpenThemeClass(PTHEME_FILE tf, LPCWSTR pszAppName, LPCWSTR pszClassList)
{
PTHEME_CLASS cls = NULL;
+#ifdef __REACTOS__
+ PTHEME_CLASS defaultCls = NULL;
+#endif
WCHAR szClassName[MAX_THEME_CLASS_NAME];
LPCWSTR start;
LPCWSTR end;
start = end+1;
cls = MSSTYLES_FindClass(tf, pszAppName, szClassName);
if(cls) break;
+#ifdef __REACTOS__
+ if (!defaultCls)
+ defaultCls = MSSTYLES_FindClass(tf, NULL, szClassName);
+#endif
}
if(!cls && *start) {
lstrcpynW(szClassName, start, sizeof(szClassName)/sizeof(szClassName[0]));
cls = MSSTYLES_FindClass(tf, pszAppName, szClassName);
+#ifdef __REACTOS__
+ if (!defaultCls)
+ defaultCls = MSSTYLES_FindClass(tf, NULL, szClassName);
+#endif
}
if(cls) {
TRACE("Opened app %s, class %s from list %s\n", debugstr_w(cls->szAppName), debugstr_w(cls->szClassName), debugstr_w(pszClassList));
cls->tf->dwRefCount++;
TRACE("Theme %p refcount: %d\n", tf, tf->dwRefCount);
}
+#ifdef __REACTOS__
+ else if (defaultCls)
+ {
+ cls = defaultCls;
+ TRACE("Opened default class %s from list %s\n", debugstr_w(cls->szClassName), debugstr_w(pszClassList));
+ cls->tf = tf;
+ cls->tf->dwRefCount++;
+ TRACE("Theme %p refcount: %d\n", tf, tf->dwRefCount);
+ }
+#endif
return cls;
}