Changeset 213
- Timestamp:
- Dec 18, 2010, 12:41:53 AM (15 years ago)
- Location:
- trunk/openjdk/jdk
- Files:
-
- 3 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/openjdk/jdk/make/sun/font/FILES_c.gmk
r200 r213 115 115 ifeq ($(filter-out windows os2,$(PLATFORM)),) 116 116 FILES_c_platform = fontpath.c 117 ifneq ($(PLATFORM), os2) 117 ifeq ($(PLATFORM), os2) 118 FILES_c_platform += fontpath_os2.c 118 119 # no D3D on OS/2 120 else 119 121 FILES_cpp_platform = D3DTextRenderer.cpp 120 122 endif -
trunk/openjdk/jdk/make/sun/font/Makefile
r202 r213 171 171 vpath %.cpp $(SHARE_SRC)/native/$(PKGDIR) 172 172 173 ifeq ($(PLATFORM), os2) 174 vpath %.c $(PLATFORM_SRC_OS2)/native/$(PKGDIR) 175 endif 176 173 177 # 174 178 # Fontmanager is headless (independent of X/Motif) -
trunk/openjdk/jdk/src/windows/native/sun/font/fontpath.c
r200 r213 37 37 #include <wchar.h> 38 38 #include <minivcrt.h> 39 extern char *getOs2FontPath(); 39 40 #endif 40 41 … … 43 44 char windir[BSIZE]; 44 45 char sysdir[BSIZE]; 46 #ifdef __WIN32OS2__ 47 char *fontpath; 48 #else 45 49 char fontpath[BSIZE*2]; 50 #endif 46 51 char *end; 52 53 #ifdef __WIN32OS2__ 54 /* Find out all folders containing registered fonts in OS/2 to let Java 55 * pick them up */ 56 fontpath = getOs2FontPath(); 57 fontpath = fontpath ? realloc(fontpath, strlen(fontpath) + BSIZE*2) 58 : malloc(BSIZE*2); 59 if (!fontpath) 60 return NULL; 61 #endif 47 62 48 63 /* Locate fonts directories relative to the Windows System directory. … … 65 80 } 66 81 82 #ifdef __WIN32OS2__ 83 strcat(fontpath,sysdir); 84 #else 67 85 strcpy(fontpath,sysdir); 86 #endif 68 87 if (stricmp(sysdir,windir)) { 69 88 strcat(fontpath,";"); … … 71 90 } 72 91 73 return JNU_NewStringPlatform(env, fontpath); 92 jstring ret = JNU_NewStringPlatform(env, fontpath); 93 #ifdef __WIN32OS2__ 94 free(fontpath); 95 #endif 96 97 return ret; 74 98 } 75 99
Note:
See TracChangeset
for help on using the changeset viewer.