summaryrefslogtreecommitdiff
path: root/src/Vendor.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/Vendor.c')
-rw-r--r--src/Vendor.c23
1 files changed, 21 insertions, 2 deletions
diff --git a/src/Vendor.c b/src/Vendor.c
index 3b282dc..b2f0b0d 100644
--- a/src/Vendor.c
+++ b/src/Vendor.c
@@ -46,7 +46,7 @@ ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
SOFTWARE.
******************************************************************/
-/* $XFree86: xc/lib/Xt/Vendor.c,v 1.7 2002/05/31 18:45:46 dawes Exp $ */
+/* $XFree86: xc/lib/Xt/Vendor.c,v 1.8 2003/12/22 21:10:25 dickey Exp $ */
/* Make sure all wm properties can make it out of the resource manager */
@@ -64,9 +64,11 @@ SOFTWARE.
*
***************************************************************************/
-#ifdef __UNIXOS2__
+#if defined(__UNIXOS2__) || defined(__CYGWIN__)
/* to fix the EditRes problem because of wrong linker semantics */
extern WidgetClass vendorShellWidgetClass;
+
+#if defined(__UNIXOS2__)
unsigned long _DLL_InitTerm(unsigned long mod,unsigned long flag)
{
switch (flag) {
@@ -82,6 +84,23 @@ unsigned long _DLL_InitTerm(unsigned long mod,unsigned long flag)
}
#endif
+#if defined(__CYGWIN__)
+int __stdcall
+DllMain(unsigned long mod_handle, unsigned long flag, void *routine)
+{
+ switch (flag)
+ {
+ case 1: /* DLL_PROCESS_ATTACH - process attach */
+ vendorShellWidgetClass = (WidgetClass)(&vendorShellClassRec);
+ break;
+ case 0: /* DLL_PROCESS_DETACH - process detach */
+ break;
+ }
+ return 1;
+}
+#endif
+#endif
+
externaldef(vendorshellclassrec) VendorShellClassRec vendorShellClassRec = {
{
/* superclass */ (WidgetClass) &wmShellClassRec,