Release 950302

Thu Mar  2 17:44:32 1995  Alexandre Julliard  (julliard@sunsite.unc.edu)

	* [loader/resource.c] [objects/oembitmap.c]
	Removed sysres bitmap code; you need libXpm to compile now.
	Implemented LoadIcon() for OEM icons.

	* [include/bitmaps/oic_*]
	Added OEM icons in XPM format.

	* [objects/dib.c]
	Bug fix in DrawIcon().

	* [rc/sysresbm.rc]
	Removed; all bitmaps are stored in XPM format now.

Tue Feb 28 18:54:28 1995  Tomi Leppikangas  (tomilepp@paju.oulu.fi)

	* [controls/edit.c]
	Small patch to fix edit-control when it's created with text.

Sun Feb 26 20:22:15 1995  Michael Veksler  (e1678223@tochnapc2.technion.ac.il)

	* [tools/make_debug]
	The created macros won't have side effects anymore when used in
	an "if-else" structure. No more warnings from the compiler when
	compiled without defining DEBUG_RUNTIME.
 
Sun Feb 26 20:20:49 1995  Michael Patra <micky@marie.physik.TU-Berlin.DE>

	* [controls/listbox.c]
	ListBoxDeleteString(): Fixed

	* [loader/selector.c]
	GetMemoryReference(): When special segments are referenced by
	pseudo-functions like __0040H, a reference to a "normal" segment
	will be returned preventing the program from crashing as soon
	as the referenced segment is actually accessed.

Sun Feb 26 15:55:14 MET 1995  Martin von Loewis (loewis@informatik.hu-berlin.de)

	* [Configure]
	Ask for OLE stubs and malloc debugging

	* [Imakefile]
	link with libmcheck.a if necessary

	* [if1632/relay.c][include/dll.h][if1632/Imakefile]
	Add OLE stubs, increase number of builtins
	dll_name_table_entry_s: new field dll_is_used

	* [loader/library.c]
	GetModuleHandle,ModuleNext: Check dll_is_used

	* [loader/ne_image.c]
	Bark on unsupported NE_RADDR_LOWBYTE flag (what is it supposed
	to mean, anyway?)

	* [misc/olecli.c][misc/olesvr.c]
	New files. Add to misc/Imakefile

	* [misc/dos_fs.c]
	DOS_GetUnixFileName: make a copy of the input parameter to 
	prevent overwriting

	* [misc/main.c]
	MAIN_ParseDLLOptions: new function
	MAIN_ParseOptions: treat -dll command line flag
	main: add support for malloc debugging

Fri Feb 24 12:43:27 1995  Erik Svendsen  <z3esv@kmd-ac.dk>

	* [loader/signal.c]
	Small patch for people using FreeBSD-2.1.0.

Fri Feb 17 22:49:18 1995  Miguel de Icaza (miguel@roxanne.nuclecu.unam.mx)

	* [toolkit/sup.c]
	Added return values to the Call* routines

	* [toolkit/winmain.c]
	Load the resource file properly for WineLib applications.
This commit is contained in:
Alexandre Julliard 1995-03-02 17:33:47 +00:00
parent b67b1dcc26
commit 6abb89c3b2
49 changed files with 1813 additions and 2352 deletions

View File

@ -1,14 +1,14 @@
This is release 950216 of Wine the MS Windows emulator. This is still a
This is release 950302 of Wine the MS Windows emulator. This is still a
developer's only release. There are many bugs and many unimplemented API
features. Most applications still do not work.
Patches should be submitted to "wine-new@amscons.com". Please don't forget
to include a ChangeLog entry. I'll make a new release every other Sunday.
WHAT'S NEW with Wine-950216: (see ChangeLog for details)
- Size optimizations in DLL relay code
- Portability fixes for WineLib
- Handling of relative paths in DOS filenames
WHAT'S NEW with Wine-950302: (see ChangeLog for details)
- You now need libXpm to be able to compile.
- OLE stubs and run-time option to disable them.
- Support for special selectors like __0040H.
- Lots of bug fixes
See the README file in the distribution for installation instructions.
@ -17,11 +17,11 @@ Because of lags created by using mirror, this message may reach you before
the release is available at the ftp sites. The sources will be available
from the following locations:
sunsite.unc.edu:/pub/Linux/ALPHA/wine/Wine-950216.tar.gz
aris.com:/pub/linux/ALPHA/Wine/development/Wine-950216.tar.gz
tsx-11.mit.edu:/pub/linux/ALPHA/Wine/development/Wine-950216.tar.gz
ftp.funet.fi:/pub/OS/Linux/ALPHA/Wine/Wine-950216.tar.gz
ftp.wonderland.org:/Wine/Wine-950216.tar.gz
sunsite.unc.edu:/pub/Linux/ALPHA/wine/Wine-950302.tar.gz
aris.com:/pub/linux/ALPHA/Wine/development/Wine-950302.tar.gz
tsx-11.mit.edu:/pub/linux/ALPHA/Wine/development/Wine-950302.tar.gz
ftp.funet.fi:/pub/OS/Linux/ALPHA/Wine/Wine-950302.tar.gz
ftp.wonderland.org:/Wine/Wine-950302.tar.gz
If you submitted a patch, please check to make sure it has been
included in the new release.

View File

@ -1,3 +1,86 @@
----------------------------------------------------------------------
Thu Mar 2 17:44:32 1995 Alexandre Julliard (julliard@sunsite.unc.edu)
* [loader/resource.c] [objects/oembitmap.c]
Removed sysres bitmap code; you need libXpm to compile now.
Implemented LoadIcon() for OEM icons.
* [include/bitmaps/oic_*]
Added OEM icons in XPM format.
* [objects/dib.c]
Bug fix in DrawIcon().
* [rc/sysresbm.rc]
Removed; all bitmaps are stored in XPM format now.
Tue Feb 28 18:54:28 1995 Tomi Leppikangas (tomilepp@paju.oulu.fi)
* [controls/edit.c]
Small patch to fix edit-control when it's created with text.
Sun Feb 26 20:22:15 1995 Michael Veksler (e1678223@tochnapc2.technion.ac.il)
* [tools/make_debug]
The created macros won't have side effects anymore when used in
an "if-else" structure. No more warnings from the compiler when
compiled without defining DEBUG_RUNTIME.
Sun Feb 26 20:20:49 1995 Michael Patra <micky@marie.physik.TU-Berlin.DE>
* [controls/listbox.c]
ListBoxDeleteString(): Fixed
* [loader/selector.c]
GetMemoryReference(): When special segments are referenced by
pseudo-functions like __0040H, a reference to a "normal" segment
will be returned preventing the program from crashing as soon
as the referenced segment is actually accessed.
Sun Feb 26 15:55:14 MET 1995 Martin von Loewis (loewis@informatik.hu-berlin.de)
* [Configure]
Ask for OLE stubs and malloc debugging
* [Imakefile]
link with libmcheck.a if necessary
* [if1632/relay.c][include/dll.h][if1632/Imakefile]
Add OLE stubs, increase number of builtins
dll_name_table_entry_s: new field dll_is_used
* [loader/library.c]
GetModuleHandle,ModuleNext: Check dll_is_used
* [loader/ne_image.c]
Bark on unsupported NE_RADDR_LOWBYTE flag (what is it supposed
to mean, anyway?)
* [misc/olecli.c][misc/olesvr.c]
New files. Add to misc/Imakefile
* [misc/dos_fs.c]
DOS_GetUnixFileName: make a copy of the input parameter to
prevent overwriting
* [misc/main.c]
MAIN_ParseDLLOptions: new function
MAIN_ParseOptions: treat -dll command line flag
main: add support for malloc debugging
Fri Feb 24 12:43:27 1995 Erik Svendsen <z3esv@kmd-ac.dk>
* [loader/signal.c]
Small patch for people using FreeBSD-2.1.0.
Fri Feb 17 22:49:18 1995 Miguel de Icaza (miguel@roxanne.nuclecu.unam.mx)
* [toolkit/sup.c]
Added return values to the Call* routines
* [toolkit/winmain.c]
Load the resource file properly for WineLib applications.
----------------------------------------------------------------------
Thu Feb 16 18:57:31 1995 Alexandre Julliard (julliard@sunsite.unc.edu)

View File

@ -7,7 +7,6 @@
WINELIB=''
SHORTNAMES=''
XPM=''
LANGUAGE=not_matching
NEWBUILD=''
ALLDEFINES=''
@ -29,6 +28,9 @@ prompt ()
fi
}
echo Read the RELEASE-NOTES for an explanation of the various flags
echo
echo -n 'Build Wine as emulator or library (E/L) [E]? '
read input
if [ "$input" = 'l' -o "$input" = 'L' ]
@ -46,16 +48,6 @@ then
ALLDEFINES="$ALLDEFINES -DSHORTNAMES"
fi
echo
echo -n 'Use the XPM library (Y/N) [Y]? '
read input
if [ "$input" = 'n' -o "$input" = 'N' ]
then :
else
XPM='#define USE_XPM'
ALLDEFINES="$ALLDEFINES -DUSE_XPM"
fi
LANGS=`echo En rc/sysres_*.rc | sed -e 's/rc\/sysres_//g' -e 's/\.rc//g' -e 's/ /\//g;'`
while expr "$LANGS" : ".*$LANGUAGE" = 0 > /dev/null
do
@ -67,6 +59,15 @@ do
done
ALLDEFINES="$ALLDEFINES -ALANG\($LANGUAGE\)"
prompt "Malloc debugging" MALLOC_DEBUGGING N
if [ MALLOC_DEBUGGING = 'Y' -o $MALLOC_DEBUGGING = 'y' ]
then
MALLOC_DEBUGGING="#define MALLOC_DEBUGGING"
ALLDEFINES="$ALLDEFINES -DMALLOC_DEBUGGING"
else
MALLOC_DEBUGGING=''
fi
if [ "`(domainname)`" = 'amscons.com' ]
then
echo
@ -202,8 +203,8 @@ cat > autoconf.h << EOF
/* autoconf.h generated automatically. Run Configure. */
$WINELIB
$SHORTNAMES
$XPM
$NEWBUILD
$MALLOC_DEBUGGING
#define WINE_INI_GLOBAL "$WINE_CONFIGFILE"
#define AutoDefines $ALLDEFINES
EOF

View File

@ -89,17 +89,20 @@ SYSLIBS = -ll -lm -lgnumalloc
SYSLIBS = -lm -lg
#endif
#ifdef USE_XPM
/* You may need to add the full path of your libXpm here */
XPM_LIB = -lXpm
#ifdef MALLOC_DEBUGGING
MALLOCLIB = -lmcheck
#else
XPM_LIB =
MALLOCLIB =
#endif
MakeSubdirs($(SUBDIRS))
DependSubdirs($(SUBDIRS))
#ifndef WINELIB
NormalProgramTarget(wine,$(OBJS),$(DEPXLIB),$(XPM_LIB) $(XLIB),$(SYSLIBS))
NormalProgramTarget(wine,$(OBJS),$(DEPXLIB),$(XPM_LIB) $(XLIB),$(MALLOCLIB) $(SYSLIBS))
AllTarget(wine.sym)
#else
NormalLibraryTarget(wine,$(OBJS))

6
README
View File

