Author: gadamopoulos
Date: Tue Jul 12 21:25:51 2011
New Revision: 52665
URL: http://svn.reactos.org/svn/reactos?rev=52665&view=rev
Log:
[apihooksrv]
- Commit a test utility that can install user api hooks and give for the first
time real themes support. This is a temporary test program till the same
functionality is integrated to winlogon. To use it someone has to activate
themes with themecfg and then run "apihook uxtheme.dll". Also note that it is
possible to use this tool in windows for testing purposes
Added:
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/ (with
props)
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/CMakeLists.txt
(with props)
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/apihooksrv.c
(with props)
Modified:
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/CMakeLists.txt
Modified: branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/CMakeLists.txt
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/CMakeLists.txt?rev=52665&r1=52664&r2=52665&view=diff
==============================================================================
--- branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/CMakeLists.txt
[iso-8859-1] (original)
+++ branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/CMakeLists.txt
[iso-8859-1] Tue Jul 12 21:25:51 2011
@@ -1,5 +1,6 @@
add_subdirectory(themecfg)
+add_subdirectory(apihooksrv)
include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine)
add_definitions(-D__WINESRC__)
Propchange: branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/
------------------------------------------------------------------------------
--- bugtraq:logregex (added)
+++ bugtraq:logregex Tue Jul 12 21:25:51 2011
@@ -1,0 +1,2 @@
+([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))?
+(\d+)
Propchange: branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/
------------------------------------------------------------------------------
bugtraq:message = See issue #%BUGID% for more details.
Propchange: branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/
------------------------------------------------------------------------------
bugtraq:url = http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/
------------------------------------------------------------------------------
tsvn:logminsize = 10
Added:
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/CMakeLists.txt
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/CMakeLists.txt?rev=52665&view=auto
==============================================================================
---
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/CMakeLists.txt
(added)
+++
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/CMakeLists.txt
[iso-8859-1] Tue Jul 12 21:25:51 2011
@@ -1,0 +1,13 @@
+
+set_rc_compiler()
+
+list(APPEND SOURCE
+ apihooksrv.c)
+
+add_executable(apihooksrv ${SOURCE})
+
+set_module_type(apihooksrv win32cui)
+
+add_importlibs(apihooksrv msvcrt user32 kernel32)
+
+add_cd_file(TARGET apihooksrv DESTINATION reactos/system32 FOR all)
Propchange:
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Added:
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/apihooksrv.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/apihooksrv.c?rev=52665&view=auto
==============================================================================
--- branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/apihooksrv.c
(added)
+++ branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/apihooksrv.c
[iso-8859-1] Tue Jul 12 21:25:51 2011
@@ -1,0 +1,57 @@
+#include <stdio.h>
+#include <tchar.h>
+#include <windows.h>
+
+typedef BOOL (WINAPI * PTHEMESHOOKINSTALL) ();
+
+int _tmain(int argc, _TCHAR* argv[])
+{
+ HMODULE hmodRosTheme;
+ PTHEMESHOOKINSTALL fnInstall, fnRemove;
+ BOOL ret;
+ DWORD info = BSM_APPLICATIONS;
+
+ if ( argc != 2 )
+ {
+ return 0;
+ }
+
+
+ //hmodRosTheme =
LoadLibrary(L"C:\\Reactos\\src\\themes-priv\\output-MinGW-i386\\reactos\\dll\\win32\\uxtheme\\rostheme.dll");
+ hmodRosTheme = LoadLibrary(argv[1]);
+ if(!hmodRosTheme)
+ {
+ printf("failed to load rostheme\n");
+ return 0;
+ }
+
+ fnInstall = GetProcAddress(hmodRosTheme, (LPCSTR)34);
+ fnRemove = GetProcAddress(hmodRosTheme, (LPCSTR)35);
+
+ if(!fnInstall)
+ {
+ printf("failed to get ThemeHooksInstall\n");
+ return 0;
+ }
+
+ if(!fnRemove)
+ {
+ printf("failed to get ThemeHooksRemove\n");
+ return 0;
+ }
+
+ ret = fnInstall();
+ printf("ThemeHooksInstall returned %d\n", ret);
+
+ BroadcastSystemMessage(BSF_POSTMESSAGE, &info,WM_SETFOCUS,0,0);
+
+ Sleep(36000);
+
+ ret = fnRemove();
+ printf("ThemeHooksRemove returned %d\n", ret);
+
+ BroadcastSystemMessage(BSF_POSTMESSAGE, &info,WM_SETFOCUS,0,0);
+
+ return 0;
+}
+
Propchange:
branches/GSoC_2011/ThemesSupport/dll/win32/uxtheme/apihooksrv/apihooksrv.c
------------------------------------------------------------------------------
svn:eol-style = native