ChangeSet ID: 21466
CVSROOT: /opt/cvs-commit
Module name: wine
Changes by: julliard(a)winehq.org 2005/11/28 05:02:32
Modified files:
dlls/shell32 : iconcache.c
Log message:
Ge van Geldorp <gvg(a)reactos.org>
Load shortcut icon by resource id instead of by icon index.
Patch: http://cvs.winehq.org/patch.py?id=21466
Old revision New revision Changes Path
1.96 1.97 +4 -1 wine/dlls/shell32/iconcache.c
Index: wine/dlls/shell32/iconcache.c
diff -u -p wine/dlls/shell32/iconcache.c:1.96 wine/dlls/shell32/iconcache.c:1.97
--- wine/dlls/shell32/iconcache.c:1.96 28 Nov 2005 11: 2:32 -0000
+++ wine/dlls/shell32/iconcache.c 28 Nov 2005 11: 2:32 -0000
@@ -129,7 +129,10 @@ static HICON SIC_OverlayShortcutImage(HI
/* search for the shortcut icon only once */
if (s_imgListIdx == -1)
- s_imgListIdx = SIC_LoadOverlayIcon(29); /* icon index for IDI_SHELL_SHORTCUT */
+ s_imgListIdx = SIC_LoadOverlayIcon(- IDI_SHELL_SHORTCUT);
+ /* FIXME should use icon index 29 instead of the
+ resource id, but not all icons are present yet
+ so we can't use icon indices */
if (s_imgListIdx != -1)
{
ChangeSet ID: 21462
CVSROOT: /opt/cvs-commit
Module name: wine
Changes by: julliard(a)winehq.org 2005/11/28 05:01:56
Modified files:
dlls/iccvid : Makefile.in iccvid.c
Added files:
dlls/iccvid : iccvid_En.rc iccvid_private.h rsrc.rc
Log message:
Dmitry Timoshkov <dmitry(a)codeweavers.com>
Add support for ICM_GETINFO in iccvid codec (based on msrle32).
Patch: http://cvs.winehq.org/patch.py?id=21462
Old revision New revision Changes Path
1.3 1.4 +3 -1 wine/dlls/iccvid/Makefile.in
1.7 1.8 +43 -2 wine/dlls/iccvid/iccvid.c
Added 1.1 +0 -0 wine/dlls/iccvid/iccvid_En.rc
Added 1.1 +0 -0 wine/dlls/iccvid/iccvid_private.h
Added 1.1 +0 -0 wine/dlls/iccvid/rsrc.rc
Index: wine/dlls/iccvid/Makefile.in
diff -u -p wine/dlls/iccvid/Makefile.in:1.3 wine/dlls/iccvid/Makefile.in:1.4
--- wine/dlls/iccvid/Makefile.in:1.3 28 Nov 2005 11: 1:56 -0000
+++ wine/dlls/iccvid/Makefile.in 28 Nov 2005 11: 1:56 -0000
@@ -3,11 +3,13 @@ TOPOBJDIR = ../..
SRCDIR = @srcdir@
VPATH = @srcdir@
MODULE = iccvid.dll
-IMPORTS = kernel32
+IMPORTS = user32 kernel32
C_SRCS = \
iccvid.c
+RC_SRCS = rsrc.rc
+
@MAKE_DLL_RULES@
### Dependencies:
Index: wine/dlls/iccvid/iccvid.c
diff -u -p wine/dlls/iccvid/iccvid.c:1.7 wine/dlls/iccvid/iccvid.c:1.8
--- wine/dlls/iccvid/iccvid.c:1.7 28 Nov 2005 11: 1:56 -0000
+++ wine/dlls/iccvid/iccvid.c 28 Nov 2005 11: 1:56 -0000
@@ -47,13 +47,15 @@
#include "winuser.h"
#include "commdlg.h"
#include "vfw.h"
-
#include "mmsystem.h"
+#include "iccvid_private.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL(iccvid);
+static HINSTANCE ICCVID_hModule;
+
#define ICCVID_MAGIC mmioFOURCC('c', 'v', 'i', 'd')
#define DBUG 0
@@ -910,8 +912,27 @@ static LRESULT ICCVID_Close( ICCVID_Info
return 1;
}
+static LRESULT ICCVID_GetInfo( ICCVID_Info *info, ICINFO *icinfo, DWORD dwSize )
+{
+ if (!icinfo) return sizeof(ICINFO);
+ if (dwSize < sizeof(ICINFO)) return 0;
+
+ icinfo->dwSize = sizeof(ICINFO);
+ icinfo->fccType = ICTYPE_VIDEO;
+ icinfo->fccHandler = info ? info->dwMagic : ICCVID_MAGIC;
+ icinfo->dwFlags = 0;
+ icinfo->dwVersion = 0x00010000; /* Version 1.0 build 0 */
+ icinfo->dwVersionICM = 0x01040000; /* Version 1.4 build 0 */
+
+ LoadStringW(ICCVID_hModule, IDS_NAME, icinfo->szName, sizeof(icinfo->szName)/sizeof(WCHAR));
+ LoadStringW(ICCVID_hModule, IDS_DESCRIPTION, icinfo->szDescription, sizeof(icinfo->szDescription)/sizeof(WCHAR));
+ /* msvfw32 will fill icinfo->szDriver for us */
+
+ return sizeof(ICINFO);
+}
+
LRESULT WINAPI ICCVID_DriverProc( DWORD dwDriverId, HDRVR hdrvr, UINT msg,
- LONG lParam1, LONG lParam2)
+ LPARAM lParam1, LPARAM lParam2)
{
ICCVID_Info *info = (ICCVID_Info *) dwDriverId;
@@ -939,6 +960,9 @@ LRESULT WINAPI ICCVID_DriverProc( DWORD
}
return (LRESULT) info;
+ case ICM_GETINFO:
+ return ICCVID_GetInfo( info, (ICINFO *)lParam1, (DWORD)lParam2 );
+
case ICM_DECOMPRESS_QUERY:
return ICCVID_DecompressQuery( info, (LPBITMAPINFO) lParam1,
(LPBITMAPINFO) lParam2 );
@@ -963,3 +987,20 @@ LRESULT WINAPI ICCVID_DriverProc( DWORD
}
return 0;
}
+
+BOOL WINAPI DllMain(HINSTANCE hModule, DWORD dwReason, LPVOID lpReserved)
+{
+ TRACE("(%p,%ld,%p)\n", hModule, dwReason, lpReserved);
+
+ switch (dwReason)
+ {
+ case DLL_PROCESS_ATTACH:
+ DisableThreadLibraryCalls(hModule);
+ ICCVID_hModule = hModule;
+ break;
+
+ case DLL_PROCESS_DETACH:
+ break;
+ }
+ return TRUE;
+}
Index: wine/dlls/iccvid/iccvid_En.rc
diff -u -p /dev/null wine/dlls/iccvid/iccvid_En.rc:1.1
--- /dev/null 28 Nov 2005 11: 1:56 -0000
+++ wine/dlls/iccvid/iccvid_En.rc 28 Nov 2005 11: 1:56 -0000
@@ -0,0 +1,25 @@
+/*
+ * Copyright 2005 Dmitry Timoshkov
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT
+
+STRINGTABLE DISCARDABLE
+{
+ IDS_NAME "Cinepak Video codec"
+ IDS_DESCRIPTION "Cinepak Video codec"
+}
Index: wine/dlls/iccvid/iccvid_private.h
diff -u -p /dev/null wine/dlls/iccvid/iccvid_private.h:1.1
--- /dev/null 28 Nov 2005 11: 1:56 -0000
+++ wine/dlls/iccvid/iccvid_private.h 28 Nov 2005 11: 1:56 -0000
@@ -0,0 +1,25 @@
+/*
+ * Copyright 2005 Dmitry Timoshkov
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef __ICCVID_PRIVATE_H
+#define __ICCVID_PRIVATE_H
+
+#define IDS_NAME 100
+#define IDS_DESCRIPTION 101
+
+#endif /* __ICCVID_PRIVATE_H */
Index: wine/dlls/iccvid/rsrc.rc
diff -u -p /dev/null wine/dlls/iccvid/rsrc.rc:1.1
--- /dev/null 28 Nov 2005 11: 1:56 -0000
+++ wine/dlls/iccvid/rsrc.rc 28 Nov 2005 11: 1:56 -0000
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2005 Dmitry Timoshkov
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include "windef.h"
+#include "iccvid_private.h"
+
+#include "iccvid_En.rc"