@ -17,9 +17,13 @@ You must have one of:
NetBSD-current
FreeBSD-current or FreeBSD 1.1
You also need to have libXpm installed on your system. The sources for
it are probably available on the ftp site where you got Wine. They can
also be found on ftp.x.org and all its mirror sites.
To build Wine, first do a "./Configure" and then a "make" (or "gmake"
if you're running *BSD). The executable "wine" will be built. "wine"
will load and run 16-bit Windows' executables.
will load and run 16-bit Windows executables.
To upgrade to a new release by using a patch file, first cd to the
top-level directory of the release (the one containing this README

29
RELEASE-NOTES Normal file
View File

@ -0,0 +1,29 @@
This file contains information about the current release of Wine.
If you are new to Wine, read the files ANNOUNCE and README and the FAQ
list first.
If you want to contribute code to Wine, read the DEVELOPER-HINTS. The
primary source of information to developers is the ChangeLog (next to
the source, of course).
1. make: No rule to make target xxx/xxx.o. Stop.
This frequently happens when a prior attempt to make xxx.o failed.
In the current setup, make does not terminate then, but continues and
realises the problem later on. 'make' again and watch the output. Be
sure to analyze the problem before you report it to the newsgroup.
2. What are these questions in Configure?
Emulator/Library: You need an emulator when you want to run MS-Win
binaries. You need a library when you want to compile the source code
of a Windows program.
Short filenames: Some file systems are limited to 11 characters per
file name. Files generated in if1632 will get gracefully translated
names.
Language: Wine can present the system menu in multiple languages. Select
one of English, German, or Norwegian here.
Malloc debugging: When enabled, the mtrace and mcheck GNU libc functions
are called. You might want to set the MALLOC_TRACE environment variable
to a trace file name. If your system supports another way of malloc
debugging, feel free to add it.
Config file: Sets the Wine environment. See README for details.

View File

@ -501,6 +501,8 @@ long EDIT_NCCreateMsg(HWND hwnd, LONG lParam)
es->hText = EDIT_HeapAlloc(hwnd, EditBufLen(wndPtr) + 2);
text = EDIT_HeapAddr(hwnd, es->hText);
memset(text, 0, es->textlen + 2);
es->wlines = 0;
es->textwidth = 0;
EDIT_ClearTextPointers(hwnd);
}
else
@ -569,12 +571,10 @@ long EDIT_CreateMsg(HWND hwnd, LONG lParam)
/* --- other structure variables */
GetTextMetrics(hdc, &tm);
es->txtht = tm.tmHeight + tm.tmExternalLeading;
es->wlines = 0;
es->wtop = es->wleft = 0;
es->CurrCol = es->CurrLine = 0;
es->WndCol = es->WndRow = 0;
es->TextChanged = FALSE;
es->textwidth = 0;
es->SelBegLine = es->SelBegCol = 0;
es->SelEndLine = es->SelEndCol = 0;
es->hFont = 0;

View File

@ -920,12 +920,16 @@ int ListBoxDeleteString(HWND hwnd, UINT uIndex)
lpls = lphl->lpFirst;
if (lpls == NULL) return LB_ERR;
if (uIndex > lphl->ItemsCount) return LB_ERR;
for(Count = 1; Count < uIndex; Count++) {
if( uIndex == 0 )
lphl->lpFirst = lpls->lpNext;
else {
for(Count = 0; Count < uIndex; Count++) {
if (lpls->lpNext == NULL) return LB_ERR;
lpls2 = lpls;
lpls = (LPLISTSTRUCT)lpls->lpNext;
}
lpls2->lpNext = (LPLISTSTRUCT)lpls->lpNext;
}
lphl->ItemsCount--;
if (lpls->hData != 0) LIST_HEAP_FREE(lphl, lpls->hData);
if (lpls->hMem != 0) LIST_HEAP_FREE(lphl, lpls->hMem);

View File

@ -19,6 +19,13 @@ DLLOBJS = \
dll_keyboard.o \
dll_mmsystem.o \
dll_mouse.o \
dll_ole2.o \
dll_ole2conv.o \
dll_ole2disp.o \
dll_ole2nls.o \
dll_ole2prox.o \
dll_olecli.o \
dll_olesvr.o \
dll_shell.o \
dll_sound.o \
dll_stress.o \
@ -46,6 +53,13 @@ MakeDllFromSpec(keyboard)
MakeDllFromSpec(shell)
MakeDllFromSpec(mmsystem)
MakeDllFromSpec(mouse)
MakeDllFromSpec(ole2)
MakeDllFromSpec(ole2conv)
MakeDllFromSpec(ole2disp)
MakeDllFromSpec(ole2nls)
MakeDllFromSpec(ole2prox)
MakeDllFromSpec(olecli)
MakeDllFromSpec(olesvr)
MakeDllFromSpec(sound)
MakeDllFromSpec(stress)
MakeDllFromSpec(system)

View File

@ -183,8 +183,8 @@ LONG CallWindowProc( WNDPROC func, HWND hwnd, WORD message,
}
else if (IS_16_BIT_ADDRESS(func))
{
dprintf_callback(stddeb, "CallWindowProc // 16bit func=%08x !\n",
(unsigned int) func);
dprintf_callback(stddeb, "CallWindowProc // 16bit func=%08x ds=%04x!\n",
(unsigned int) func, pStack16Frame->ds );
PushOn16( CALLBACK_SIZE_WORD, hwnd );
PushOn16( CALLBACK_SIZE_WORD, message );
PushOn16( CALLBACK_SIZE_WORD, wParam );

150
if1632/ole2.spec Normal file
View File

@ -0,0 +1,150 @@
name OLE2
id 16
length 161
#1 OLEBUILDVERSION
#2 OLEINITIALIZE
#3 OLEUNINITIALIZE
#4 DLLGETCLASSOBJECT
#5 WEP
#6 OLEQUERYLINKFROMDATA
#7 OLEQUERYCREATEFROMDATA
#8 OLECREATEFROMDATA
#9 OLECREATELINKFROMDATA
#10 OLECREATE
#11 OLECREATELINK
#12 OLELOAD
#13 OLESAVE
#14 OLERUN
#15 ___EXPORTEDSTUB
#16 OLEISRUNNING
#17 OLELOCKRUNNING
#18 READCLASSSTG
#19 WRITECLASSSTG
#20 READCLASSSTM
#21 WRITECLASSSTM
#22 BINDMONIKER
#23 MKPARSEDISPLAYNAME
#24 OLESAVETOSTREAM
#25 OLELOADFROMSTREAM
#26 CREATEBINDCTX
#27 CREATEITEMMONIKER
#28 CREATEFILEMONIKER
#29 CREATEGENERICCOMPOSITE
#30 GETRUNNINGOBJECTTABLE
#31 OLEGETMALLOC
#32 RELEASESTGMEDIUM
#33 READSTRINGSTREAM
#34 WRITESTRINGSTREAM
#35 REGISTERDRAGDROP
#36 REVOKEDRAGDROP
#37 DODRAGDROP
#38 CREATEOLEADVISEHOLDER
#39 CREATEDATAADVISEHOLDER
#40 OLECREATEMENUDESCRIPTOR
#41 OLESETMENUDESCRIPTOR
#42 OLEDESTROYMENUDESCRIPTOR
#43 OPENORCREATESTREAM
#44 CREATEANTIMONIKER
#45 CREATEPOINTERMONIKER
#46 MONIKERRELATIVEPATHTO
#47 MONIKERCOMMONPREFIXWITH
#48 ISACCELERATOR
#49 OLESETCLIPBOARD
#50 OLEGETCLIPBOARD
#51 OLEDUPLICATEDATA
#52 OLEGETICONOFFILE
#53 OLEGETICONOFCLASS
#54 CREATEILOCKBYTESONHGLOBAL
#55 GETHGLOBALFROMILOCKBYTES
#56 OLEMETAFILEPICTFROMICONANDLABEL
#57 GETCLASSFILE
#58 OLEDRAW
#59 OLECREATEDEFAULTHANDLER
#60 OLECREATEEMBEDDINGHELPER
#61 OLECONVERTISTORAGETOOLESTREAMEX
#62 OLECONVERTOLESTREAMTOISTORAGEEX
#63 SETDOCUMENTBITSTG
#64 GETDOCUMENTBITSTG
#65 WRITEOLESTG
#66 READOLESTG
#67 OLECREATEFROMFILE
#68 OLECREATELINKTOFILE
#69 CREATEDATACACHE
#70 OLECONVERTISTORAGETOOLESTREAM
#71 OLECONVERTOLESTREAMTOISTORAGE
#74 READFMTUSERTYPESTG
#75 WRITEFMTUSERTYPESTG
#76 OLEFLUSHCLIPBOARD
#77 OLEISCURRENTCLIPBOARD
#78 OLETRANSLATEACCELERATOR
#79 OLEDOAUTOCONVERT
#80 OLEGETAUTOCONVERT
#81 OLESETAUTOCONVERT
#82 GETCONVERTSTG
#83 SETCONVERTSTG
#84 CREATESTREAMONHGLOBAL
#85 GETHGLOBALFROMSTREAM
#86 OLESETCONTAINEDOBJECT
#87 OLENOTEOBJECTVISIBLE
#88 OLECREATESTATICFROMDATA
#89 OLEREGGETUSERTYPE
#90 OLEREGGETMISCSTATUS
#91 OLEREGENUMFORMATETC
#92 OLEREGENUMVERBS
#93 OLEGETENUMFORMATETC
#100 MAKEDEBUGSTREAM
#104 DBGLOGOPEN
#105 DBGLOGCLOSE
#106 DBGLOGOUTPUTDEBUGSTRING
#107 DBGLOGWRITE
#108 DBGLOGTIMESTAMP
#109 DBGLOGWRITEBANNER
#110 DBGDUMPOBJECT
#111 DBGISOBJECTVALID
#112 DUMPALLOBJECTS
#113 VALIDATEALLOBJECTS
#114 DBGDUMPCLASSNAME
#115 DBGDUMPEXTERNALOBJECT
#120 _IID_IENUMUNKNOWN
#121 _IID_IENUMSTRING
#122 _IID_IENUMMONIKER
#123 _IID_IENUMFORMATETC
#124 _IID_IENUMOLEVERB
#125 _IID_IENUMSTATDATA
#126 _IID_IENUMGENERIC
#127 _IID_IENUMHOLDER
#128 _IID_IENUMCALLBACK
#129 _IID_IPERSISTSTREAM
#130 _IID_IPERSISTSTORAGE
#131 _IID_IPERSISTFILE
#132 _IID_IPERSIST
#133 _IID_IVIEWOBJECT
#134 _IID_IDATAOBJECT
#135 _IID_IADVISESINK
#136 _IID_IDATAADVISEHOLDER
#137 _IID_IOLEADVISEHOLDER
#138 _IID_IOLEOBJECT
#139 _IID_IOLEINPLACEOBJECT
#140 _IID_IOLEWINDOW
#141 _IID_IOLEINPLACEUIWINDOW
#142 _IID_IOLEINPLACEFRAME
#143 _IID_IOLEINPLACEACTIVEOBJECT
#144 _IID_IOLECLIENTSITE
#145 _IID_IOLEINPLACESITE
#146 _IID_IPARSEDISPLAYNAME
#147 _IID_IOLECONTAINER
#148 _IID_IOLEITEMCONTAINER
#149 _IID_IOLELINK
#150 _IID_IOLECACHE
#151 _IID_IOLEMANAGER
#152 _IID_IOLEPRESOBJ
#153 _IID_IDROPSOURCE
#154 _IID_IDROPTARGET
#155 _IID_IDEBUG
#156 _IID_IDEBUGSTREAM
#157 _IID_IADVISESINK2
#158 _IID_IVIEWOBJECT2
#159 _IID_IOLECACHE2
#160 _IID_IOLECACHECONTROL
#161 _IID_IRUNNABLEOBJECT

12
if1632/ole2conv.spec Normal file
View File

@ -0,0 +1,12 @@
name ole2conv
id 17
length 10
#1 GETFILTERINFO
#2 IMPORTGR
#3 GETFILTERPREF
#4 IMPORTEMBEDDEDGR
#5 QD2GDI
#6 STATUSPROC
#7 ENUMFONTFUNC
#8 WEP
#9 ___EXPORTEDSTUB

113
if1632/ole2disp.spec Normal file
View File

@ -0,0 +1,113 @@
name ole2disp
id 18
length 110
#1 DLLGETCLASSOBJECT
#2 SYSALLOCSTRING
#3 SYSREALLOCSTRING
#4 SYSALLOCSTRINGLEN
#5 SYSREALLOCSTRINGLEN
#6 SYSFREESTRING
#7 SYSSTRINGLEN
#8 VARIANTINIT
#9 VARIANTCLEAR
#10 VARIANTCOPY
#11 VARIANTCOPYIND
#12 VARIANTCHANGETYPE
#13 VARIANTTIMETODOSDATETIME
#14 DOSDATETIMETOVARIANTTIME
#15 SAFEARRAYCREATE
#16 SAFEARRAYDESTROY
#17 SAFEARRAYGETDIM
#18 SAFEARRAYGETELEMSIZE
#19 SAFEARRAYGETUBOUND
#20 SAFEARRAYGETLBOUND
#21 SAFEARRAYLOCK
#22 SAFEARRAYUNLOCK
#23 SAFEARRAYACCESSDATA
#24 SAFEARRAYUNACCESSDATA
#25 SAFEARRAYGETELEMENT
#26 SAFEARRAYPUTELEMENT
#27 SAFEARRAYCOPY
#28 DISPGETPARAM
#29 DISPGETIDSOFNAMES
#30 DISPINVOKE
#31 CREATEDISPTYPEINFO
#32 CREATESTDDISPATCH
#33 _IID_IDISPATCH
#34 _IID_IENUMVARIANT
#35 REGISTERACTIVEOBJECT
#36 REVOKEACTIVEOBJECT
#37 GETACTIVEOBJECT
#38 SAFEARRAYALLOCDESCRIPTOR
#39 SAFEARRAYALLOCDATA
#40 SAFEARRAYDESTROYDESCRIPTOR
#41 SAFEARRAYDESTROYDATA
#42 SAFEARRAYREDIM
#43 VARI2FROMI4
#44 VARI2FROMR4
#45 VARI2FROMR8
#46 VARI2FROMCY
#47 VARI2FROMDATE
#48 VARI2FROMSTR
#49 VARI2FROMDISP
#50 VARI2FROMBOOL
#51 VARI4FROMI2
#52 VARI4FROMR4
#53 VARI4FROMR8
#54 VARI4FROMCY
#55 VARI4FROMDATE
#56 VARI4FROMSTR
#57 VARI4FROMDISP
#58 VARI4FROMBOOL
#59 VARR4FROMI2
#60 VARR4FROMI4
#61 VARR4FROMR8
#62 VARR4FROMCY
#63 VARR4FROMDATE
#64 VARR4FROMSTR
#65 VARR4FROMDISP
#66 VARR4FROMBOOL
#67 VARR8FROMI2
#68 VARR8FROMI4
#69 VARR8FROMR4
#70 VARR8FROMCY
#71 VARR8FROMDATE
#72 VARR8FROMSTR
#73 VARR8FROMDISP
#74 VARR8FROMBOOL
#75 VARDATEFROMI2
#76 VARDATEFROMI4
#77 VARDATEFROMR4
#78 VARDATEFROMR8
#79 VARDATEFROMCY
#80 VARDATEFROMSTR
#81 VARDATEFROMDISP
#82 VARDATEFROMBOOL
#83 VARCYFROMI2
#84 VARCYFROMI4
#85 VARCYFROMR4
#86 VARCYFROMR8
#87 VARCYFROMDATE
#88 VARCYFROMSTR
#89 VARCYFROMDISP
#90 VARCYFROMBOOL
#91 VARBSTRFROMI2
#92 VARBSTRFROMI4
#93 VARBSTRFROMR4
#94 VARBSTRFROMR8
#95 VARBSTRFROMCY
#96 VARBSTRFROMDATE
#97 VARBSTRFROMDISP
#98 VARBSTRFROMBOOL
#99 VARBOOLFROMI2
#100 VARBOOLFROMI4
#101 VARBOOLFROMR4
#102 VARBOOLFROMR8
#103 VARBOOLFROMDATE
#104 VARBOOLFROMCY
#105 VARBOOLFROMSTR
#106 VARBOOLFROMDISP
#107 DOINVOKEMETHOD
#108 VARIANTCHANGETYPEEX
#109 WEP
#110 ___EXPORTEDSTUB

14
if1632/ole2nls.spec Normal file
View File

@ -0,0 +1,14 @@
name ole2nls
id 19
length 11
#1 GETUSERDEFAULTLCID
#2 GETSYSTEMDEFAULTLCID
#3 GETUSERDEFAULTLANGID
#4 GETSYSTEMDEFAULTLANGID
#5 GETLOCALEINFOA
#6 LCMAPSTRINGA
#7 GETSTRINGTYPEA
#8 COMPARESTRINGA
#9 WEP
#10 LIBMAIN
#11 NOTIFYWINDOWPROC

6
if1632/ole2prox.spec Normal file
View File

@ -0,0 +1,6 @@
name ole2prox
id 20
length 3
#1 DLLGETCLASSOBJECT
#2 WEP
#3 ___EXPORTEDSTUB

181
if1632/olecli.spec Normal file
View File

@ -0,0 +1,181 @@
name olecli
id 21
length 954
#1 WEP
#2 OLEDELETE
#3 OLESAVETOSTREAM
#4 OLELOADFROMSTREAM
#6 OLECLONE
#7 OLECOPYFROMLINK
#8 OLEEQUAL
#9 OLEQUERYLINKFROMCLIP
#10 OLEQUERYCREATEFROMCLIP
#11 OLECREATELINKFROMCLIP
#12 OLECREATEFROMCLIP
#13 OLECOPYTOCLIPBOARD
#14 OLEQUERYTYPE
#15 OLESETHOSTNAMES
#16 OLESETTARGETDEVICE
#17 OLESETBOUNDS
#18 OLEQUERYBOUNDS
#19 OLEDRAW
#20 OLEQUERYOPEN
#21 OLEACTIVATE
#22 OLEUPDATE
#23 OLERECONNECT
#24 OLEGETLINKUPDATEOPTIONS
#25 OLESETLINKUPDATEOPTIONS
#26 OLEENUMFORMATS
#27 OLECLOSE
#28 OLEGETDATA
#29 OLESETDATA
#30 OLEQUERYPROTOCOL
#31 OLEQUERYOUTOFDATE
#32 OLEOBJECTCONVERT
#33 OLECREATEFROMTEMPLATE
#34 OLECREATE
#35 OLEQUERYRELEASESTATUS
#36 OLEQUERYRELEASEERROR
#37 OLEQUERYRELEASEMETHOD
#38 OLECREATEFROMFILE
#39 OLECREATELINKFROMFILE
#40 OLERELEASE
41 pascal OleRegisterClientDoc(ptr ptr long ptr) OleRegisterClientDoc(1 2 3 4)
42 pascal OleRevokeClientDoc(long) OleRevokeClientDoc(1)
43 pascal OleRenameClientDoc(long ptr) OleRenameClientDoc(1 2)
#44 OLEREVERTCLIENTDOC
#45 OLESAVEDCLIENTDOC
#46 OLERENAME
#47 OLEENUMOBJECTS
#48 OLEQUERYNAME
#49 OLESETCOLORSCHEME
#50 OLEREQUESTDATA
#54 OLELOCKSERVER
#55 OLEUNLOCKSERVER
#56 OLEQUERYSIZE
#57 OLEEXECUTE
#58 OLECREATEINVISIBLE
#59 OLEQUERYCLIENTVERSION
#60 OLEISDCMETA
#100 DOCWNDPROC
#101 SRVRWNDPROC
#102 MFCALLBACKFUNC
#110 DEFLOADFROMSTREAM
#111 DEFCREATEFROMCLIP
#112 DEFCREATELINKFROMCLIP
#113 DEFCREATEFROMTEMPLATE
#114 DEFCREATE
#115 DEFCREATEFROMFILE
#116 DEFCREATELINKFROMFILE
#117 DEFCREATEINVISIBLE
#200 LERELEASE
#201 LESHOW
#202 LEGETDATA
#203 LESETDATA
#204 LESETHOSTNAMES
#205 LESETTARGETDEVICE
#206 LESETBOUNDS
#207 LESAVETOSTREAM
#208 LECLONE
#209 LECOPYFROMLINK
#210 LEEQUAL
#211 LECOPY
#212 LEQUERYTYPE
#213 LEQUERYBOUNDS
#214 LEDRAW
#215 LEQUERYOPEN
#216 LEACTIVATE
#218 LEUPDATE
#219 LERECONNECT
#220 LEENUMFORMAT
#221 LEQUERYPROTOCOL
#222 LEQUERYOUTOFDATE
#223 LEOBJECTCONVERT
#224 LECHANGEDATA
#225 LECLOSE
#226 LEGETUPDATEOPTIONS
#227 LESETUPDATEOPTIONS
#228 LEEXECUTE
#229 LEOBJECTLONG
#230 LECREATEINVISIBLE
#300 MFRELEASE
#301 MFGETDATA
#302 MFSAVETOSTREAM
#303 MFCLONE
#304 MFEQUAL
#305 MFCOPY
#307 MFQUERYBOUNDS
#308 MFDRAW
#309 MFENUMFORMAT
#310 MFCHANGEDATA
#400 BMRELEASE
#401 BMGETDATA
#402 BMSAVETOSTREAM
#403 BMCLONE
#404 BMEQUAL
#405 BMCOPY
#407 BMQUERYBOUNDS
#408 BMDRAW
#409 BMENUMFORMAT
#410 BMCHANGEDATA
#500 DIBRELEASE
#501 DIBGETDATA
#502 DIBSAVETOSTREAM
#503 DIBCLONE
#504 DIBEQUAL
#505 DIBCOPY
#507 DIBQUERYBOUNDS
#508 DIBDRAW
#509 DIBENUMFORMAT
#510 DIBCHANGEDATA
#600 GENRELEASE
#601 GENGETDATA
#602 GENSETDATA
#603 GENSAVETOSTREAM
#604 GENCLONE
#605 GENEQUAL
#606 GENCOPY
#608 GENQUERYBOUNDS
#609 GENDRAW
#610 GENENUMFORMAT
#611 GENCHANGEDATA
#701 ERRSHOW
#702 ERRSETDATA
#703 ERRSETHOSTNAMES
#704 ERRSETTARGETDEVICE
#705 ERRSETBOUNDS
#706 ERRCOPYFROMLINK
#707 ERRQUERYOPEN
#708 ERRACTIVATE
#709 ERRCLOSE
#710 ERRUPDATE
#711 ERRRECONNECT
#712 ERRQUERYPROTOCOL
#713 ERRQUERYOUTOFDATE
#714 ERROBJECTCONVERT
#715 ERRGETUPDATEOPTIONS
#716 ERRSETUPDATEOPTIONS
#717 ERREXECUTE
#718 ERROBJECTLONG
#800 PBLOADFROMSTREAM
#801 PBCREATEFROMCLIP
#802 PBCREATELINKFROMCLIP
#803 PBCREATEFROMTEMPLATE
#804 PBCREATE
#805 PBDRAW
#806 PBQUERYBOUNDS
#807 PBCOPYTOCLIPBOARD
#808 PBCREATEFROMFILE
#809 PBCREATELINKFROMFILE
#810 PBENUMFORMATS
#811 PBGETDATA
#812 PBCREATEINVISIBLE
#910 OBJQUERYNAME
#911 OBJRENAME
#912 OBJQUERYTYPE
#913 OBJQUERYSIZE
#950 CONNECTDLGPROC
#951 SETNETNAME
#952 CHECKNETDRIVE
#953 SETNEXTNETDRIVE
#954 GETTASKVISIBLEWINDOW

26
if1632/olesvr.spec Normal file
View File

@ -0,0 +1,26 @@
name olesvr
id 22
length 31
#1 WEP
2 pascal OleRegisterServer(ptr ptr ptr word word) OleRegisterServer(1 2 3 4 5)
3 pascal OleRevokeServer(long) OleRevokeServer(1)
4 pascal OleBlockServer(long) OleBlockServer(1)
5 pascal OleUnblockServer(long ptr) OleUnblockServer(1 2)
6 pascal OleRegisterServerDoc(long ptr ptr ptr) OleRegisterServerDoc(1 2 3 4)
7 pascal OleRevokeServerDoc(long) OleRevokeServerDoc(1)
#8 OLERENAMESERVERDOC
#9 OLEREVERTSERVERDOC
#10 OLESAVEDSERVERDOC
#11 OLEREVOKEOBJECT
#12 OLEQUERYSERVERVERSION
#21 SRVRWNDPROC
#22 DOCWNDPROC
#23 ITEMWNDPROC
#24 SENDDATAMSG
#25 FINDITEMWND
#26 ITEMCALLBACK
#27 TERMINATECLIENTS
#28 TERMINATEDOCCLIENTS
#29 DELETECLIENTINFO
#30 SENDRENAMEMSG
#31 ENUMFORTERMINATE

View File

@ -42,21 +42,28 @@ dprintf_stack
struct dll_name_table_entry_s dll_builtin_table[N_BUILTINS] =
{
{ "KERNEL", WineLibSkip(KERNEL_table), 410, 1 },
{ "USER", WineLibSkip(USER_table), 540, 2 },
{ "GDI", WineLibSkip(GDI_table), 490, 3 },
{ "UNIXLIB", WineLibSkip(UNIXLIB_table), 10, 4 },
{ "WIN87EM", WineLibSkip(WIN87EM_table), 10, 5 },
{ "SHELL", WineLibSkip(SHELL_table), 103, 6 },
{ "SOUND", WineLibSkip(SOUND_table), 20, 7 },
{ "KEYBOARD",WineLibSkip(KEYBOARD_table),137, 8 },
{ "WINSOCK", WineLibSkip(WINSOCK_table), 155, 9 },
{ "STRESS", WineLibSkip(STRESS_table), 15, 10},
{ "MMSYSTEM",WineLibSkip(MMSYSTEM_table),1226,11},
{ "SYSTEM", WineLibSkip(SYSTEM_table), 20 ,12},
{ "TOOLHELP",WineLibSkip(TOOLHELP_table), 83, 13},
{ "MOUSE", WineLibSkip(MOUSE_table), 8, 14},
{ "EMUCOMMDLG", WineLibSkip(COMMDLG_table), 31, 15},
{ "KERNEL", WineLibSkip(KERNEL_table), 410, 1, 1 },
{ "USER", WineLibSkip(USER_table), 540, 2, 1 },
{ "GDI", WineLibSkip(GDI_table), 490, 3, 1 },
{ "UNIXLIB", WineLibSkip(UNIXLIB_table), 10, 4, 1 },
{ "WIN87EM", WineLibSkip(WIN87EM_table), 10, 5, 1 },
{ "SHELL", WineLibSkip(SHELL_table), 103, 6, 1 },
{ "SOUND", WineLibSkip(SOUND_table), 20, 7, 1 },
{ "KEYBOARD",WineLibSkip(KEYBOARD_table),137, 8, 1 },
{ "WINSOCK", WineLibSkip(WINSOCK_table), 155, 9, 1 },
{ "STRESS", WineLibSkip(STRESS_table), 15, 10, 1},
{ "MMSYSTEM",WineLibSkip(MMSYSTEM_table),1226,11, 1},
{ "SYSTEM", WineLibSkip(SYSTEM_table), 20 ,12, 1},
{ "TOOLHELP",WineLibSkip(TOOLHELP_table), 83, 13, 1},
{ "MOUSE", WineLibSkip(MOUSE_table), 8, 14, 1},
{ "COMMDLG", WineLibSkip(COMMDLG_table), 31, 15, 1},
{ "OLE2", WineLibSkip(OLE2_table), 31, 16, 1},
{ "OLE2CONV",WineLibSkip(OLE2CONV_table), 31, 17, 1},
{ "OLE2DISP",WineLibSkip(OLE2DISP_table), 31, 18, 1},
{ "OLE2NLS", WineLibSkip(OLE2NLS_table), 31, 19, 1},
{ "OLE2PROX",WineLibSkip(OLE2PROX_table), 31, 20, 1},
{ "OLECLI", WineLibSkip(OLECLI_table), 31, 21, 1},
{ "OLESVR", WineLibSkip(OLESVR_table), 31, 22, 1},
};
/* don't forget to increase N_BUILTINS in dll.h if you add a dll */
@ -79,7 +86,14 @@ struct dll_conversions {
SYSTEM_offsets, SYSTEM_types, /* SYSTEM */
TOOLHELP_offsets, TOOLHELP_types, /* TOOLHELP */
MOUSE_offsets, MOUSE_types, /* MOUSE */
COMMDLG_offsets, COMMDLG_types /* EMUCOMMDLG */
COMMDLG_offsets, COMMDLG_types, /* EMUCOMMDLG */
OLE2_offsets, OLE2_types, /* OLE2 */
OLE2CONV_offsets, OLE2CONV_types, /* OLE2CONV */
OLE2DISP_offsets, OLE2DISP_types, /* OLE2DISP */
OLE2NLS_offsets, OLE2NLS_types, /* OLE2NLS */
OLE2DISP_offsets, OLE2DISP_types, /* OLE2PROX */
OLECLI_offsets, OLECLI_types, /* OLE2CLI */
OLESVR_offsets, OLESVR_types /* OLE2CLI */
};
@ -141,17 +155,14 @@ DLLRelay(unsigned int func_num, unsigned int seg_off)
if (debugging_relay)
{
unsigned int *ret_addr;
ret_addr = (unsigned int *) ((char *) seg_off + 0x14);
printf("Call %s (%s.%d), stack=%04x:%04x, ",
printf( "Call %s (%s.%d), stack=%04x:%04x, ret=%04x:%04x",
dll_p->export_name,
dll_builtin_table[dll_id].dll_name, ordinal,
seg_off >> 16, seg_off & 0xffff);
printf("ret=%08x", *ret_addr);
printf(" ESP=%04x, EBP=%04x, SS=%04x\n",
IF1632_Saved16_sp, IF1632_Saved16_bp,
IF1632_Saved16_ss);
seg_off >> 16, seg_off & 0xffff,
pStack16Frame->cs, pStack16Frame->ip );
printf(" bp=%04x ds=%04x args=%d\n",
pStack16Frame->bp, pStack16Frame->ds,
pStack16Frame->arg_length );
if(debugging_stack)
{
@ -245,15 +256,17 @@ DLLRelay(unsigned int func_num, unsigned int seg_off)
arg_table[12], arg_table[13], arg_table[14],
arg_table[15]);
pStack16Frame = pOldStack16Frame;
if (debugging_relay)
{
printf("Returning %08x from %s (%s.%d)\n",
printf("Returning %08x from %s (%s.%d) ds=%04x\n",
ret_val,
dll_p->export_name,
dll_builtin_table[dll_id].dll_name, ordinal);
dll_builtin_table[dll_id].dll_name, ordinal,
pStack16Frame->ds );
}
pStack16Frame = pOldStack16Frame;
return ret_val;
}
#endif
@ -267,7 +280,8 @@ FindDLLTable(char *dll_name)
int i;
for (i = 0; i < N_BUILTINS; i++)
if (strcasecmp(dll_builtin_table[i].dll_name, dll_name) == 0)
if (strcasecmp(dll_builtin_table[i].dll_name, dll_name) == 0
&& dll_builtin_table[i].dll_is_used)
#ifdef WINELIB
return dll_builtin_table[i].dll_number;
#else

View File

@ -43,4 +43,8 @@ extern HBITMAP BITMAP_SelectObject( HDC hdc, DC * dc, HBITMAP hbitmap,
extern int DIB_GetImageWidthBytes( int width, int depth );
extern int DIB_BitmapInfoSize( BITMAPINFO * info, WORD coloruse );
/* objects/oembitmap.c */
extern HBITMAP OBM_LoadBitmap( WORD id );
extern HICON OBM_LoadIcon( WORD id );
#endif /* __WINE_BITMAP_H */

View File

@ -1,26 +0,0 @@
#define check_boxes_width 56
#define check_boxes_height 39
static char check_boxes_bits[] = {
0xff, 0xdf, 0xff, 0xf7, 0xff, 0xfd, 0x7f, 0x01, 0xd0, 0x00, 0xf6, 0xff,
0xfd, 0x7f, 0x01, 0x50, 0x01, 0x35, 0x80, 0x1d, 0x70, 0x01, 0x50, 0x82,
0x34, 0x80, 0x2d, 0x68, 0x01, 0x50, 0x44, 0x34, 0x80, 0x4d, 0x64, 0x01,
0x50, 0x28, 0x34, 0x80, 0x8d, 0x62, 0x01, 0x50, 0x10, 0x34, 0x80, 0x0d,
0x61, 0x01, 0x50, 0x28, 0x34, 0x80, 0x8d, 0x62, 0x01, 0x50, 0x44, 0x34,
0x80, 0x4d, 0x64, 0x01, 0x50, 0x82, 0x34, 0x80, 0x2d, 0x68, 0x01, 0x50,
0x01, 0x35, 0x80, 0x1d, 0x70, 0x01, 0xd0, 0x00, 0xf6, 0xff, 0xfd, 0x7f,
0xff, 0xdf, 0xff, 0xf7, 0xff, 0xfd, 0x7f, 0xe0, 0x00, 0x38, 0x00, 0x0e,
0x80, 0x03, 0x18, 0x03, 0xc6, 0x80, 0x3f, 0xe0, 0x0f, 0x04, 0x04, 0x01,
0xc1, 0x71, 0x70, 0x1c, 0x02, 0x88, 0x38, 0xe2, 0xe0, 0xb8, 0x3b, 0x02,
0x88, 0x7c, 0x62, 0xc0, 0xd8, 0x37, 0x01, 0x50, 0xfe, 0x34, 0x80, 0xed,
0x6f, 0x01, 0x50, 0xfe, 0x34, 0x80, 0xed, 0x6f, 0x01, 0x50, 0xfe, 0x34,
0x80, 0xed, 0x6f, 0x02, 0x88, 0x7c, 0x62, 0xc0, 0xd8, 0x37, 0x02, 0x88,
0x38, 0xe2, 0xe0, 0xb8, 0x3b, 0x04, 0x04, 0x01, 0xc1, 0x71, 0x70, 0x1c,
0x18, 0x03, 0xc6, 0x80, 0x3f, 0xe0, 0x0f, 0xe0, 0x00, 0x38, 0x00, 0x0e,
0x80, 0x03, 0x00, 0xc0, 0xff, 0x07, 0x00, 0xfc, 0x7f, 0x00, 0xc0, 0xaa,
0x06, 0x00, 0xfc, 0x7f, 0x00, 0x40, 0x55, 0x05, 0x00, 0x5c, 0x75, 0x00,
0xc0, 0xaa, 0x06, 0x00, 0xac, 0x6a, 0x00, 0x40, 0x55, 0x05, 0x00, 0x5c,
0x75, 0x00, 0xc0, 0xaa, 0x06, 0x00, 0xac, 0x6a, 0x00, 0x40, 0x55, 0x05,
0x00, 0x5c, 0x75, 0x00, 0xc0, 0xaa, 0x06, 0x00, 0xac, 0x6a, 0x00, 0x40,
0x55, 0x05, 0x00, 0x5c, 0x75, 0x00, 0xc0, 0xaa, 0x06, 0x00, 0xac, 0x6a,
0x00, 0x40, 0x55, 0x05, 0x00, 0x5c, 0x75, 0x00, 0xc0, 0xaa, 0x06, 0x00,
0xfc, 0x7f, 0x00, 0xc0, 0xff, 0x07, 0x00, 0xfc, 0x7f};

View File

@ -1,6 +0,0 @@
#define check_mark_width 14
#define check_mark_height 14
static char check_mark_bits[] = {
0x00, 0x00, 0x00, 0x08, 0x00, 0x08, 0x00, 0x0c, 0x00, 0x04, 0x00, 0x06,
0x30, 0x02, 0x60, 0x03, 0x40, 0x01, 0xc0, 0x01, 0x80, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00};

View File

@ -1,4 +0,0 @@
#define menu_arrow_width 7
#define menu_arrow_height 11
static char menu_arrow_bits[] = {
0x00, 0x02, 0x06, 0x0e, 0x1e, 0x3e, 0x1e, 0x0e, 0x06, 0x02, 0x00};

38
include/bitmaps/oic_bang Normal file
View File

@ -0,0 +1,38 @@
/* XPM */
static char * oic_bang[] = {
"32 32 3 1",
" s None c None",
". s black c black",
"X s yellow c yellow",
" ........ ",
" ...XXXXXXXX... ",
" ..XXXXXXXXXXXXXX.. ",
" .XXXXX........XXXXX. ",
" .XXXXXX........XXXXXX. ",
" .XXXXXXX........XXXXXXX. ",
" .XXXXXXXX........XXXXXXXX. ",
" .XXXXXXXXX........XXXXXXXXX. ",
" .XXXXXXXXX........XXXXXXXXX. ",
" .XXXXXXXXXX........XXXXXXXXXX. ",
" .XXXXXXXXXX........XXXXXXXXXX. ",
" .XXXXXXXXXX........XXXXXXXXXX. ",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
".XXXXXXXXXXX........XXXXXXXXXXX.",
" .XXXXXXXXXX........XXXXXXXXXX. ",
" .XXXXXXXXXXXXXXXXXXXXXXXXXXXX. ",
" .XXXXXXXXXXXXX..XXXXXXXXXXXXX. ",
" .XXXXXXXXXX......XXXXXXXXXX. ",
" .XXXXXXXXXX......XXXXXXXXXX. ",
" .XXXXXXXX........XXXXXXXX. ",
" .XXXXXXX........XXXXXXX. ",
" .XXXXXXX......XXXXXXX. ",
" .XXXXXX......XXXXXX. ",
" ..XXXXXX..XXXXXX.. ",
" ...XXXXXXXX... ",
" ........ "};

38
include/bitmaps/oic_hand Normal file
View File

@ -0,0 +1,38 @@
/* XPM */
static char * oic_hand[] = {
"32 32 3 1",
" s None c None",
". s red c red",
"X s white c white",
" ",
" .............. ",
" ................ ",
" .................. ",
" .................... ",
" ...................... ",
" ........................ ",
" .......................... ",
" ............................ ",
" .............................. ",
" ......XX..XXXXX..XX...XXX..... ",
" .....X..X...X...X..X..X..X.... ",
" .....X..X...X...X..X..X..X.... ",
" .....X......X...X..X..X..X.... ",
" .....X......X...X..X..X..X.... ",
" ......XX....X...X..X..XXX..... ",
" ........X...X...X..X..X....... ",
" ........X...X...X..X..X....... ",
" .....X..X...X...X..X..X....... ",
" .....X..X...X...X..X..X....... ",
" .....X..X...X...X..X..X....... ",
" ......XX....X....XX...X....... ",
" .............................. ",
" ............................ ",
" .......................... ",
" ........................ ",
" ...................... ",
" .................... ",
" .................. ",
" ................ ",
" .............. ",
" "};

39
include/bitmaps/oic_note Normal file
View File

@ -0,0 +1,39 @@
/* XPM */
static char * oic_note[] = {
"32 32 4 1",
" s None c None",
". s black c black",
"X s blue c blue",
"o s white c white",
" ........ ",
" ...XXXXXXXX... ",
" ..XXXXXooooXXXXX.. ",
" .XXXXXXooooooXXXXXX. ",
" .XXXXXXooooooooXXXXXX. ",
" .XXXXXXXooooooooXXXXXXX. ",
" .XXXXXXXXooooooooXXXXXXXX. ",
" .XXXXXXXXXXooooooXXXXXXXXXX. ",
" .XXXXXXXXXXXooooXXXXXXXXXXX. ",
" .XXXXXXXXXXXXXXXXXXXXXXXXXXXX. ",
" .XXXXXXXXXXXXXXXXXXXXXXXXXXXX. ",
" .XXXXXXXXXoooooooooXXXXXXXXXX. ",
".XXXXXXXXXXoooooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
" .XXXXXXXXXXXXooooooXXXXXXXXXX. ",
" .XXXXXXXXXXXXooooooXXXXXXXXXX. ",
" .XXXXXXXXXXXXooooooXXXXXXXXXX. ",
" .XXXXXXXXXXXooooooXXXXXXXXX. ",
" .XXXXXXXXXXXooooooXXXXXXXXX. ",
" .XXXXXXXooooooooooooXXXXX. ",
" .XXXXXXooooooooooooXXXX. ",
" .XXXXXooooooooooooXXX. ",
" .XXXXXXXXXXXXXXXXXX. ",
" ..XXXXXXXXXXXXXX.. ",
" ...XXXXXXXX... ",
" ........ "};

39
include/bitmaps/oic_ques Normal file
View File

@ -0,0 +1,39 @@
/* XPM */
static char * oic_ques[] = {
"32 32 4 1",
" s None c None",
". s black c black",
"X s green c green",
"o s white c white",
" ........ ",
" ...XXXXXXXX... ",
" ..XXXXXXXXXXXXXX.. ",
" .XXXXXXooooooXXXXXX. ",
" .XXXXXXoooooooooXXXXX. ",
" .XXXXXXoooooooooooXXXXX. ",
" .XXXXXXXoooooooooooXXXXXX. ",
" .XXXXXXXoooooooooooooXXXXXX. ",
" .XXXXXXXoooooooooooooXXXXXX. ",
" .XXXXXXXXoooooXXooooooXXXXXXX. ",
" .XXXXXXXXoooooXXooooooXXXXXXX. ",
" .XXXXXXXXoooooXXooooooXXXXXXX. ",
".XXXXXXXXXXXXXXXooooooXXXXXXXXX.",
".XXXXXXXXXXXXXXXooooooXXXXXXXXX.",
".XXXXXXXXXXXXXXooooooXXXXXXXXXX.",
".XXXXXXXXXXXXXXooooooXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXXooooooXXXXXXXXXXX.",
".XXXXXXXXXXXXooooooXXXXXXXXXXXX.",
".XXXXXXXXXXXXooooooXXXXXXXXXXXX.",
" .XXXXXXXXXXXooooooXXXXXXXXXXX. ",
" .XXXXXXXXXXXXXXXXXXXXXXXXXXXX. ",
" .XXXXXXXXXXXXXooXXXXXXXXXXXXX. ",
" .XXXXXXXXXXooooooXXXXXXXXXX. ",
" .XXXXXXXXXXooooooXXXXXXXXXX. ",
" .XXXXXXXXooooooooXXXXXXXX. ",
" .XXXXXXXooooooooXXXXXXX. ",
" .XXXXXXXooooooXXXXXXX. ",
" .XXXXXXooooooXXXXXX. ",
" ..XXXXXXooXXXXXX.. ",
" ...XXXXXXXX... ",
" ........ "};

View File

@ -0,0 +1,37 @@
/* XPM */
static char * oic_sample[] = {
"32 32 2 1",
" s black c black",
". s white c white",
" ",
" ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ............................ ",
" ",
" ",
" "};

File diff suppressed because it is too large Load Diff

View File

@ -91,6 +91,7 @@ struct dll_name_table_entry_s
struct dll_table_entry_s *dll_table;
int dll_table_length;
int dll_number;
int dll_is_used; /* use MS provided if set to zero */
};
extern struct dll_table_entry_s KERNEL_table[];
@ -108,6 +109,13 @@ extern struct dll_table_entry_s SYSTEM_table[];
extern struct dll_table_entry_s TOOLHELP_table[];
extern struct dll_table_entry_s MOUSE_table[];
extern struct dll_table_entry_s COMMDLG_table[];
extern struct dll_table_entry_s OLE2_table[];
extern struct dll_table_entry_s OLE2CONV_table[];
extern struct dll_table_entry_s OLE2DISP_table[];
extern struct dll_table_entry_s OLE2NLS_table[];
extern struct dll_table_entry_s OLE2PROX_table[];
extern struct dll_table_entry_s OLECLI_table[];
extern struct dll_table_entry_s OLESVR_table[];
extern unsigned short KERNEL_offsets[];
@ -125,6 +133,13 @@ extern unsigned short SYSTEM_offsets[];
extern unsigned short TOOLHELP_offsets[];
extern unsigned short MOUSE_offsets[];
extern unsigned short COMMDLG_offsets[];
extern unsigned short OLE2_offsets[];
extern unsigned short OLE2CONV_offsets[];
extern unsigned short OLE2DISP_offsets[];
extern unsigned short OLE2NLS_offsets[];
extern unsigned short OLE2PROX_offsets[];
extern unsigned short OLECLI_offsets[];
extern unsigned short OLESVR_offsets[];
extern unsigned char KERNEL_types[];
@ -142,9 +157,15 @@ extern unsigned char SYSTEM_types[];
extern unsigned char TOOLHELP_types[];
extern unsigned char MOUSE_types[];
extern unsigned char COMMDLG_types[];
extern unsigned char OLE2_types[];
extern unsigned char OLE2CONV_types[];
extern unsigned char OLE2DISP_types[];
extern unsigned char OLE2NLS_types[];
extern unsigned char OLE2PROX_types[];
extern unsigned char OLECLI_types[];
extern unsigned char OLESVR_types[];
#define N_BUILTINS 15
#define N_BUILTINS 22
#endif /* DLLS_H */

85
include/ole.h Normal file
View File

@ -0,0 +1,85 @@
/*
* ole.h - Declarations for OLESVR and OLECLI
*/
typedef enum
{
OLE_OK,
OLE_WAIT_FOR_RELEASE,
OLE_BUSY,
OLE_ERROR_PROTECT_ONLY,
OLE_ERROR_MEMORY,
OLE_ERROR_STREAM,
OLE_ERROR_STATIC,
OLE_ERROR_BLANK,
OLE_ERROR_DRAW,
OLE_ERROR_METAFILE,
OLE_ERROR_ABORT,
OLE_ERROR_CLIPBOARD,
OLE_ERROR_FORMAT,
OLE_ERROR_OBJECT,
OLE_ERROR_OPTION,
OLE_ERROR_PROTOCOL,
OLE_ERROR_ADDRESS,
OLE_ERROR_NOT_EQUAL,
OLE_ERROR_HANDLE,
OLE_ERROR_GENERIC,
OLE_ERROR_CLASS,
OLE_ERROR_SYNTAX,
OLE_ERROR_DATATYPE,
OLE_ERROR_PALETTE,
OLE_ERROR_NOT_LINK,
OLE_ERROR_NOT_EMPTY,
OLE_ERROR_SIZE,
OLE_ERROR_DRIVE,
OLE_ERROR_NETWORK,
OLE_ERROR_NAME,
OLE_ERROR_TEMPLATE,
OLE_ERROR_NEW,
OLE_ERROR_EDIT,
OLE_ERROR_OPEN,
OLE_ERROR_NOT_OPEN,
OLE_ERROR_LAUNCH,
OLE_ERROR_COMM,
OLE_ERROR_TERMINATE,
OLE_ERROR_COMMAND,
OLE_ERROR_SHOW,
OLE_ERROR_DOVERB,
OLE_ERROR_ADVISE_NATIVE,
OLE_ERROR_ADVISE_PICT,
OLE_ERROR_ADVISE_RENAME,
OLE_ERROR_POKE_NATIVE,
OLE_ERROR_REQUEST_NATIVE,
OLE_ERROR_REQUEST_PICT,
OLE_ERROR_SERVER_BLOCKED,
OLE_ERROR_REGISTRATION,
OLE_ERROR_ALREADY_REGISTERED,
OLE_ERROR_TASK,
OLE_ERROR_OUTOFDATE,
OLE_ERROR_CANT_UPDATE_CLIENT,
OLE_ERROR_UPDATE,
OLE_ERROR_SETDATA_FORMAT,
OLE_ERROR_STATIC_FROM_OTHER_OS,
OLE_WARN_DELETE_DATA = 1000
} OLESTATUS;
typedef enum{
OLE_SERVER_MULTI,
OLE_SERVER_SINGLE
}OLE_SERVER_USE;
typedef LONG LHSERVER;
typedef LONG LHSERVERDOC;
typedef LONG LHCLIENTDOC;
typedef struct _OLESERVER* LPOLESERVER;
typedef struct _OLESERVERDOC* LPOLESERVERDOC;
OLESTATUS WINAPI OleRegisterServer(LPCSTR,LPOLESERVER,LHSERVER FAR*,HINSTANCE,OLE_SERVER_USE);
OLESTATUS WINAPI OleUnblockServer(LHSERVER,BOOL FAR*);
OLESTATUS WINAPI OleRegisterServerDoc(LHSERVER,LPCSTR,LPOLESERVERDOC,LHSERVERDOC FAR*);
OLESTATUS WINAPI OleRegisterClientDoc(LPCSTR,LPCSTR,LONG,LHCLIENTDOC FAR*);
OLESTATUS WINAPI OleRenameClientDoc(LHCLIENTDOC,LPCSTR);
OLESTATUS WINAPI OleRevokeServerDoc(LHSERVERDOC);
OLESTATUS WINAPI OleRevokeClientDoc(LHCLIENTDOC);
OLESTATUS WINAPI OleRevokeServer(LHSERVER);

View File

@ -110,6 +110,7 @@
#undef DEBUG_KEYBOARD
#undef DEBUG_LDT
#undef DEBUG_LISTBOX
#undef DEBUG_MALLOC
#undef DEBUG_MCI
#undef DEBUG_MCIANIM
#undef DEBUG_MCIWAVE
@ -125,6 +126,7 @@
#undef DEBUG_MSG
#undef DEBUG_MSGBOX
#undef DEBUG_NONCLIENT
#undef DEBUG_OLE
#undef DEBUG_PALETTE
#undef DEBUG_PROFILE
#undef DEBUG_PROP
@ -180,6 +182,7 @@
#define DEBUG_KEYBOARD
#define DEBUG_LDT
#define DEBUG_LISTBOX
#define DEBUG_MALLOC
#define DEBUG_MCI
#define DEBUG_MCIANIM
#define DEBUG_MCIWAVE
@ -195,6 +198,7 @@
#define DEBUG_MSG
#define DEBUG_MSGBOX
#define DEBUG_NONCLIENT
#define DEBUG_OLE
#define DEBUG_PALETTE
#define DEBUG_PROFILE
#define DEBUG_PROP

View File

@ -280,6 +280,11 @@ HANDLE GetModuleHandle(LPSTR lpModuleName)
/* dprintf_module(stddeb,"GetModuleHandle // searching in builtin libraries\n");*/
for (i = 0; i < N_BUILTINS; i++) {
if (dll_builtin_table[i].dll_name == NULL) break;
if (!dll_builtin_table[i].dll_is_used){
dprintf_module(stddeb,"Skipping builtin %s\n",
dll_builtin_table[i].dll_name);
continue;
}
if (((int) lpModuleName & 0xffff0000) == 0) {
if (0xFF00 + i == (int) lpModuleName) {
dprintf_module(stddeb,"GetModuleHandle('%s') return %04X \n",
@ -576,16 +581,22 @@ BOOL ModuleNext(MODULEENTRY *lpModule)
dprintf_module(stddeb,"ModuleNext(%08X)\n", (int) lpModule);
if (IS_BUILTIN_DLL(lpModule->hModule)) {
if (IS_BUILTIN_DLL(lpModule->hModule))
{
int builtin_no=lpModule->hModule & 0xff;
do{
/* last built-in ? */
if ((lpModule->hModule & 0xff) == (N_BUILTINS - 1) ) {
if (builtin_no == (N_BUILTINS - 1) ) {
if (wine_files) {
FillModStructLoaded(lpModule, wine_files);
return TRUE;
} else
return FALSE;
}
FillModStructBuiltIn(lpModule, &dll_builtin_table[(lpModule->hModule & 0xff)+1]);
builtin_no++;
}while(!dll_builtin_table[builtin_no].dll_is_used);
FillModStructBuiltIn(lpModule, &dll_builtin_table[builtin_no]);
return TRUE;
}
w = GetFileInfo(lpModule->hModule);

View File

@ -253,6 +253,9 @@ int NE_FixupSegment(struct w_files *wpnt, int segment_num)
switch (rep->address_type)
{
case NE_RADDR_LOWBYTE:
dprintf_fixup(stddeb,"Unhandled address type NE_RADDR_LOWBYTE\n");
return -1;
case NE_RADDR_OFFSET16:
do {
dprintf_fixup(stddeb," %04x:%04x:%04x OFFSET16\n",

View File

@ -22,7 +22,6 @@ static char Copyright[] = "Copyright Robert J. Amstadt, 1993";
#include "library.h"
#include "stddebug.h"
#include "debug.h"
#include "../rc/sysresbm.h"
#define MIN(a,b) ((a) < (b) ? (a) : (b))
@ -30,7 +29,6 @@ RESOURCE *Top = NULL;
extern int NE_FindResource(HANDLE, LPSTR, LPSTR, RESOURCE *);
extern int PE_FindResource(HANDLE, LPSTR, LPSTR, RESOURCE *);
extern HBITMAP OBM_LoadOEMBitmap( WORD id ); /* objects/oembitmap.c */
#define PrintId(name) \
if (HIWORD((DWORD)name)) \
@ -54,9 +52,6 @@ HANDLE FindResource(HANDLE instance, LPSTR name, LPSTR type)
printf(")\n");
}
if (instance == (HANDLE)NULL)
instance = hSysRes;
/* FIXME: did we already find this one ? */
if ((rh = GlobalAlloc(GMEM_MOVEABLE, sizeof(RESOURCE))) == 0)
@ -111,9 +106,6 @@ HANDLE AllocResource(HANDLE instance, HANDLE hResInfo, DWORD dwSize)
dprintf_resource(stddeb, "AllocResource(%04X, %04X, %08X);\n",
instance, hResInfo, (int) dwSize);
if (instance == (HANDLE)NULL)
instance = hSysRes;
if ((r = (RESOURCE *)GlobalLock(hResInfo)) == NULL)
return 0;
@ -140,9 +132,6 @@ int AccessResource(HANDLE instance, HANDLE hResInfo)
dprintf_resource(stddeb, "AccessResource(%04X, %04X);\n",
instance, hResInfo);
if (instance == (HANDLE)NULL)
instance = hSysRes;
if ((r = (RESOURCE *)GlobalLock(hResInfo)) == NULL)
return -1;
@ -164,9 +153,6 @@ WORD SizeofResource(HANDLE instance, HANDLE hResInfo)
dprintf_resource(stddeb, "SizeofResource(%04X, %04X);\n",
instance, hResInfo);
if (instance == (HANDLE)NULL)
instance = hSysRes;
if ((r = (RESOURCE *)GlobalLock(hResInfo)) == NULL)
return 0;
@ -188,9 +174,6 @@ HANDLE LoadResource(HANDLE instance, HANDLE hResInfo)
dprintf_resource(stddeb, "LoadResource(%04X, %04X);\n", instance, hResInfo);
if (instance == (HANDLE)NULL)
instance = hSysRes;
if ((r = (RESOURCE *)GlobalLock(hResInfo)) == NULL)
return 0;
@ -324,9 +307,6 @@ RSC_LoadResource(int instance, LPSTR rsc_name, LPSTR type, int *image_size_ret)
HANDLE hResInfo;
RESOURCE *r;
if (instance == (HANDLE)NULL)
instance = hSysRes;
dprintf_resource(stddeb, "RSC_LoadResource: instance = %04x, name = %08x, type = %08x\n",
instance, (int) rsc_name, (int) type);
@ -364,6 +344,12 @@ HICON LoadIcon(HANDLE instance, LPSTR icon_name)
printf(")\n");
}
if (!instance)
{
if (HIWORD((int)icon_name)) return 0; /* FIXME: should handle '#xxx' */
return OBM_LoadIcon( LOWORD((int)icon_name) );
}
if (!(hdc = GetDC(GetDesktopWindow()))) return 0;
rsc_mem = RSC_LoadResource(instance, icon_name, (LPSTR) NE_RSCTYPE_GROUP_ICON,
&image_size);
@ -711,24 +697,11 @@ LoadBitmap(HANDLE instance, LPSTR bmp_name)
printf(")\n");
}
if (!instance) {
struct ResourceTable *it;
hbitmap = OBM_LoadOEMBitmap(((int) bmp_name) & 0xffff);
if (hbitmap)
return hbitmap;
/* Load from sysresbm */
dprintf_resource(stddeb,"Searching for %d\n", (int) bmp_name);
for(it=sysresbmTable;it->value;it++){
if(it->type==NE_RSCTYPE_BITMAP)
if((((int)bmp_name & 0xFFFF0000) == 0))
{if(it->id==(int)bmp_name)break;}
else if(!strcmp(it->name,bmp_name))break;
if (!instance)
{
if (HIWORD((int)bmp_name)) return 0; /* FIXME: should handle '#xxx' */
return OBM_LoadBitmap( LOWORD((int)bmp_name) );
}
if(!it->value)return 0;
dprintf_resource(stddeb,"Found %s\n",it->name);
lp=(long *)it->value;
rsc_mem=(HANDLE)NULL;
} else { /* Load from file - indent this code properly later */
rsc_mem = RSC_LoadResource(instance, bmp_name, (LPSTR) NE_RSCTYPE_BITMAP,
&image_size);
@ -744,7 +717,6 @@ LoadBitmap(HANDLE instance, LPSTR bmp_name)
GlobalFree(rsc_mem);
return 0;
}
} /* Load from file */
if (!(hdc = GetDC(0))) lp = NULL;
size = CONV_LONG (*lp);
if (size == sizeof(BITMAPCOREHEADER)){

View File

@ -634,6 +634,77 @@ GetNextSegment(unsigned int flags, unsigned int limit)
return CreateNewSegments(0, 0, limit, 1);
}
/**********************************************************************
* Check whether pseudo-functions like __0040H for direct memory
* access are referenced and return 1 if so.
* FIXME: Reading and writing to the returned selectors has no effect
* (e.g. reading from the Bios data segment (esp. clock!) )
*/
unsigned int GetMemoryReference(char *dll_name, char *function, int *sel,
int *addr)
{
static HANDLE memory_handles[ 10 ] = { 0,0,0,0,0,0,0,0,0,0 };
static char *memory_names[ 10 ] = { "segment 0xA000",
"segment 0xB000",
"segment 0xB800",
"Bios-Rom",
"segment 0xD000",
"segment 0x0000",
"segment 0xE000",
"segment 0xF000",
"segment 0xC000",
"Bios data segment" };
short nr;
if( strcasecmp( dll_name, "KERNEL" ) )
return 0;
if( HIWORD( function ) ) {
if( ( *function != '_' ) || ( *(function+1) != '_' ) )
return 0;
if( !strcasecmp( function, "__A000H" ) ) nr = 0;
else if( !strcasecmp( function, "__B000H" ) ) nr = 1;
else if( !strcasecmp( function, "__B800H" ) ) nr = 2;
else if( !strcasecmp( function, "__ROMBIOS" ) ) nr = 3;
else if( !strcasecmp( function, "__D000H" ) ) nr = 4;
else if( !strcasecmp( function, "__0000H" ) ) nr = 5;
else if( !strcasecmp( function, "__E000H" ) ) nr = 6;
else if( !strcasecmp( function, "__F000H" ) ) nr = 7;
else if( !strcasecmp( function, "__C000H" ) ) nr = 8;
else if( !strcasecmp( function, "__0040H" ) ) nr = 9;
else
return 0;
}
else {
switch( LOWORD( function ) ) {
case 174: nr = 0; break;
case 181: nr = 1; break;
case 182: nr = 2; break;
case 173: nr = 3; break;
case 179: nr = 4; break;
case 183: nr = 5; break;
case 190: nr = 6; break;
case 194: nr = 7; break;
case 195: nr = 8; break;
case 193: nr = 9; break;
default: return 0;
}
}
if( !memory_handles[ nr ] ) {
fprintf( stderr, "Warning: Direct access to %s!\n", memory_names[ nr ] );
memory_handles[ nr ] = GlobalAlloc( GMEM_FIXED, 65535 );
}
*sel = memory_handles[ nr ];
*addr = MAKELONG(*sel,*sel);
return 1;
}
/**********************************************************************
* GetEntryPointFromOrdinal
*/
@ -652,6 +723,9 @@ unsigned int GetEntryDLLName(char * dll_name, char * function, int * sel,
char * cpnt;
int ordinal, j, len;
if( GetMemoryReference( dll_name, function, sel, addr ) )
return 0;
dll_table = FindDLLTable(dll_name);
if(dll_table) {
@ -693,6 +767,9 @@ unsigned int GetEntryDLLOrdinal(char * dll_name, int ordinal, int * sel,
struct w_files * wpnt;
int j;
if( GetMemoryReference( dll_name, (char*)ordinal, sel, addr ) )
return 0;
dll_table = FindDLLTable(dll_name);
if(dll_table) {

View File

@ -240,10 +240,13 @@ void init_wine_signals(void)
#endif
#if defined(__NetBSD__) || defined(__FreeBSD__)
sigset_t sig_mask;
#if defined(BSD4_4) && !defined (__FreeBSD__)
struct sigaltstack ss;
#if !defined (__FreeBSD__)
if ((ss.ss_base = malloc(MINSIGSTKSZ)) == NULL) {
#else
if ((ss.ss_sp = malloc(MINSIGSTKSZ)) == NULL) {
#endif
fprintf(stderr, "Unable to allocate signal stack (%d bytes)\n",
MINSIGSTKSZ);
exit(1);
@ -254,16 +257,6 @@ void init_wine_signals(void)
perror("sigstack");
exit(1);
}
#else
struct sigstack ss;
ss.ss_sp = (char *) (((unsigned int)(cstack) + sizeof(cstack) - 4) & ~3);
ss.ss_onstack = 0;
if (sigstack(&ss, NULL) < 0) {
perror("sigstack");
exit(1);
}
#endif
sigemptyset(&sig_mask);
segv_act.sa_handler = (void (*)) win_fault;
segv_act.sa_flags = SA_ONSTACK;

View File

@ -15,6 +15,8 @@ SRCS = \
keyboard.c \
lstr.c \
main.c \
olecli.c \
olesvr.c \
message.c \
network.c \
profile.c \

View File

@ -414,6 +414,7 @@ char *DOS_GetUnixFileName(char *dosfilename)
/* a:\windows\system.ini => /dos/windows/system.ini */
static char temp[256];
static char dostemp[256];
int drive;
if (dosfilename[1] == ':')
@ -427,14 +428,17 @@ char *DOS_GetUnixFileName(char *dosfilename)
} else
drive = CurrentDrive;
/* Consider dosfilename const */
strcpy(dostemp,dosfilename);
/* Expand the filename to it's full path if it doesn't
* start from the root.
*/
DOS_ExpandToFullPath(dosfilename, drive);
DOS_ExpandToFullPath(dostemp, drive);
strcpy(temp, DosDrives[drive].rootdir);
strcat(temp, DosDrives[drive].cwd);
GetUnixDirName(temp + strlen(DosDrives[drive].rootdir), dosfilename);
GetUnixDirName(temp + strlen(DosDrives[drive].rootdir), dostemp);
dprintf_dosfs(stddeb,"GetUnixFileName: %s => %s\n", dosfilename, temp);
return(temp);

View File

@ -10,6 +10,9 @@ static char Copyright[] = "Copyright Alexandre Julliard, 1994";
#include <string.h>
#include <ctype.h>
#include <locale.h>
#ifdef MALLOC_DEBUGGING
#include <malloc.h>
#endif
#include <X11/Xlib.h>
#include <X11/Xresource.h>
#include <X11/Xutil.h>
@ -26,6 +29,7 @@ static char Copyright[] = "Copyright Alexandre Julliard, 1994";
#include "prototypes.h"
#include "texts.h"
#include "selectors.h" /* for InitSelectors prototype */
#include "library.h"
#define DEBUG_DEFINE_VARIABLES
#include "stddebug.h"
#include "debug.h"
@ -86,7 +90,8 @@ static XrmOptionDescRec optionsTable[] =
{ "-synchronous", ".synchronous", XrmoptionNoArg, (caddr_t)"on" },
{ "-spy", ".spy", XrmoptionSepArg, (caddr_t)NULL },
{ "-debug", ".debug", XrmoptionNoArg, (caddr_t)"on" },
{ "-debugmsg", ".debugmsg", XrmoptionSepArg, (caddr_t)NULL }
{ "-debugmsg", ".debugmsg", XrmoptionSepArg, (caddr_t)NULL },
{ "-dll", ".dll", XrmoptionSepArg, (caddr_t)NULL }
};
#define NB_OPTIONS (sizeof(optionsTable) / sizeof(optionsTable[0]))
@ -106,7 +111,9 @@ static XrmOptionDescRec optionsTable[] =
" -backingstore Turn on backing store\n" \
" -spy file Turn on message spying to the specified file\n" \
" -relaydbg Obsolete. Use -debugmsg +relay instead\n" \
" -debugmsg name Turn debugging-messages on or off\n"
" -debugmsg name Turn debugging-messages on or off\n" \
" -dll name Enable or disable built-in DLLs\n"
/***********************************************************************
@ -263,6 +270,43 @@ BOOL ParseDebugOptions(char *options)
#endif
/***********************************************************************
* MAIN_ParseDLLOptions
*
* Set runtime DLL usage flags
*/
static BOOL MAIN_ParseDLLOptions(char *options)
{
int l;
int i;
if (strlen(options)<3)
return FALSE;
do
{
if ((*options!='+')&&(*options!='-'))
return FALSE;
if (strchr(options,','))
l=strchr(options,',')-options;
else l=strlen(options);
for (i=0;i<N_BUILTINS;i++)
if (!strncasecmp(options+1,dll_builtin_table[i].dll_name,l-1))
{
dll_builtin_table[i].dll_is_used=(*options=='+');
break;
}
if (i==N_BUILTINS)
return FALSE;
options+=l;
}
while((*options==',')&&(*(++options)));
if (*options)
return FALSE;
else
return TRUE;
}
/***********************************************************************
* MAIN_ParseOptions
*
@ -344,6 +388,20 @@ static void MAIN_ParseOptions( int *argc, char *argv[] )
#endif
}
if(MAIN_GetResource( db, ".dll", &value))
if(MAIN_ParseDLLOptions((char*)value.addr)==FALSE)
{
int i;
fprintf(stderr,"%s: Syntax: -dll +xxx,... or -dll -xxx,...\n",argv[0]);
fprintf(stderr,"Example: -dll -ole2 Do not use emulated OLE2.DLL\n");
fprintf(stderr,"Available DLLs\n");
for(i=0;i<N_BUILTINS;i++)
fprintf(stderr,"%-9s%c",dll_builtin_table[i].dll_name,
(((i+2)%8==0)?'\n':' '));
fprintf(stderr,"\n\n");
exit(1);
}
/* MAIN_GetAllButtonTexts(db); */
}
@ -444,6 +502,12 @@ static void MAIN_RestoreSetup(void)
KBBellPitch | KBBellDuration | KBAutoRepeatMode, &keyboard_value);
}
static void malloc_error()
{
fprintf(stderr,"malloc is not feeling well. Good bye\n");
exit(1);
}
static void called_at_exit(void)
{
Comm_DeInit();
@ -468,6 +532,22 @@ int main( int argc, char *argv[] )
MAIN_ParseOptions( &argc, argv );
#ifdef MALLOC_DEBUGGING
if(debugging_malloc)
{
char *trace=getenv("MALLOC_TRACE");
if(!trace)
{
dprintf_malloc(stddeb,"MALLOC_TRACE not set. No trace generated\n");
}else
{
dprintf_malloc(stddeb,"malloc trace goes to %s\n",trace);
mtrace();
}
mcheck(malloc_error);
}
#endif
screen = DefaultScreenOfDisplay( display );
screenWidth = WidthOfScreen( screen );
screenHeight = HeightOfScreen( screen );

View File

@ -28,7 +28,16 @@ static char Copyright[] = "Copyright Martin Ayotte, 1993";
* Defaults for button-texts
*/
ButtonTexts ButtonText = {
ButtonTexts ButtonText = { /* FIXME: Norwegian Translation missing */
#if #LANG(De)
"&Ja", 'J',
"&Nein", 'N',
"&Ok", 'O',
"&Abbruch",'A',
"&Abbruch",'A',
"&Wiederholen", 'W',
"&Ignorieren", 'I'
#else
"&Yes", 'Y',
"&No", 'N',
"&Ok", 'O',
@ -36,6 +45,7 @@ ButtonTexts ButtonText = {
"&Abort", 'A',
"&Retry", 'R',
"&Ignore", 'I'
#endif
};
extern HBITMAP hUpArrow;

47
misc/olecli.c Normal file
View File

@ -0,0 +1,47 @@
/*
* OLECLI library
*
* Copyright 1995 Martin von Loewis
*/
/* At the moment, these are only empty stubs.
*/
#include "windows.h"
#include "ole.h"
#include "stddebug.h"
#include "debug.h"
extern LONG OLE_current_handle;
/***********************************************************************
* OleRegisterClientDoc
*/
OLESTATUS WINAPI OleRegisterClientDoc(
LPCSTR classname,
LPCSTR docname,
LONG reserved,
LHCLIENTDOC FAR *hRet)
{
dprintf_ole(stdnimp,"OleRegisterClientDoc:%s %s\n",classname,docname);
*hRet=++OLE_current_handle;
return OLE_OK;
}
/***********************************************************************
* OleRenameClientDoc
*/
OLESTATUS WINAPI OleRenameClientDoc(LHCLIENTDOC hDoc, LPCSTR newName)
{
dprintf_ole(stdnimp,"OleRenameClientDoc: %d %s\n",hDoc, newName);
return OLE_OK;
}
/***********************************************************************
* OleRevokeClientDoc
*/
OLESTATUS WINAPI OleRevokeClientDoc(LHCLIENTDOC hServerDoc)
{
dprintf_ole(stdnimp,"OleRevokeClientDoc:%d\n",hServerDoc);
return OLE_OK;
}

83
misc/olesvr.c Normal file
View File

@ -0,0 +1,83 @@
/*
* OLESVR library
*
* Copyright 1995 Martin von Loewis
*/
/* At the moment, these are only empty stubs.
*/
#include "windows.h"
#include "ole.h"
#include "stddebug.h"
#include "debug.h"
LONG OLE_current_handle;
/***********************************************************************
* OleRegisterServer
*/
OLESTATUS WINAPI OleRegisterServer(
LPCSTR name,
LPOLESERVER serverStruct,
LHSERVER FAR *hRet,
HINSTANCE hServer,
OLE_SERVER_USE use)
{
dprintf_ole(stdnimp,"OleRegisterServer:%s\n",name);
*hRet=++OLE_current_handle;
/* return OLE_ERROR_MEMORY, OLE_ERROR_PROTECT_ONLY if you want it fail*/
return OLE_OK;
}
/***********************************************************************
* OleBlockServer
*/
OLESTATUS WINAPI OleBlockServer(LHSERVER hServer)
{
fprintf(stdnimp,"OleBlockServer:%d\n",hServer);
return OLE_OK;
}
/***********************************************************************
* OleUnblockServer
*/
OLESTATUS WINAPI OleUnblockServer(LHSERVER hServer, BOOL FAR *block)
{
fprintf(stdnimp,"OleUnblockServer:%d\n",hServer);
/* no more blocked messages :) */
*block=FALSE;
return OLE_OK;
}
/***********************************************************************
* OleRegisterServerDoc
*/
OLESTATUS WINAPI OleRegisterServerDoc(
LHSERVER hServer,
LPCSTR docname,
LPOLESERVERDOC document,
LHSERVERDOC FAR *hRet)
{
dprintf_ole(stdnimp,"OleRegisterServerDoc:%d,%s\n", hServer, docname);
*hRet=++OLE_current_handle;
return OLE_OK;
}
/***********************************************************************
* OleRevokeServerDoc
*/
OLESTATUS WINAPI OleRevokeServerDoc(LHSERVERDOC hServerDoc)
{
dprintf_ole(stdnimp,"OleRevokeServerDoc:%d\n",hServerDoc);
return OLE_OK;
}
/***********************************************************************
* OleRevokeServer
*/
OLESTATUS WINAPI OleRevokeServer(LHSERVER hServer)
{
dprintf_ole(stdnimp,"OleRevokeServer:%d\n",hServer);
return OLE_OK;
}

View File

@ -665,19 +665,32 @@ BOOL DrawIcon(HDC hDC, short x, short y, HICON hIcon)
BITMAP bm;
HBITMAP hBitTemp;
HDC hMemDC;
COLORREF oldFg, oldBg;
oldFg = SetTextColor( hDC, RGB(0,0,0) );
oldBg = SetBkColor( hDC, RGB(255,255,255) );
dprintf_icon(stddeb,"DrawIcon(%04X, %d, %d, %04X) \n", hDC, x, y, hIcon);
if (hIcon == (HICON)NULL) return FALSE;
lpico = (ICONALLOC *)GlobalLock(hIcon);
GetObject(lpico->hBitmap, sizeof(BITMAP), (LPSTR)&bm);
hMemDC = CreateCompatibleDC(hDC);
if (lpico->hBitMask)
{
hBitTemp = SelectObject(hMemDC, lpico->hBitMask);
BitBlt(hDC, x, y, bm.bmWidth, bm.bmHeight, hMemDC, 0, 0, SRCAND);
SelectObject(hMemDC, lpico->hBitmap);
BitBlt(hDC, x, y, bm.bmWidth, bm.bmHeight, hMemDC, 0, 0, SRCINVERT);
}
else /* no mask -> everything is masked; so use SRCCOPY as it's faster */
{
hBitTemp = SelectObject(hMemDC, lpico->hBitmap);
BitBlt(hDC, x, y, bm.bmWidth, bm.bmHeight, hMemDC, 0, 0, SRCCOPY);
}
SelectObject( hMemDC, hBitTemp );
DeleteDC(hMemDC);
GlobalUnlock( hIcon );
SetTextColor( hDC, oldFg );
SetBkColor( hDC, oldBg );
return TRUE;
}

View File

@ -1,62 +1,21 @@
/*
* GDI OEM bitmap objects
*
* Copyright 1994 Alexandre Julliard
* Copyright 1994, 1995 Alexandre Julliard
*
static char Copyright[] = "Copyright Alexandre Julliard, 1994";
*/
*/
#include <stdlib.h>
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#ifdef USE_XPM
#include <X11/xpm.h>
#endif
#include "gdi.h"
#include "bitmap.h"
#include "stddebug.h"
#include "color.h"
#include "icon.h"
#include "stddebug.h"
#include "debug.h"
#define OBM_FIRST OBM_LFARROWI /* First OEM bitmap */
#define OBM_LAST OBM_OLD_CLOSE /* Last OEM bitmap */
#ifdef USE_XPM
#define NB_COLOR_SYMBOLS 5
/* This is the list of the symbolic colors. All the colors used */
/* in the xpm files must be included in this list. If you need */
/* to add new colors, add them just before "black", and add the */
/* color identifier in OBM_Sys_Colors_Symbols below. */
/* Warning: black and white must always be the last 2 colors. */
static XpmColorSymbol OBM_Color_Symbols[NB_COLOR_SYMBOLS+2] =
{
{ "button_face", NULL, 0 }, /* COLOR_BTNFACE */
{ "button_shadow", NULL, 0 }, /* COLOR_BTNSHADOW */
{ "button_highlight", NULL, 0 }, /* COLOR_BTNHIGHLIGHT */
{ "button_text", NULL, 0 }, /* COLOR_BTNTEXT */
{ "window_frame", NULL, 0 }, /* COLOR_WINDOWFRAME */
{ "black", NULL, 0 },
{ "white", NULL, 0 }
};
static const int OBM_Sys_Colors_Symbols[NB_COLOR_SYMBOLS] =
{
COLOR_BTNFACE,
COLOR_BTNSHADOW,
COLOR_BTNHIGHLIGHT,
COLOR_BTNTEXT,
COLOR_WINDOWFRAME
};
/* Don't change this list! */
static XpmColorSymbol OBM_BW_Symbols[2] =
{
{ "white", NULL, 0 },
{ "black", NULL, 1 }
};
/* Include OEM pixmaps */
#include "bitmaps/obm_lfarrowi"
@ -94,6 +53,9 @@ static XpmColorSymbol OBM_BW_Symbols[2] =
#include "bitmaps/obm_size"
#include "bitmaps/obm_old_close"
#define OBM_FIRST OBM_LFARROWI /* First OEM bitmap */
#define OBM_LAST OBM_OLD_CLOSE /* Last OEM bitmap */
static const struct
{
char** data; /* Pointer to bitmap data */
@ -135,142 +97,102 @@ static const struct
{ obm_old_close, FALSE }, /* OBM_OLD_CLOSE */
};
#else /* USE_XPM */
/* Include OEM bitmaps */
#include "bitmaps/check_boxes"
#include "bitmaps/check_mark"
#include "bitmaps/menu_arrow"
/* Include OEM icons */
#include "bitmaps/oic_sample"
#include "bitmaps/oic_hand"
#include "bitmaps/oic_ques"
#include "bitmaps/oic_bang"
#include "bitmaps/oic_note"
#define OIC_FIRST OIC_SAMPLE /* First OEM icon */
#define OIC_LAST OIC_NOTE /* Last OEM icon */
static char **OBM_Icons_Data[OIC_LAST-OIC_FIRST+1] =
{
oic_sample, /* OIC_SAMPLE */
oic_hand, /* OIC_HAND */
oic_ques, /* OIC_QUES */
oic_bang, /* OIC_BANG */
oic_note /* OIC_NOTE */
};
/* All the colors used in the xpm files must be included in this */
/* list, to make sure that the loaded bitmaps only use colors from */
/* the Windows colormap. Note: the PALETTEINDEX() are not really */
/* palette indexes, but system colors that will be converted to */
/* indexes later on. */
static const struct
{
WORD width, height;
char *data;
} OBM_Bitmaps_Data[OBM_LAST-OBM_FIRST+1] =
char * name;
COLORREF color;
} OBM_SymbolicColors[] =
{
{ 0, 0, NULL }, /* OBM_LFARROWI */
{ 0, 0, NULL }, /* OBM_RGARROWI */
{ 0, 0, NULL }, /* OBM_DNARROWI */
{ 0, 0, NULL }, /* OBM_UPARROWI */
{ 0, 0, NULL }, /* OBM_COMBO */
{ menu_arrow_width, menu_arrow_height, menu_arrow_bits }, /* OBM_MNARROW */
{ 0, 0, NULL }, /* OBM_LFARROWD */
{ 0, 0, NULL }, /* OBM_RGARROWD */
{ 0, 0, NULL }, /* OBM_DNARROWD */
{ 0, 0, NULL }, /* OBM_UPARROWD */
{ 0, 0, NULL }, /* OBM_RESTORED */
{ 0, 0, NULL }, /* OBM_ZOOMD */
{ 0, 0, NULL }, /* OBM_REDUCED */
{ 0, 0, NULL }, /* OBM_RESTORE */
{ 0, 0, NULL }, /* OBM_ZOOM */
{ 0, 0, NULL }, /* OBM_REDUCE */
{ 0, 0, NULL }, /* OBM_LFARROW */
{ 0, 0, NULL }, /* OBM_RGARROW */
{ 0, 0, NULL }, /* OBM_DNARROW */
{ 0, 0, NULL }, /* OBM_UPARROW */
{ 0, 0, NULL }, /* OBM_CLOSE */
{ 0, 0, NULL }, /* OBM_OLD_RESTORE */
{ 0, 0, NULL }, /* OBM_OLD_ZOOM */
{ 0, 0, NULL }, /* OBM_OLD_REDUCE */
{ 0, 0, NULL }, /* OBM_BTNCORNERS */
{ check_boxes_width, check_boxes_height,
check_boxes_bits }, /* OBM_CHECKBOXES */
{ check_mark_width, check_mark_height, check_mark_bits }, /* OBM_CHECK */
{ 0, 0, NULL }, /* OBM_BTSIZE */
{ 0, 0, NULL }, /* OBM_OLD_LFARROW */
{ 0, 0, NULL }, /* OBM_OLD_RGARROW */
{ 0, 0, NULL }, /* OBM_OLD_DNARROW */
{ 0, 0, NULL }, /* OBM_OLD_UPARROW */
{ 0, 0, NULL }, /* OBM_SIZE */
{ 0, 0, NULL }, /* OBM_OLD_CLOSE */
/* Black & white must always be the first 2 colors */
{ "black", RGB(0,0,0) },
{ "white", RGB(255,255,255) },
{ "red", RGB(255,0,0) },
{ "green", RGB(0,255,0) },
{ "blue", RGB(0,0,255) },
{ "yellow", RGB(255,255,0) },
{ "button_face", PALETTEINDEX(COLOR_BTNFACE) },
{ "button_shadow", PALETTEINDEX(COLOR_BTNSHADOW) },
{ "button_highlight", PALETTEINDEX(COLOR_BTNHIGHLIGHT) },
{ "button_text", PALETTEINDEX(COLOR_BTNTEXT) },
{ "window_frame", PALETTEINDEX(COLOR_WINDOWFRAME) }
};
#endif /* USE_XPM */
#define NB_COLOR_SYMBOLS \
(sizeof(OBM_SymbolicColors)/sizeof(OBM_SymbolicColors[0]))
static XpmColorSymbol *OBM_Colors = NULL;
/***********************************************************************
* OBM_InitColorSymbols
*/
#ifdef USE_XPM
static void OBM_InitColorSymbols()
static BOOL OBM_InitColorSymbols()
{
int i;
static int already_done = 0;
if (already_done) return;
if (OBM_Colors) return TRUE; /* Already initialised */
/* Init the system colors */
OBM_Colors = (XpmColorSymbol *) malloc( sizeof(XpmColorSymbol) *
NB_COLOR_SYMBOLS );
if (!OBM_Colors) return FALSE;
for (i = 0; i < NB_COLOR_SYMBOLS; i++)
{
OBM_Color_Symbols[i].pixel = COLOR_ToPhysical( NULL,
GetSysColor(OBM_Sys_Colors_Symbols[i]));
OBM_Colors[i].name = OBM_SymbolicColors[i].name;
OBM_Colors[i].value = NULL;
if (OBM_SymbolicColors[i].color & 0xff000000) /* PALETTEINDEX */
OBM_Colors[i].pixel = COLOR_ToPhysical( NULL,
GetSysColor(OBM_SymbolicColors[i].color & 0xff));
else /* RGB*/
OBM_Colors[i].pixel = COLOR_ToPhysical( NULL,
OBM_SymbolicColors[i].color );
}
/* Init black and white */
OBM_Color_Symbols[i++].pixel = COLOR_ToPhysical( NULL, RGB(0,0,0) );
OBM_Color_Symbols[i++].pixel = COLOR_ToPhysical( NULL, RGB(255,255,255) );
already_done = 1;
return TRUE;
}
#endif /* USE_XPM */
/***********************************************************************
* OBM_LoadOEMBitmap
* OBM_MakeBitmap
*
* Allocate a GDI bitmap.
*/
HBITMAP OBM_LoadOEMBitmap( WORD id )
static HBITMAP OBM_MakeBitmap( WORD width, WORD height,
WORD bpp, Pixmap pixmap )
{
BITMAPOBJ * bmpObjPtr;
HBITMAP hbitmap;
WORD width, height, bpp;
Pixmap pixmap;
if ((id < OBM_FIRST) || (id > OBM_LAST)) return 0;
id -= OBM_FIRST;
#ifdef USE_XPM
if (!OBM_Pixmaps_Data[id].data) return 0;
{
XpmAttributes attrs;
int err;
OBM_InitColorSymbols();
attrs.valuemask = XpmColormap | XpmDepth | XpmColorSymbols;
attrs.colormap = COLOR_WinColormap;
if (OBM_Pixmaps_Data[id].color) attrs.depth = bpp = screenDepth;
else attrs.depth = bpp = 1;
attrs.colorsymbols = (bpp > 1) ? OBM_Color_Symbols : OBM_BW_Symbols;
attrs.numsymbols = (bpp > 1) ? NB_COLOR_SYMBOLS + 2 : 2;
if ((err = XpmCreatePixmapFromData( display, rootWindow,
OBM_Pixmaps_Data[id].data,
&pixmap, NULL,
&attrs )) != XpmSuccess)
{
fprintf( stderr, "Error %d creating pixmap %d\n",
err, OBM_FIRST+id );
pixmap = width = height = 0;
}
else
{
width = attrs.width;
height = attrs.height;
}
}
#else
if (!OBM_Bitmaps_Data[id].data) return 0;
bpp = 1;
width = OBM_Bitmaps_Data[id].width;
height = OBM_Bitmaps_Data[id].height;
pixmap = XCreateBitmapFromData( display, rootWindow,
OBM_Bitmaps_Data[id].data, width, height );
#endif /* USE_XPM */
BITMAPOBJ * bmpObjPtr;
if (!pixmap) return 0;
/* Create the BITMAPOBJ */
if (!(hbitmap = GDI_AllocObject( sizeof(BITMAPOBJ), BITMAP_MAGIC )))
{
XFreePixmap( display, pixmap );
return 0;
}
hbitmap = GDI_AllocObject( sizeof(BITMAPOBJ), BITMAP_MAGIC );
if (!hbitmap) return 0;
bmpObjPtr = (BITMAPOBJ *) GDI_HEAP_ADDR( hbitmap );
bmpObjPtr->size.cx = 0;
bmpObjPtr->size.cy = 0;
@ -286,3 +208,121 @@ HBITMAP OBM_LoadOEMBitmap( WORD id )
}
/***********************************************************************
* OBM_CreateBitmaps
*
* Create the 2 bitmaps from XPM data.
*/
static BOOL OBM_CreateBitmaps( char **data, BOOL color, BOOL mask,
HBITMAP *hBitmap, HBITMAP *hBitmapMask )
{
Pixmap pixmap, pixmask;
XpmAttributes attrs;
int err;
attrs.valuemask = XpmColormap | XpmDepth | XpmColorSymbols;
attrs.colormap = COLOR_WinColormap;
attrs.depth = color ? screenDepth : 1;
attrs.colorsymbols = OBM_Colors;
attrs.numsymbols = (attrs.depth > 1) ? NB_COLOR_SYMBOLS : 2;
err = XpmCreatePixmapFromData( display, rootWindow, data,
&pixmap, &pixmask, &attrs );
if (err != XpmSuccess) return FALSE;
*hBitmap = OBM_MakeBitmap( attrs.width, attrs.height,
attrs.depth, pixmap );
if (mask) *hBitmapMask = OBM_MakeBitmap( attrs.width, attrs.height,
1, pixmask );
if (!*hBitmap)
{
if (pixmap) XFreePixmap( display, pixmap );
if (pixmask) XFreePixmap( display, pixmask );
if (*hBitmap) GDI_FreeObject( *hBitmap );
if (*hBitmapMask) GDI_FreeObject( *hBitmapMask );
return FALSE;
}
else return TRUE;
}
/***********************************************************************
* OBM_LoadBitmap
*/
HBITMAP OBM_LoadBitmap( WORD id )
{
HBITMAP hbitmap, hbitmask;
if ((id < OBM_FIRST) || (id > OBM_LAST)) return 0;
id -= OBM_FIRST;
if (!OBM_InitColorSymbols()) return 0;
if (!OBM_CreateBitmaps( OBM_Pixmaps_Data[id].data,
OBM_Pixmaps_Data[id].color,
FALSE, &hbitmap, &hbitmask ))
{
fprintf( stderr, "Error creating OEM bitmap %d\n", OBM_FIRST+id );
return 0;
}
return hbitmap;
}
/***********************************************************************
* OBM_LoadIcon
*/
HICON OBM_LoadIcon( WORD id )
{
HICON hicon;
ICONALLOC *pIcon;
BITMAPOBJ *bmp;
if ((id < OIC_FIRST) || (id > OIC_LAST)) return 0;
id -= OIC_FIRST;
if (!OBM_InitColorSymbols()) return 0;
if (!(hicon = GlobalAlloc( GMEM_MOVEABLE, sizeof(ICONALLOC) ))) return 0;
pIcon = (ICONALLOC *)GlobalLock( hicon );
if (!OBM_CreateBitmaps( OBM_Icons_Data[id], TRUE, TRUE,
&pIcon->hBitmap, &pIcon->hBitMask ))
{
fprintf( stderr, "Error creating OEM icon %d\n", OIC_FIRST+id );
GlobalFree( hicon );
return 0;
}
bmp = (BITMAPOBJ *) GDI_GetObjPtr( pIcon->hBitmap, BITMAP_MAGIC );
pIcon->descriptor.Width = bmp->bitmap.bmWidth;
pIcon->descriptor.Height = bmp->bitmap.bmHeight;
pIcon->descriptor.ColorCount = bmp->bitmap.bmBitsPixel;
if (pIcon->hBitMask)
{
BITMAPOBJ *bmpMask;
/* Invert the mask */
bmpMask = (BITMAPOBJ *) GDI_GetObjPtr( pIcon->hBitMask, BITMAP_MAGIC );
XSetFunction( display, BITMAP_monoGC, GXinvert );
XFillRectangle( display, bmpMask->pixmap, BITMAP_monoGC, 0, 0,
bmpMask->bitmap.bmWidth, bmpMask->bitmap.bmHeight );
/* Set the masked pixels to black */
if (bmp->bitmap.bmBitsPixel != 1)
{
XSetForeground( display, BITMAP_colorGC,
COLOR_ToPhysical( NULL, RGB(0,0,0) ));
XSetBackground( display, BITMAP_colorGC, 0 );
XSetFunction( display, BITMAP_colorGC, GXor );
XCopyPlane( display, bmpMask->pixmap, bmp->pixmap, BITMAP_colorGC,
0, 0, bmp->bitmap.bmWidth, bmp->bitmap.bmHeight,
0, 0, 1 );
XSetFunction( display, BITMAP_colorGC, GXcopy );
}
XSetFunction( display, BITMAP_monoGC, GXcopy );
}
return hicon;
}

View File

@ -14,7 +14,7 @@ MODULE = rc
XCOMM This would be nicer, but it breaks gcc (2.5.8 on Linux) --AJ
XCOMM gcc -E -x c -P $(CFLAGS) -imacros ../include/windows.h $*.rc | ./winerc -o $* -v -p $*
RCSRCS = sysres.rc sysresbm.rc
RCSRCS = sysres.rc
RCOBJS = $(RCSRCS:.rc=.o)

File diff suppressed because it is too large Load Diff

View File

@ -10,17 +10,17 @@
LONG CallWindowProc (WNDPROC func, HWND hwnd, WORD message,
WORD wParam, LONG lParam)
{
(*func)(hwnd, message, wParam, lParam);
return (*func)(hwnd, message, wParam, lParam);
}
CallLineDDAProc (FARPROC back, int x, int y, long lParam)
{
(*back)(x, y, lParam);
return (*back)(x, y, lParam);
}
DWORD CallHookProc (HOOKPROC func, short code, WPARAM wParam, LPARAM lParam)
{
(*func)(code, wParam, lParam);
return (*func)(code, wParam, lParam);
}
BOOL CallGrayStringProc (FARPROC func, HDC hdc, LPARAM lParam, INT cch)

View File

@ -1,4 +1,6 @@
#include <stdio.h>
#include <string.h>
#include <malloc.h>
#include "windows.h"
#include "wine.h"
@ -7,8 +9,8 @@ extern HINSTANCE hSysRes;
_WinMain (int argc, char *argv [])
{
int ret_val;
char filename [4096];
HANDLE hTaskMain;
char filename [4096], *module_name, *resource_file;
HANDLE hTaskMain, hInstance;
GetPrivateProfileString("wine", "SystemResources", "sysres.dll",
filename, sizeof(filename), WINE_INI);
@ -18,9 +20,20 @@ _WinMain (int argc, char *argv [])
else
printf("System Resources Loaded // hSysRes='%04X'\n", hSysRes);
if ((module_name = strchr (argv [0], '/')) == NULL){
printf ("Error: Can't determine base name for resource loading\n");
return 0;
}
resource_file = malloc (strlen (++module_name) + 5);
strcpy (resource_file, module_name);
strcat (resource_file, ".dll");
hInstance = LoadImage (resource_file, 0, 0);
USER_InitApp (hSysRes);
hTaskMain = CreateNewTask (1); /* This is not correct */
ret_val = WinMain (1, /* hInstance */
ret_val = WinMain (hInstance, /* hInstance */
0, /* hPrevInstance */
"", /* lpszCmdParam */
SW_NORMAL); /* nCmdShow */

View File

@ -89,14 +89,14 @@ do
y=`echo $x | tr a-z A-Z`
cat <<++EOF++ >>$DEBUG_H
#ifdef DEBUG_RUNTIME
#define dprintf_$x if(debug_msg_enabled[$i]) fprintf
#define dprintf_$x if(!debug_msg_enabled[$i]) ; else fprintf
#define debugging_$x debug_msg_enabled[$i]
#else
#ifdef DEBUG_$y
#define dprintf_$x fprintf
#define debugging_$x 1
#else
#define dprintf_$x
#define dprintf_$x while(0) fprintf
#define debugging_$x 0
#endif
#endif