提交 0d1cf430 编写于 作者: L lana

Merge

...@@ -205,3 +205,5 @@ dfb40f066c6ce129822f0f5dc2ac89173808781a jdk8-b80 ...@@ -205,3 +205,5 @@ dfb40f066c6ce129822f0f5dc2ac89173808781a jdk8-b80
c0f8022eba536dcdc8aae659005b33f3982b9368 jdk8-b81 c0f8022eba536dcdc8aae659005b33f3982b9368 jdk8-b81
624bcb4800065c6656171948e31ebb2925f25c7a jdk8-b82 624bcb4800065c6656171948e31ebb2925f25c7a jdk8-b82
ac519af51769e92c51b597a730974e8607357709 jdk8-b83 ac519af51769e92c51b597a730974e8607357709 jdk8-b83
7b4721e4edb4e1c65e9c839a70d7cc67f81c7632 jdk8-b84
296676d534c52888c36e305a2bf7f345c4ca70f8 jdk8-b85
...@@ -316,6 +316,8 @@ JAVA_JAVA_java = \ ...@@ -316,6 +316,8 @@ JAVA_JAVA_java = \
java/util/concurrent/BrokenBarrierException.java \ java/util/concurrent/BrokenBarrierException.java \
java/util/concurrent/Callable.java \ java/util/concurrent/Callable.java \
java/util/concurrent/CancellationException.java \ java/util/concurrent/CancellationException.java \
java/util/concurrent/CompletableFuture.java \
java/util/concurrent/CompletionException.java \
java/util/concurrent/CompletionService.java \ java/util/concurrent/CompletionService.java \
java/util/concurrent/ConcurrentHashMap.java \ java/util/concurrent/ConcurrentHashMap.java \
java/util/concurrent/ConcurrentLinkedDeque.java \ java/util/concurrent/ConcurrentLinkedDeque.java \
......
...@@ -136,8 +136,7 @@ define SetupDemo ...@@ -136,8 +136,7 @@ define SetupDemo
$$(wildcard $$(addprefix $(JDK_TOPDIR)/src/$6share/demo/$2/$1/,$7))) $$(wildcard $$(addprefix $(JDK_TOPDIR)/src/$6share/demo/$2/$1/,$7)))
ifneq ($7,) ifneq ($7,)
$(JDK_OUTPUTDIR)/demo/$2/$1/% : $(JDK_TOPDIR)/src/$6share/demo/$2/$1/% $(JDK_OUTPUTDIR)/demo/$2/$1/% : $(JDK_TOPDIR)/src/$6share/demo/$2/$1/%
$(MKDIR) -p $$(@D) $$(call install-file)
$(CP) $$< $$@
$(CHMOD) -f ug+w $$@ $(CHMOD) -f ug+w $$@
BUILD_DEMOS += $$($1_COPY_TARGETS) BUILD_DEMOS += $$($1_COPY_TARGETS)
...@@ -190,8 +189,7 @@ ifndef OPENJDK ...@@ -190,8 +189,7 @@ ifndef OPENJDK
$(JDK_OUTPUTDIR)/demo/nbproject/%,\ $(JDK_OUTPUTDIR)/demo/nbproject/%,\
$(call CacheFind,$(JDK_TOPDIR)/src/closed/share/demo/nbproject)) $(call CacheFind,$(JDK_TOPDIR)/src/closed/share/demo/nbproject))
$(JDK_OUTPUTDIR)/demo/nbproject/% : $(JDK_TOPDIR)/src/closed/share/demo/nbproject/% $(JDK_OUTPUTDIR)/demo/nbproject/% : $(JDK_TOPDIR)/src/closed/share/demo/nbproject/%
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
endif endif
...@@ -268,8 +266,7 @@ define SetupJVMTIDemo ...@@ -268,8 +266,7 @@ define SetupJVMTIDemo
ZIP:=$(JDK_OUTPUTDIR)/demo/jvmti/$1/src.zip)) ZIP:=$(JDK_OUTPUTDIR)/demo/jvmti/$1/src.zip))
$(JDK_OUTPUTDIR)/demo/jvmti/$1/README.txt : $(JDK_TOPDIR)/src/share/demo/jvmti/$1/README.txt $(JDK_OUTPUTDIR)/demo/jvmti/$1/README.txt : $(JDK_TOPDIR)/src/share/demo/jvmti/$1/README.txt
$(MKDIR) -p $$(@D) $$(call install-file)
$(CP) $$< $$@
$(CHMOD) -f ug+w $$@ $(CHMOD) -f ug+w $$@
ifneq (,$$(wildcard $(JDK_TOPDIR)/src/share/demo/jvmti/$1/*.java)) ifneq (,$$(wildcard $(JDK_TOPDIR)/src/share/demo/jvmti/$1/*.java))
...@@ -325,23 +322,22 @@ JPDA_SOURCES:=$(call CacheFind,$(JDK_TOPDIR)/src/share/classes/com/sun/tools/exa ...@@ -325,23 +322,22 @@ JPDA_SOURCES:=$(call CacheFind,$(JDK_TOPDIR)/src/share/classes/com/sun/tools/exa
JPDA_FILES:=$(subst $(JDK_TOPDIR)/src/share/classes/,,$(JPDA_SOURCES)) JPDA_FILES:=$(subst $(JDK_TOPDIR)/src/share/classes/,,$(JPDA_SOURCES))
$(JDK_OUTPUTDIR)/demo/jpda/src.zip : $(JPDA_SOURCES) $(JDK_OUTPUTDIR)/demo/jpda/src.zip : $(JPDA_SOURCES)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
(cd $(JDK_TOPDIR)/src/share/classes && $(ZIP) -qru $@ com -i "com/sun/tools/example/*") (cd $(JDK_TOPDIR)/src/share/classes && $(ZIP) -qru $@ com -i "com/sun/tools/example/*")
$(JDK_OUTPUTDIR)/demo/jpda/examples.jar : $(JPDA_SOURCES) $(JDK_OUTPUTDIR)/demo/jpda/examples.jar : $(JPDA_SOURCES)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $(@D)/_the.sources $(RM) $(@D)/_the.sources
$(call ListPathsSafely,JPDA_FILES,\n, >> $(@D)/_the.sources) $(call ListPathsSafely,JPDA_FILES,\n, >> $(@D)/_the.sources)
$(SED) -e "s#@@RELEASE@@#$(RELEASE)#" \ $(SED) -e "s#@@RELEASE@@#$(RELEASE)#" \
-e "s#@@COMPANY_NAME@@#$(COMPANY_NAME)#" $(JDK_TOPDIR)/make/tools/manifest.mf > $(@D)/_the.manifest -e "s#@@COMPANY_NAME@@#$(COMPANY_NAME)#" $(JDK_TOPDIR)/make/tools/manifest.mf > $(@D)/_the.manifest
$(ECHO) "Main-Class: " >> $(@D)/_the.manifest $(ECHO) "Main-Class: " >> $(@D)/_the.manifest
(cd $(JDK_TOPDIR)/src/share/classes && $(JAR) cfm $@ $(@D)/_the.manifest @$(@D)/_the.sources) (cd $(JDK_TOPDIR)/src/share/classes && $(JAR) cfm $@ $(@D)/_the.manifest @$(@D)/_the.sources)
(cd $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example && $(JAR) uf $@ README) (cd $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example && $(JAR) uf $@ README)
$(JDK_OUTPUTDIR)/demo/jpda/com/sun/tools/example/README : $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example/README $(JDK_OUTPUTDIR)/demo/jpda/com/sun/tools/example/README : $(JDK_TOPDIR)/src/share/classes/com/sun/tools/example/README
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@ $(CHMOD) -f ug+w $@
$(CHMOD) -f ug+w $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jpda/src.zip $(JDK_OUTPUTDIR)/demo/jpda/examples.jar \ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jpda/src.zip $(JDK_OUTPUTDIR)/demo/jpda/examples.jar \
$(JDK_OUTPUTDIR)/demo/jpda/com/sun/tools/example/README $(JDK_OUTPUTDIR)/demo/jpda/com/sun/tools/example/README
...@@ -349,14 +345,12 @@ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jpda/src.zip $(JDK_OUTPUTDIR)/demo/jpda/exa ...@@ -349,14 +345,12 @@ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jpda/src.zip $(JDK_OUTPUTDIR)/demo/jpda/exa
################################################################################################## ##################################################################################################
$(JDK_OUTPUTDIR)/demo/management/index.html : $(JDK_TOPDIR)/src/share/demo/management/index.html $(JDK_OUTPUTDIR)/demo/management/index.html : $(JDK_TOPDIR)/src/share/demo/management/index.html
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@ $(CHMOD) -f ug+w $@
$(CHMOD) -f ug+w $@
$(JDK_OUTPUTDIR)/demo/jvmti/index.html : $(JDK_TOPDIR)/src/share/demo/jvmti/index.html $(JDK_OUTPUTDIR)/demo/jvmti/index.html : $(JDK_TOPDIR)/src/share/demo/jvmti/index.html
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@ $(CHMOD) -f ug+w $@
$(CHMOD) -f ug+w $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/management/index.html \ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/management/index.html \
$(JDK_OUTPUTDIR)/demo/jvmti/index.html $(JDK_OUTPUTDIR)/demo/jvmti/index.html
...@@ -369,15 +363,13 @@ BUILD_DEMOS += $(patsubst $(JDK_TOPDIR)/src/share/demo/nbproject/%,\ ...@@ -369,15 +363,13 @@ BUILD_DEMOS += $(patsubst $(JDK_TOPDIR)/src/share/demo/nbproject/%,\
$(call CacheFind,$(JDK_TOPDIR)/src/share/demo/nbproject)) $(call CacheFind,$(JDK_TOPDIR)/src/share/demo/nbproject))
$(JDK_OUTPUTDIR)/demo/nbproject/% : $(JDK_TOPDIR)/src/share/demo/nbproject/% $(JDK_OUTPUTDIR)/demo/nbproject/% : $(JDK_TOPDIR)/src/share/demo/nbproject/%
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
$(CHMOD) -f ug+w $@ $(CHMOD) -f ug+w $@
################################################################################################## ##################################################################################################
$(JDK_OUTPUTDIR)/demo/README: $(JDK_TOPDIR)/src/share/demo/README $(JDK_OUTPUTDIR)/demo/README: $(JDK_TOPDIR)/src/share/demo/README
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/README BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/README
...@@ -386,14 +378,12 @@ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/README ...@@ -386,14 +378,12 @@ BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/README
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
$(JDK_OUTPUTDIR)/democlasses/jni/Poller/% : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/% $(JDK_OUTPUTDIR)/democlasses/jni/Poller/% : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/%
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@ $(CHMOD) -f ug+w $@
$(CHMOD) -f ug+w $@
$(JDK_OUTPUTDIR)/demo/jni/Poller/README.txt : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/README.txt $(JDK_OUTPUTDIR)/demo/jni/Poller/README.txt : $(JDK_TOPDIR)/src/solaris/demo/jni/Poller/README.txt
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@ $(CHMOD) -f ug+w $@
$(CHMOD) -f ug+w $@
$(JDK_OUTPUTDIR)/demo/jni/Poller/Poller.jar : \ $(JDK_OUTPUTDIR)/demo/jni/Poller/Poller.jar : \
$(JDK_OUTPUTDIR)/democlasses/jni/Poller/README.txt $(JDK_OUTPUTDIR)/democlasses/jni/Poller/Poller.c $(JDK_OUTPUTDIR)/democlasses/jni/Poller/README.txt $(JDK_OUTPUTDIR)/democlasses/jni/Poller/Poller.c
...@@ -433,8 +423,7 @@ $(JDK_OUTPUTDIR)/demoobjs/jni/Poller/Poller.o : $(JDK_OUTPUTDIR)/demo/jni/Poller ...@@ -433,8 +423,7 @@ $(JDK_OUTPUTDIR)/demoobjs/jni/Poller/Poller.o : $(JDK_OUTPUTDIR)/demo/jni/Poller
$(JDK_OUTPUTDIR)/demo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) : \ $(JDK_OUTPUTDIR)/demo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) : \
$(JDK_OUTPUTDIR)/demoobjs/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) $(JDK_OUTPUTDIR)/demoobjs/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX)
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX) BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/jni/Poller/lib/$(LIBRARY_PREFIX)Poller$(SHARED_LIBRARY_SUFFIX)
...@@ -456,8 +445,8 @@ ifndef OPENJDK ...@@ -456,8 +445,8 @@ ifndef OPENJDK
$(JDK_OUTPUTDIR)/demo/db/README-JDK-DEMOS.html: \ $(JDK_OUTPUTDIR)/demo/db/README-JDK-DEMOS.html: \
$(JDK_TOPDIR)/src/closed/share/db/README-JDK-DEMOS.html \ $(JDK_TOPDIR)/src/closed/share/db/README-JDK-DEMOS.html \
| $(JDK_OUTPUTDIR)/demo/_the.db.unzipped | $(JDK_OUTPUTDIR)/demo/_the.db.unzipped
$(MKDIR) -p $(@D) $(call install-file)
$(CP) '$<' '$@'
BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/_the.db.unzipped $(JDK_OUTPUTDIR)/demo/db/README-JDK-DEMOS.html BUILD_DEMOS += $(JDK_OUTPUTDIR)/demo/_the.db.unzipped $(JDK_OUTPUTDIR)/demo/db/README-JDK-DEMOS.html
endif endif
......
...@@ -281,8 +281,7 @@ endif ...@@ -281,8 +281,7 @@ endif
# These resources violates the convention of having code and resources together under # These resources violates the convention of having code and resources together under
# $(JDK_TOPDIR)/src/.../classes directories # $(JDK_TOPDIR)/src/.../classes directories
$(JDK_OUTPUTDIR)/classes/javax/swing/beaninfo/images/%.gif: $(JDK_TOPDIR)/make/tools/swing-beans/beaninfo/images/%.gif $(JDK_OUTPUTDIR)/classes/javax/swing/beaninfo/images/%.gif: $(JDK_TOPDIR)/make/tools/swing-beans/beaninfo/images/%.gif
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
# The JDK_USER_DEFINED_FILTER is a poor man's incremental build: by specifying # The JDK_USER_DEFINED_FILTER is a poor man's incremental build: by specifying
# JDK_FILTER at the make command line, only a subset of the JDK java files will # JDK_FILTER at the make command line, only a subset of the JDK java files will
......
...@@ -489,8 +489,7 @@ endif ...@@ -489,8 +489,7 @@ endif
# -link -incremental:no # -link -incremental:no
# like all other launchers. # like all other launchers.
$(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/unpack200$(EXE_SUFFIX): $(BUILD_UNPACKEXE) $(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/unpack200$(EXE_SUFFIX): $(BUILD_UNPACKEXE)
$(MKDIR) -p $(@D) $(call install-file)
$(CP) '$<' '$@'
BUILD_LAUNCHERS += $(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/unpack200$(EXE_SUFFIX) BUILD_LAUNCHERS += $(JDK_OUTPUTDIR)/bin$(OUTPUT_SUBDIR)/unpack200$(EXE_SUFFIX)
...@@ -588,8 +587,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows) ...@@ -588,8 +587,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows)
$(call SET_SHARED_LIBRARY_MAPFILE,$(JDK_TOPDIR)/makefiles/java/main/java/mapfile-$(OPENJDK_TARGET_CPU)))) $(call SET_SHARED_LIBRARY_MAPFILE,$(JDK_TOPDIR)/makefiles/java/main/java/mapfile-$(OPENJDK_TARGET_CPU))))
else else
$(JAVA_RMI_CGI): $(JDK_TOPDIR)/src/solaris/bin/java-rmi.cgi.sh $(JAVA_RMI_CGI): $(JDK_TOPDIR)/src/solaris/bin/java-rmi.cgi.sh
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
$(CHMOD) a+x $@ $(CHMOD) a+x $@
endif endif
......
...@@ -109,7 +109,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM_MAC,\ ...@@ -109,7 +109,7 @@ $(eval $(call SetupNativeCompilation,BUILD_LIBFDLIBM_MAC,\
BUILD_LIBFDLIBM := $(JDK_OUTPUTDIR)/objs/$(LIBRARY_PREFIX)fdlibm$(STATIC_LIBRARY_SUFFIX) BUILD_LIBFDLIBM := $(JDK_OUTPUTDIR)/objs/$(LIBRARY_PREFIX)fdlibm$(STATIC_LIBRARY_SUFFIX)
$(BUILD_LIBFDLIBM) : $(BUILD_LIBFDLIBM_MAC) $(BUILD_LIBFDLIBM) : $(BUILD_LIBFDLIBM_MAC)
$(CP) -a $< $@ $(call install-file)
endif endif
BUILD_LIBRARIES += $(BUILD_LIBFDLIBM) BUILD_LIBRARIES += $(BUILD_LIBFDLIBM)
...@@ -1838,16 +1838,14 @@ BUILD_LIBRARIES += $(BUILD_LIBNET) ...@@ -1838,16 +1838,14 @@ BUILD_LIBRARIES += $(BUILD_LIBNET)
$(JDK_OUTPUTDIR)/lib/net.properties: $(JDK_TOPDIR)/src/share/lib/net.properties $(JDK_OUTPUTDIR)/lib/net.properties: $(JDK_TOPDIR)/src/share/lib/net.properties
$(ECHO) $(LOG_INFO) Copying $(@F) $(ECHO) $(LOG_INFO) Copying $(@F)
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
COPY_FILES += $(JDK_OUTPUTDIR)/lib/net.properties COPY_FILES += $(JDK_OUTPUTDIR)/lib/net.properties
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
$(JDK_OUTPUTDIR)/lib/sdp/sdp.conf.template : $(JDK_TOPDIR)/src/${OPENJDK_TARGET_OS_API_DIR}/lib/sdp/sdp.conf.template $(JDK_OUTPUTDIR)/lib/sdp/sdp.conf.template : $(JDK_TOPDIR)/src/${OPENJDK_TARGET_OS_API_DIR}/lib/sdp/sdp.conf.template
$(ECHO) $(LOG_INFO) Copying $(@F) $(ECHO) $(LOG_INFO) Copying $(@F)
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
COPY_FILES += $(JDK_OUTPUTDIR)/lib/sdp/sdp.conf.template COPY_FILES += $(JDK_OUTPUTDIR)/lib/sdp/sdp.conf.template
endif endif
...@@ -2168,7 +2166,7 @@ else ifeq ($(OPENJDK_TARGET_OS),macosx) ...@@ -2168,7 +2166,7 @@ else ifeq ($(OPENJDK_TARGET_OS),macosx)
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli_static)) OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjli_static))
$(JDK_OUTPUTDIR)/objs/libjli_static.a : $(BUILD_LIBJLI_STATIC) $(JDK_OUTPUTDIR)/objs/libjli_static.a : $(BUILD_LIBJLI_STATIC)
$(CP) -a $< $@ $(call install-file)
BUILD_LIBRARIES += $(JDK_OUTPUTDIR)/objs/libjli_static.a BUILD_LIBRARIES += $(JDK_OUTPUTDIR)/objs/libjli_static.a
endif endif
...@@ -2386,18 +2384,23 @@ endif ...@@ -2386,18 +2384,23 @@ endif
ifndef BUILD_HEADLESS_ONLY ifndef BUILD_HEADLESS_ONLY
LIBSPLASHSCREEN_DIRS:=\ LIBSPLASHSCREEN_DIRS:=\
$(JDK_TOPDIR)/src/share/native/sun/awt/giflib \
$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \ $(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \
$(JDK_TOPDIR)/src/share/native/sun/awt/libpng \ $(JDK_TOPDIR)/src/share/native/sun/awt/libpng \
$(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen $(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen
ifeq ($(USE_EXTERNAL_LIBGIF),true)
GIFLIB_LDFLAGS := -lgif
else
LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/share/native/sun/awt/giflib
GIFLIB_CFLAGS := -I$(JDK_TOPDIR)/src/share/native/sun/awt/giflib
endif
ifneq ($(OPENJDK_TARGET_OS), macosx) ifneq ($(OPENJDK_TARGET_OS), macosx)
LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt/splashscreen LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt/splashscreen
else else
LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/macosx/native/sun/awt/splashscreen LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/macosx/native/sun/awt/splashscreen
endif endif
LIBSPLASHSCREEN_CFLAGS:=-DSPLASHSCREEN -DPNG_NO_MMX_CODE \ LIBSPLASHSCREEN_CFLAGS:=-DSPLASHSCREEN -DPNG_NO_MMX_CODE \
$(foreach dir,$(LIBSPLASHSCREEN_DIRS),-I$(dir)) $(foreach dir,$(LIBSPLASHSCREEN_DIRS),-I$(dir))
...@@ -2449,11 +2452,11 @@ $(eval $(call SetupNativeCompilation,LIBSPLASHSCREEN,\ ...@@ -2449,11 +2452,11 @@ $(eval $(call SetupNativeCompilation,LIBSPLASHSCREEN,\
EXCLUDE_FILES:=imageioJPEG.c jpegdecoder.c pngtest.c,\ EXCLUDE_FILES:=imageioJPEG.c jpegdecoder.c pngtest.c,\
LANG:=C,\ LANG:=C,\
OPTIMIZATION:=LOW, \ OPTIMIZATION:=LOW, \
CFLAGS:=$(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB),\ CFLAGS:=$(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB) $(GIFLIB_CFLAGS),\
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \ MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \
LDFLAGS:=$(LDFLAGS_JDKLIB) \ LDFLAGS:=$(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN),\ $(call SET_SHARED_LIBRARY_ORIGIN),\
LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ),\ LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(GIFLIB_LDFLAGS),\
LDFLAGS_SUFFIX_solaris:=-lc,\ LDFLAGS_SUFFIX_solaris:=-lc,\
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\ VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
RC_FLAGS:=$(RC_FLAGS)\ RC_FLAGS:=$(RC_FLAGS)\
......
...@@ -46,14 +46,10 @@ H_TARGET_FILES =$(INCLUDEDIR)/jdwpTransport.h \ ...@@ -46,14 +46,10 @@ H_TARGET_FILES =$(INCLUDEDIR)/jdwpTransport.h \
$(OPENJDK_TARGET_OS_INCLUDE)/jawt_md.h $(OPENJDK_TARGET_OS_INCLUDE)/jawt_md.h
$(INCLUDEDIR)/%.h: $(JDK_TOPDIR)/src/share/javavm/export/%.h $(INCLUDEDIR)/%.h: $(JDK_TOPDIR)/src/share/javavm/export/%.h
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(OPENJDK_TARGET_OS_INCLUDE)/%.h: $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/javavm/export/%.h $(OPENJDK_TARGET_OS_INCLUDE)/%.h: $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/javavm/export/%.h
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES = $(H_TARGET_FILES) COPY_FILES = $(H_TARGET_FILES)
...@@ -88,22 +84,16 @@ MGMT_SRC_FILES = $(wildcard $(MGMT_LIB_SRC)/*) ...@@ -88,22 +84,16 @@ MGMT_SRC_FILES = $(wildcard $(MGMT_LIB_SRC)/*)
MGMT_TARGET_FILES = $(subst $(MGMT_LIB_SRC),$(MGMT_LIBDIR),$(MGMT_SRC_FILES)) MGMT_TARGET_FILES = $(subst $(MGMT_LIB_SRC),$(MGMT_LIBDIR),$(MGMT_SRC_FILES))
$(MGMT_LIBDIR)/management.properties: $(MGMT_LIB_SRC)/management.properties $(MGMT_LIBDIR)/management.properties: $(MGMT_LIB_SRC)/management.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) 644 $@ $(CHMOD) 644 $@
# this file has different permissions...don't know why... # this file has different permissions...don't know why...
$(MGMT_LIBDIR)/jmxremote.access: $(MGMT_LIB_SRC)/jmxremote.access $(MGMT_LIBDIR)/jmxremote.access: $(MGMT_LIB_SRC)/jmxremote.access
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) 644 $@ $(CHMOD) 644 $@
$(MGMT_LIBDIR)/%: $(MGMT_LIB_SRC)/% $(MGMT_LIBDIR)/%: $(MGMT_LIB_SRC)/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
COPY_FILES += $(MGMT_TARGET_FILES) COPY_FILES += $(MGMT_TARGET_FILES)
...@@ -113,9 +103,7 @@ COPY_FILES += $(MGMT_TARGET_FILES) ...@@ -113,9 +103,7 @@ COPY_FILES += $(MGMT_TARGET_FILES)
LOGGING_LIB_SRC = $(JDK_TOPDIR)/src/share/lib LOGGING_LIB_SRC = $(JDK_TOPDIR)/src/share/lib
$(LIBDIR)/logging.properties: $(LOGGING_LIB_SRC)/logging.properties $(LIBDIR)/logging.properties: $(LOGGING_LIB_SRC)/logging.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(LIBDIR)/logging.properties COPY_FILES += $(LIBDIR)/logging.properties
...@@ -128,9 +116,7 @@ PSFONTPROPFILE_SRCS = $(wildcard $(PSFONTPROPFILE_SRC_DIR)/*.properties*) ...@@ -128,9 +116,7 @@ PSFONTPROPFILE_SRCS = $(wildcard $(PSFONTPROPFILE_SRC_DIR)/*.properties*)
PSFONTPROPFILE_TARGET_FILES = $(subst $(PSFONTPROPFILE_SRC_DIR),$(LIBDIR),$(PSFONTPROPFILE_SRCS)) PSFONTPROPFILE_TARGET_FILES = $(subst $(PSFONTPROPFILE_SRC_DIR),$(LIBDIR),$(PSFONTPROPFILE_SRCS))
$(LIBDIR)/%: $(PSFONTPROPFILE_SRC_DIR)/% $(LIBDIR)/%: $(PSFONTPROPFILE_SRC_DIR)/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(PSFONTPROPFILE_TARGET_FILES) COPY_FILES += $(PSFONTPROPFILE_TARGET_FILES)
...@@ -145,9 +131,7 @@ OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/macosx/lib ...@@ -145,9 +131,7 @@ OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/macosx/lib
endif endif
$(LIBDIR)/flavormap.properties: $(OPENJDK_TARGET_OS_LIB_SRC)/flavormap.properties $(LIBDIR)/flavormap.properties: $(OPENJDK_TARGET_OS_LIB_SRC)/flavormap.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(LIBDIR)/flavormap.properties COPY_FILES += $(LIBDIR)/flavormap.properties
...@@ -155,9 +139,7 @@ CURSORS_DEST_DIR = $(LIBDIR)/images/cursors ...@@ -155,9 +139,7 @@ CURSORS_DEST_DIR = $(LIBDIR)/images/cursors
CURSORS_OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib/images/cursors CURSORS_OPENJDK_TARGET_OS_LIB_SRC = $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib/images/cursors
$(CURSORS_DEST_DIR)/cursors.properties: $(CURSORS_OPENJDK_TARGET_OS_LIB_SRC)/cursors.properties $(CURSORS_DEST_DIR)/cursors.properties: $(CURSORS_OPENJDK_TARGET_OS_LIB_SRC)/cursors.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(CURSORS_DEST_DIR)/cursors.properties COPY_FILES += $(CURSORS_DEST_DIR)/cursors.properties
...@@ -170,9 +152,7 @@ endif # OPENJDK_TARGET_OS ...@@ -170,9 +152,7 @@ endif # OPENJDK_TARGET_OS
CURSORS_TARGET_FILES = $(subst $(CURSORS_LIB_SRC),$(CURSORS_DEST_DIR),$(CURSORS_SRC_FILES)) CURSORS_TARGET_FILES = $(subst $(CURSORS_LIB_SRC),$(CURSORS_DEST_DIR),$(CURSORS_SRC_FILES))
$(CURSORS_DEST_DIR)/%: $(CURSORS_LIB_SRC)/% $(CURSORS_DEST_DIR)/%: $(CURSORS_LIB_SRC)/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(CURSORS_TARGET_FILES) COPY_FILES += $(CURSORS_TARGET_FILES)
...@@ -181,9 +161,7 @@ COPY_FILES += $(CURSORS_TARGET_FILES) ...@@ -181,9 +161,7 @@ COPY_FILES += $(CURSORS_TARGET_FILES)
CONTENT_TYPES_SRC=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib CONTENT_TYPES_SRC=$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib
$(LIBDIR)/content-types.properties: $(CONTENT_TYPES_SRC)/content-types.properties $(LIBDIR)/content-types.properties: $(CONTENT_TYPES_SRC)/content-types.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(LIBDIR)/content-types.properties COPY_FILES += $(LIBDIR)/content-types.properties
...@@ -192,9 +170,7 @@ COPY_FILES += $(LIBDIR)/content-types.properties ...@@ -192,9 +170,7 @@ COPY_FILES += $(LIBDIR)/content-types.properties
CALENDARS_SRC := $(JDK_TOPDIR)/src/share/lib CALENDARS_SRC := $(JDK_TOPDIR)/src/share/lib
$(LIBDIR)/calendars.properties: $(CALENDARS_SRC)/calendars.properties $(LIBDIR)/calendars.properties: $(CALENDARS_SRC)/calendars.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(LIBDIR)/calendars.properties COPY_FILES += $(LIBDIR)/calendars.properties
...@@ -205,9 +181,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows) ...@@ -205,9 +181,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows)
TZMAPPINGS_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib TZMAPPINGS_SRC := $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/lib
$(LIBDIR)/tzmappings: $(TZMAPPINGS_SRC)/tzmappings $(LIBDIR)/tzmappings: $(TZMAPPINGS_SRC)/tzmappings
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(LIBDIR)/tzmappings COPY_FILES += $(LIBDIR)/tzmappings
...@@ -227,9 +201,7 @@ ICCPROFILE_SRCS:=$(wildcard $(ICCPROFILE_SRC_DIR)/*.pf) ...@@ -227,9 +201,7 @@ ICCPROFILE_SRCS:=$(wildcard $(ICCPROFILE_SRC_DIR)/*.pf)
ICCPROFILE_TARGET_FILES:=$(subst $(ICCPROFILE_SRC_DIR),$(ICCPROFILE_DEST_DIR),$(ICCPROFILE_SRCS)) ICCPROFILE_TARGET_FILES:=$(subst $(ICCPROFILE_SRC_DIR),$(ICCPROFILE_DEST_DIR),$(ICCPROFILE_SRCS))
$(ICCPROFILE_DEST_DIR)%.pf: $(ICCPROFILE_SRC_DIR)%.pf $(ICCPROFILE_DEST_DIR)%.pf: $(ICCPROFILE_SRC_DIR)%.pf
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) 444 $@ $(CHMOD) 444 $@
COPY_FILES += $(ICCPROFILE_TARGET_FILES) COPY_FILES += $(ICCPROFILE_TARGET_FILES)
...@@ -279,9 +251,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows) ...@@ -279,9 +251,7 @@ ifeq ($(OPENJDK_TARGET_OS),windows)
MSVCR_TARGET := $(JDK_OUTPUTDIR)/bin/$(notdir $(MSVCR_DLL)) MSVCR_TARGET := $(JDK_OUTPUTDIR)/bin/$(notdir $(MSVCR_DLL))
# Chmod to avoid permission issues if bundles are unpacked on unix platforms. # Chmod to avoid permission issues if bundles are unpacked on unix platforms.
$(MSVCR_TARGET): $(MSVCR_DLL) $(MSVCR_TARGET): $(MSVCR_DLL)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) a+rx $@ $(CHMOD) a+rx $@
COPY_FILES += $(MSVCR_TARGET) COPY_FILES += $(MSVCR_TARGET)
...@@ -292,9 +262,7 @@ endif ...@@ -292,9 +262,7 @@ endif
HPROF_SRC=$(JDK_TOPDIR)/src/share/demo/jvmti/hprof/jvm.hprof.txt HPROF_SRC=$(JDK_TOPDIR)/src/share/demo/jvmti/hprof/jvm.hprof.txt
$(LIBDIR)/jvm.hprof.txt : $(HPROF_SRC) $(LIBDIR)/jvm.hprof.txt : $(HPROF_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(LIBDIR)/jvm.hprof.txt COPY_FILES += $(LIBDIR)/jvm.hprof.txt
...@@ -351,17 +319,13 @@ ifeq ($(OPENJDK_TARGET_CPU_BITS),32) ...@@ -351,17 +319,13 @@ ifeq ($(OPENJDK_TARGET_CPU_BITS),32)
else else
# Use the default jvm.cfg for this 32 bit setup. # Use the default jvm.cfg for this 32 bit setup.
$(JVMCFG): $(JVMCFG_SRC) $(JVMCFG): $(JVMCFG_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
endif endif
endif endif
else else
# Use the default jvm.cfg for this 64 bit setup. # Use the default jvm.cfg for this 64 bit setup.
$(JVMCFG): $(JVMCFG_SRC) $(JVMCFG): $(JVMCFG_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
endif endif
COPY_FILES += $(JVMCFG) COPY_FILES += $(JVMCFG)
...@@ -372,9 +336,7 @@ PROPS_SRC := $(JDK_TOPDIR)/src/share/lib/security/java.security-$(OPENJDK_TARGET ...@@ -372,9 +336,7 @@ PROPS_SRC := $(JDK_TOPDIR)/src/share/lib/security/java.security-$(OPENJDK_TARGET
PROPS_DST := $(JDK_OUTPUTDIR)/lib/security/java.security PROPS_DST := $(JDK_OUTPUTDIR)/lib/security/java.security
$(PROPS_DST): $(PROPS_SRC) $(PROPS_DST): $(PROPS_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(PROPS_DST) COPY_FILES += $(PROPS_DST)
...@@ -384,9 +346,7 @@ POLICY_SRC := $(JDK_TOPDIR)/src/share/lib/security/java.policy ...@@ -384,9 +346,7 @@ POLICY_SRC := $(JDK_TOPDIR)/src/share/lib/security/java.policy
POLICY_DST := $(JDK_OUTPUTDIR)/lib/security/java.policy POLICY_DST := $(JDK_OUTPUTDIR)/lib/security/java.policy
$(POLICY_DST): $(POLICY_SRC) $(POLICY_DST): $(POLICY_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(POLICY_DST) COPY_FILES += $(POLICY_DST)
...@@ -396,9 +356,7 @@ CACERTS_SRC := $(CACERTS_FILE) ...@@ -396,9 +356,7 @@ CACERTS_SRC := $(CACERTS_FILE)
CACERTS_DST := $(JDK_OUTPUTDIR)/lib/security/cacerts CACERTS_DST := $(JDK_OUTPUTDIR)/lib/security/cacerts
$(CACERTS_DST): $(CACERTS_SRC) $(CACERTS_DST): $(CACERTS_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(CACERTS_DST) COPY_FILES += $(CACERTS_DST)
...@@ -413,16 +371,12 @@ TRUSTEDLIBS_SRC := $(JDK_TOPDIR)/src/closed/share/lib/security/trusted.libraries ...@@ -413,16 +371,12 @@ TRUSTEDLIBS_SRC := $(JDK_TOPDIR)/src/closed/share/lib/security/trusted.libraries
TRUSTEDLIBS_DST := $(JDK_OUTPUTDIR)/lib/security/trusted.libraries TRUSTEDLIBS_DST := $(JDK_OUTPUTDIR)/lib/security/trusted.libraries
$(BLACKLIST_DST): $(BLACKLIST_SRC) $(BLACKLIST_DST): $(BLACKLIST_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(BLACKLIST_DST) COPY_FILES += $(BLACKLIST_DST)
$(TRUSTEDLIBS_DST): $(TRUSTEDLIBS_SRC) $(TRUSTEDLIBS_DST): $(TRUSTEDLIBS_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(TRUSTEDLIBS_DST) COPY_FILES += $(TRUSTEDLIBS_DST)
...@@ -448,14 +402,10 @@ SHARED_FONTS_SRC := $(foreach F,$(SHARED_FONTS_FILES),$(SHARED_FONTS_SRC_DIR)/$( ...@@ -448,14 +402,10 @@ SHARED_FONTS_SRC := $(foreach F,$(SHARED_FONTS_FILES),$(SHARED_FONTS_SRC_DIR)/$(
SHARED_FONTS_DST := $(foreach F,$(SHARED_FONTS_FILES),$(SHARED_FONTS_DST_DIR)/$(F)) SHARED_FONTS_DST := $(foreach F,$(SHARED_FONTS_FILES),$(SHARED_FONTS_DST_DIR)/$(F))
$(SHARED_FONTS_DST_DIR)/%.ttf : $(SHARED_FONTS_SRC_DIR)/%.ttf $(SHARED_FONTS_DST_DIR)/%.ttf : $(SHARED_FONTS_SRC_DIR)/%.ttf
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(SHARED_FONTS_DST_DIR)/fonts.dir : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/motif/java.fonts.dir $(SHARED_FONTS_DST_DIR)/fonts.dir : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/motif/java.fonts.dir
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(SHARED_FONTS_DST) COPY_FILES += $(SHARED_FONTS_DST)
...@@ -476,14 +426,10 @@ OBL_FONTS_SRC := $(foreach F,$(OBL_FONTS_FILES),$(OBL_FONTS_SRC_DIR)/$(F)) ...@@ -476,14 +426,10 @@ OBL_FONTS_SRC := $(foreach F,$(OBL_FONTS_FILES),$(OBL_FONTS_SRC_DIR)/$(F))
OBL_FONTS_DST := $(foreach F,$(OBL_FONTS_FILES),$(OBL_FONTS_DST_DIR)/$(F)) OBL_FONTS_DST := $(foreach F,$(OBL_FONTS_FILES),$(OBL_FONTS_DST_DIR)/$(F))
$(OBL_FONTS_DST_DIR)/%.ttf : $(OBL_FONTS_SRC_DIR)/%.ttf $(OBL_FONTS_DST_DIR)/%.ttf : $(OBL_FONTS_SRC_DIR)/%.ttf
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(OBL_FONTS_DST_DIR)/fonts.dir : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/motif/java.oblique-fonts.dir $(OBL_FONTS_DST_DIR)/fonts.dir : $(JDK_TOPDIR)/src/solaris/classes/sun/awt/motif/java.oblique-fonts.dir
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(OBL_FONTS_DST) $(OBL_FONTS_DST_DIR)/fonts.dir COPY_FILES += $(OBL_FONTS_DST) $(OBL_FONTS_DST_DIR)/fonts.dir
...@@ -502,9 +448,7 @@ JS_RESOURCES_SRC := $(foreach F,$(JS_RESOURCES_FILES),$(JS_RESOURCES_SRC_DIR)/$( ...@@ -502,9 +448,7 @@ JS_RESOURCES_SRC := $(foreach F,$(JS_RESOURCES_FILES),$(JS_RESOURCES_SRC_DIR)/$(
JS_RESOURCES_DST := $(foreach F,$(JS_RESOURCES_FILES),$(JS_RESOURCES_DST_DIR)/$(F)) JS_RESOURCES_DST := $(foreach F,$(JS_RESOURCES_FILES),$(JS_RESOURCES_DST_DIR)/$(F))
$(JS_RESOURCES_DST_DIR)/% : $(JS_RESOURCES_SRC_DIR)/% $(JS_RESOURCES_DST_DIR)/% : $(JS_RESOURCES_SRC_DIR)/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(JS_RESOURCES_DST) COPY_FILES += $(JS_RESOURCES_DST)
...@@ -539,15 +483,11 @@ _DGALIBS_amd64 = # no amd64 library yet ...@@ -539,15 +483,11 @@ _DGALIBS_amd64 = # no amd64 library yet
DGALIBS = $(_DGALIBS_$(OPENJDK_TARGET_CPU_LEGACY):%=$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/%) DGALIBS = $(_DGALIBS_$(OPENJDK_TARGET_CPU_LEGACY):%=$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/%)
$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libxinerama.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(OPENJDK_TARGET_CPU_LEGACY)/libxinerama.so $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libxinerama.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(OPENJDK_TARGET_CPU_LEGACY)/libxinerama.so
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) 755 $@ $(CHMOD) 755 $@
$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNW%.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(OPENJDK_TARGET_CPU_LEGACY)/libjdgaSUNW%.so $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNW%.so: $(JDK_TOPDIR)/src/closed/solaris/lib/$(OPENJDK_TARGET_CPU_LEGACY)/libjdgaSUNW%.so
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(CHMOD) 755 $@ $(CHMOD) 755 $@
$(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNWafb.so: $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNWffb.so $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNWafb.so: $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/libjdgaSUNWffb.so
...@@ -567,9 +507,7 @@ SUNPKCS11_CFG_SRC := $(JDK_TOPDIR)/src/share/lib/security/sunpkcs11-solaris.cfg ...@@ -567,9 +507,7 @@ SUNPKCS11_CFG_SRC := $(JDK_TOPDIR)/src/share/lib/security/sunpkcs11-solaris.cfg
SUNPKCS11_CFG_DST := $(JDK_OUTPUTDIR)/lib/security/sunpkcs11-solaris.cfg SUNPKCS11_CFG_DST := $(JDK_OUTPUTDIR)/lib/security/sunpkcs11-solaris.cfg
$(SUNPKCS11_CFG_DST) : $(SUNPKCS11_CFG_SRC) $(SUNPKCS11_CFG_DST) : $(SUNPKCS11_CFG_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(SUNPKCS11_CFG_DST) COPY_FILES += $(SUNPKCS11_CFG_DST)
...@@ -584,9 +522,7 @@ UCRYPTO_CFG_SRC := $(JDK_TOPDIR)/src/closed/share/lib/security/ucrypto-solaris.c ...@@ -584,9 +522,7 @@ UCRYPTO_CFG_SRC := $(JDK_TOPDIR)/src/closed/share/lib/security/ucrypto-solaris.c
UCRYPTO_CFG_DST := $(JDK_OUTPUTDIR)/lib/security/ucrypto-solaris.cfg UCRYPTO_CFG_DST := $(JDK_OUTPUTDIR)/lib/security/ucrypto-solaris.cfg
$(UCRYPTO_CFG_DST) : $(UCRYPTO_CFG_SRC) $(UCRYPTO_CFG_DST) : $(UCRYPTO_CFG_SRC)
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(UCRYPTO_CFG_DST) COPY_FILES += $(UCRYPTO_CFG_DST)
...@@ -596,9 +532,7 @@ endif ...@@ -596,9 +532,7 @@ endif
########################################################################################## ##########################################################################################
$(JDK_OUTPUTDIR)/lib/sound.properties : $(JDK_TOPDIR)/src/share/lib/sound.properties $(JDK_OUTPUTDIR)/lib/sound.properties : $(JDK_TOPDIR)/src/share/lib/sound.properties
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $(@)
COPY_FILES += $(JDK_OUTPUTDIR)/lib/sound.properties COPY_FILES += $(JDK_OUTPUTDIR)/lib/sound.properties
......
...@@ -223,9 +223,7 @@ COPY_EXTRA += $(OUT_SERVICES_FILES_PRINT) ...@@ -223,9 +223,7 @@ COPY_EXTRA += $(OUT_SERVICES_FILES_PRINT)
### ###
$(JDK_OUTPUTDIR)/classes/sun/nio/cs/ext/sjis0213.dat : $(JDK_OUTPUTDIR)/gensrc/sun/nio/cs/ext/sjis0213.dat $(JDK_OUTPUTDIR)/classes/sun/nio/cs/ext/sjis0213.dat : $(JDK_OUTPUTDIR)/gensrc/sun/nio/cs/ext/sjis0213.dat
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $(@)
COPY_EXTRA += $(JDK_OUTPUTDIR)/classes/sun/nio/cs/ext/sjis0213.dat COPY_EXTRA += $(JDK_OUTPUTDIR)/classes/sun/nio/cs/ext/sjis0213.dat
......
...@@ -53,19 +53,13 @@ ifneq (, $(filter $(OPENJDK_TARGET_OS), solaris macosx)) ...@@ -53,19 +53,13 @@ ifneq (, $(filter $(OPENJDK_TARGET_OS), solaris macosx))
endif endif
$(SAMPLE_TARGET_DIR)/dtrace/%: $(SAMPLE_SOLARIS_SOURCE_DIR)/dtrace/% $(SAMPLE_TARGET_DIR)/dtrace/%: $(SAMPLE_SOLARIS_SOURCE_DIR)/dtrace/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(SAMPLE_TARGET_DIR)/webservices/%: $(SAMPLE_CLOSED_SOURCE_DIR)/webservices/% $(SAMPLE_TARGET_DIR)/webservices/%: $(SAMPLE_CLOSED_SOURCE_DIR)/webservices/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
$(SAMPLE_TARGET_DIR)/%: $(SAMPLE_SOURCE_DIR)/% $(SAMPLE_TARGET_DIR)/%: $(SAMPLE_SOURCE_DIR)/%
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
COPY_FILES += $(SAMPLE_TARGET) COPY_FILES += $(SAMPLE_TARGET)
......
...@@ -72,9 +72,7 @@ endif ...@@ -72,9 +72,7 @@ endif
$(GENDATA_FONT_CONFIG_DST)/%.src : \ $(GENDATA_FONT_CONFIG_DST)/%.src : \
$(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)% $(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)%
$(RM) $@ $(call install-file)
$(MKDIR) -p $(@D)
$(CP) $< $@
$(GENDATA_FONT_CONFIG_DST)/%.bfc : \ $(GENDATA_FONT_CONFIG_DST)/%.bfc : \
$(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)%.properties $(GENDATA_FONT_CONFIG_SRC_DIR)/$(GENDATA_FONT_CONFIG_SRC_PREFIX)%.properties
......
...@@ -55,9 +55,8 @@ $(eval $(call SetupCharacterData,CharacterData0E,-plane 14,11 4 1)) ...@@ -55,9 +55,8 @@ $(eval $(call SetupCharacterData,CharacterData0E,-plane 14,11 4 1))
# Copy two Java files that need no preprocessing. # Copy two Java files that need no preprocessing.
$(JDK_OUTPUTDIR)/gensrc/java/lang/%.java : $(CHARACTERDATA)/%.java.template $(JDK_OUTPUTDIR)/gensrc/java/lang/%.java : $(CHARACTERDATA)/%.java.template
$(MKDIR) -p $(@D)
$(ECHO) $(LOG_INFO) Generating $(@F) $(ECHO) $(LOG_INFO) Generating $(@F)
$(CP) -f $< $@ $(call install-file)
GENSRC_CHARACTERDATA += $(JDK_OUTPUTDIR)/gensrc/java/lang/CharacterDataUndefined.java \ GENSRC_CHARACTERDATA += $(JDK_OUTPUTDIR)/gensrc/java/lang/CharacterDataUndefined.java \
$(JDK_OUTPUTDIR)/gensrc/java/lang/CharacterDataPrivateUse.java $(JDK_OUTPUTDIR)/gensrc/java/lang/CharacterDataPrivateUse.java
......
...@@ -72,9 +72,8 @@ ifeq ($(OPENJDK_TARGET_OS_API),posix) ...@@ -72,9 +72,8 @@ ifeq ($(OPENJDK_TARGET_OS_API),posix)
$(JDK_OUTPUTDIR)/gensrc/java/lang/UNIXProcess.java : \ $(JDK_OUTPUTDIR)/gensrc/java/lang/UNIXProcess.java : \
$(JDK_TOPDIR)/src/solaris/classes/java/lang/UNIXProcess.java.$(UPSUFFIX) $(JDK_TOPDIR)/src/solaris/classes/java/lang/UNIXProcess.java.$(UPSUFFIX)
$(MKDIR) -p $(@D)
$(ECHO) $(LOG_INFO) Copying UNIXProcess.java.$(OPENJDK_TARGET_OS) to java/lang/UNIXProcess.java $(ECHO) $(LOG_INFO) Copying UNIXProcess.java.$(OPENJDK_TARGET_OS) to java/lang/UNIXProcess.java
$(CP) $< $@ $(call install-file)
$(CHMOD) u+rw $@ $(CHMOD) u+rw $@
GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc/java/lang/UNIXProcess.java GENSRC_MISC += $(JDK_OUTPUTDIR)/gensrc/java/lang/UNIXProcess.java
...@@ -114,9 +113,7 @@ $(JDK_OUTPUTDIR)/gensrc/sun/nio/ch/SocketOptionRegistry.java : $(BUILD_GENSRC_SO ...@@ -114,9 +113,7 @@ $(JDK_OUTPUTDIR)/gensrc/sun/nio/ch/SocketOptionRegistry.java : $(BUILD_GENSRC_SO
$(MV) $@.tmp $@ $(MV) $@.tmp $@
else else
$(JDK_OUTPUTDIR)/gensrc/sun/nio/ch/SocketOptionRegistry.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/ch/SocketOptionRegistry-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java $(JDK_OUTPUTDIR)/gensrc/sun/nio/ch/SocketOptionRegistry.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/ch/SocketOptionRegistry-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
endif endif
########################################################################################## ##########################################################################################
...@@ -156,9 +153,7 @@ $(JDK_OUTPUTDIR)/gensrc/sun/nio/fs/UnixConstants.java : $(BUILD_GENSRC_UC_EXE) ...@@ -156,9 +153,7 @@ $(JDK_OUTPUTDIR)/gensrc/sun/nio/fs/UnixConstants.java : $(BUILD_GENSRC_UC_EXE)
$(MV) $@.tmp $@ $(MV) $@.tmp $@
else else
$(JDK_OUTPUTDIR)/gensrc/sun/nio/fs/UnixConstants.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/fs/UnixConstants-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java $(JDK_OUTPUTDIR)/gensrc/sun/nio/fs/UnixConstants.java : $(JDK_TOPDIR)/src/closed/solaris/classes/sun/nio/fs/UnixConstants-$(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_ARCH).java
$(MKDIR) -p $(@D) $(call install-file)
$(RM) $@
$(CP) $< $@
endif endif
endif endif
......
...@@ -85,14 +85,12 @@ $(JDK_OUTPUTDIR)/gensrc_no_srczip/_the.generated_beaninfo: $(BEANS_SRC) $(JDK_OU ...@@ -85,14 +85,12 @@ $(JDK_OUTPUTDIR)/gensrc_no_srczip/_the.generated_beaninfo: $(BEANS_SRC) $(JDK_OU
# For some reason it is under $(JDK_TOPDIR)/make/tools/swing-beans/javax/swing # For some reason it is under $(JDK_TOPDIR)/make/tools/swing-beans/javax/swing
# Should it be moved under $(JDK_TOPDIR)/src/share/classes/javax/swing instead? # Should it be moved under $(JDK_TOPDIR)/src/share/classes/javax/swing instead?
$(JDK_OUTPUTDIR)/gensrc_no_srczip/javax/swing/SwingBeanInfoBase.java: $(DOCLETSRC_DIR)/javax/swing/SwingBeanInfoBase.java $(JDK_OUTPUTDIR)/gensrc_no_srczip/javax/swing/SwingBeanInfoBase.java: $(DOCLETSRC_DIR)/javax/swing/SwingBeanInfoBase.java
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
# This file is the part of dt.jar # This file is the part of dt.jar
# For some reason it is under $(JDK_TOPDIR)/make/tools/swing-beans/sun/swing # For some reason it is under $(JDK_TOPDIR)/make/tools/swing-beans/sun/swing
# Should it be moved under $(JDK_TOPDIR)/src/share/classes/sun/swing instead? # Should it be moved under $(JDK_TOPDIR)/src/share/classes/sun/swing instead?
$(JDK_OUTPUTDIR)/gensrc/sun/swing/BeanInfoUtils.java: $(DOCLETSRC_DIR)/sun/swing/BeanInfoUtils.java $(JDK_OUTPUTDIR)/gensrc/sun/swing/BeanInfoUtils.java: $(DOCLETSRC_DIR)/sun/swing/BeanInfoUtils.java
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
GENSRC_SWING_BEANINFO = $(JDK_OUTPUTDIR)/gensrc_no_srczip/_the.generated_beaninfo GENSRC_SWING_BEANINFO = $(JDK_OUTPUTDIR)/gensrc_no_srczip/_the.generated_beaninfo
...@@ -649,7 +649,7 @@ ifneq ($(POST_STRIP_CMD),) ...@@ -649,7 +649,7 @@ ifneq ($(POST_STRIP_CMD),)
EXEC_LIST_BIN:=$(filter-out %$(notdir $(MSVCR_DLL)),$(filter %.exe %.dll,$(ALL_BIN_LIST))) EXEC_LIST_BIN:=$(filter-out %$(notdir $(MSVCR_DLL)),$(filter %.exe %.dll,$(ALL_BIN_LIST)))
else else
# Find all executables in JDK_OUTPUTDIR since they exist when this makefile is parsed # Find all executables in JDK_OUTPUTDIR since they exist when this makefile is parsed
EXEC_LIST_BIN:=$(shell $(FILE) `$(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*$(EXE_SUFFIX)` \ EXEC_LIST_BIN:=$(shell $(FILE) `$(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*$(EXE_SUFFIX) ! -name \*.debuginfo` \
| $(EGREP) 'ELF' | $(CUT) -d':' -f1) | $(EGREP) 'ELF' | $(CUT) -d':' -f1)
# On mac, the old build searches for static libraries for stripping instead of shared. # On mac, the old build searches for static libraries for stripping instead of shared.
# Not clear if it's intentional. # Not clear if it's intentional.
......
...@@ -93,8 +93,11 @@ ALL_JARS := $(FULL_JRE_JARS) \ ...@@ -93,8 +93,11 @@ ALL_JARS := $(FULL_JRE_JARS) \
$(IMAGES_OUTPUTDIR)/lib/dt.jar \ $(IMAGES_OUTPUTDIR)/lib/dt.jar \
$(IMAGES_OUTPUTDIR)/lib/tools.jar \ $(IMAGES_OUTPUTDIR)/lib/tools.jar \
$(IMAGES_OUTPUTDIR)/lib/ct.sym \ $(IMAGES_OUTPUTDIR)/lib/ct.sym \
$(IMAGES_OUTPUTDIR)/src.zip \ $(IMAGES_OUTPUTDIR)/src.zip
$(IMAGES_OUTPUTDIR)/lib/sa-jdi.jar
ifeq ($(INCLUDE_SA),true)
ALL_JARS += $(IMAGES_OUTPUTDIR)/lib/sa-jdi.jar
endif
ifeq ($(OPENJDK_TARGET_OS),solaris) ifeq ($(OPENJDK_TARGET_OS),solaris)
ifndef OPENJDK ifndef OPENJDK
......
...@@ -79,8 +79,7 @@ check-keystore: ...@@ -79,8 +79,7 @@ check-keystore:
fi fi
$(JCE_OUTPUTDIR)/%: $(IMAGES_OUTPUTDIR)/unsigned/% $(JCE_OUTPUTDIR)/%: $(IMAGES_OUTPUTDIR)/unsigned/%
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
$(JARSIGNER) -keystore $(SIGNING_KEYSTORE) \ $(JARSIGNER) -keystore $(SIGNING_KEYSTORE) \
$@ $(SIGNING_ALIAS) < $(SIGNING_PASSPHRASE) $@ $(SIGNING_ALIAS) < $(SIGNING_PASSPHRASE)
@$(PRINTF) "\nJar codesigning finished.\n" @$(PRINTF) "\nJar codesigning finished.\n"
......
...@@ -47,17 +47,15 @@ $(eval $(call SetupJavaCompilation,BUILD_TOOLS,\ ...@@ -47,17 +47,15 @@ $(eval $(call SetupJavaCompilation,BUILD_TOOLS,\
endif endif
$(JDK_OUTPUTDIR)/btclasses/build/tools/generatenimbus/resources/%.template : \ $(JDK_OUTPUTDIR)/btclasses/build/tools/generatenimbus/resources/%.template : \
$(JDK_TOPDIR)/src/share/classes/javax/swing/plaf/nimbus/%.template $(JDK_TOPDIR)/src/share/classes/javax/swing/plaf/nimbus/%.template
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
BUILD_TOOLS += $(foreach i,$(wildcard $(JDK_TOPDIR)/src/share/classes/javax/swing/plaf/nimbus/*.template),$(JDK_OUTPUTDIR)/btclasses/build/tools/generatenimbus/resources/$(notdir $i)) BUILD_TOOLS += $(foreach i,$(wildcard $(JDK_TOPDIR)/src/share/classes/javax/swing/plaf/nimbus/*.template),$(JDK_OUTPUTDIR)/btclasses/build/tools/generatenimbus/resources/$(notdir $i))
# Resources used by CheckDeps tool # Resources used by CheckDeps tool
$(JDK_OUTPUTDIR)/btclasses/build/tools/deps/% : \ $(JDK_OUTPUTDIR)/btclasses/build/tools/deps/% : \
$(JDK_TOPDIR)/make/tools/src/build/tools/deps/% $(JDK_TOPDIR)/make/tools/src/build/tools/deps/%
$(MKDIR) -p $(@D) $(call install-file)
$(CP) $< $@
BUILD_TOOLS += $(JDK_OUTPUTDIR)/btclasses/build/tools/deps/refs.allowed BUILD_TOOLS += $(JDK_OUTPUTDIR)/btclasses/build/tools/deps/refs.allowed
......
/* /*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -33,17 +33,15 @@ import javax.swing.RootPaneContainer; ...@@ -33,17 +33,15 @@ import javax.swing.RootPaneContainer;
import com.apple.eawt.AppEvent.FullScreenEvent; import com.apple.eawt.AppEvent.FullScreenEvent;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
final class FullScreenHandler { final class FullScreenHandler {
private static final String CLIENT_PROPERTY = "com.apple.eawt.event.internalFullScreenHandler"; private static final String CLIENT_PROPERTY = "com.apple.eawt.event.internalFullScreenHandler";
static final int FULLSCREEN_WILL_ENTER = 1; @Native static final int FULLSCREEN_WILL_ENTER = 1;
static final int FULLSCREEN_DID_ENTER = 2; @Native static final int FULLSCREEN_DID_ENTER = 2;
static final int FULLSCREEN_WILL_EXIT = 3; @Native static final int FULLSCREEN_WILL_EXIT = 3;
static final int FULLSCREEN_DID_EXIT = 4; @Native static final int FULLSCREEN_DID_EXIT = 4;
// installs a private instance of the handler, if necessary // installs a private instance of the handler, if necessary
static void addFullScreenListenerTo(final RootPaneContainer window, final FullScreenListener listener) { static void addFullScreenListenerTo(final RootPaneContainer window, final FullScreenListener listener) {
......
/* /*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -31,18 +31,16 @@ import java.util.List; ...@@ -31,18 +31,16 @@ import java.util.List;
import javax.swing.*; import javax.swing.*;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
final class GestureHandler { final class GestureHandler {
private static final String CLIENT_PROPERTY = "com.apple.eawt.event.internalGestureHandler"; private static final String CLIENT_PROPERTY = "com.apple.eawt.event.internalGestureHandler";
// native constants for the supported types of high-level gestures // native constants for the supported types of high-level gestures
static final int PHASE = 1; @Native static final int PHASE = 1;
static final int ROTATE = 2; @Native static final int ROTATE = 2;
static final int MAGNIFY = 3; @Native static final int MAGNIFY = 3;
static final int SWIPE = 4; @Native static final int SWIPE = 4;
// installs a private instance of GestureHandler, if necessary // installs a private instance of GestureHandler, if necessary
static void addGestureListenerTo(final JComponent component, final GestureListener listener) { static void addGestureListenerTo(final JComponent component, final GestureListener listener) {
......
/* /*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -37,13 +37,11 @@ import sun.java2d.loops.*; ...@@ -37,13 +37,11 @@ import sun.java2d.loops.*;
import sun.java2d.pipe.*; import sun.java2d.pipe.*;
import sun.lwawt.macosx.*; import sun.lwawt.macosx.*;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/* /*
* This is the SurfaceData for a CGContextRef. * This is the SurfaceData for a CGContextRef.
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class OSXSurfaceData extends BufImgSurfaceData { public abstract class OSXSurfaceData extends BufImgSurfaceData {
final static float UPPER_BND = Float.MAX_VALUE / 2.0f; final static float UPPER_BND = Float.MAX_VALUE / 2.0f;
final static float LOWER_BND = -UPPER_BND; final static float LOWER_BND = -UPPER_BND;
...@@ -198,147 +196,147 @@ public abstract class OSXSurfaceData extends BufImgSurfaceData { ...@@ -198,147 +196,147 @@ public abstract class OSXSurfaceData extends BufImgSurfaceData {
// graphics primitives drawing implementation: // graphics primitives drawing implementation:
// certain primitives don't care about all the states (ex. drawing an image needs not involve setting current paint) // certain primitives don't care about all the states (ex. drawing an image needs not involve setting current paint)
static final int kPrimitive = 0; @Native static final int kPrimitive = 0;
static final int kImage = 1; @Native static final int kImage = 1;
static final int kText = 2; @Native static final int kText = 2;
static final int kCopyArea = 3; @Native static final int kCopyArea = 3;
static final int kExternal = 4; @Native static final int kExternal = 4;
static final int kLine = 5; // belongs to kPrimitive @Native static final int kLine = 5; // belongs to kPrimitive
static final int kRect = 6; // belongs to kPrimitive @Native static final int kRect = 6; // belongs to kPrimitive
static final int kRoundRect = 7; // belongs to kPrimitive @Native static final int kRoundRect = 7; // belongs to kPrimitive
static final int kOval = 8; // belongs to kPrimitive @Native static final int kOval = 8; // belongs to kPrimitive
static final int kArc = 9; // belongs to kPrimitive @Native static final int kArc = 9; // belongs to kPrimitive
static final int kPolygon = 10; // belongs to kPrimitive @Native static final int kPolygon = 10; // belongs to kPrimitive
static final int kShape = 11; // belongs to kPrimitive @Native static final int kShape = 11; // belongs to kPrimitive
// static final int kImage = 12; // belongs to kImage // static final int kImage = 12; // belongs to kImage
static final int kString = 13; // belongs to kText @Native static final int kString = 13; // belongs to kText
static final int kGlyphs = 14; // belongs to kText @Native static final int kGlyphs = 14; // belongs to kText
static final int kUnicodes = 15; // belongs to kText @Native static final int kUnicodes = 15; // belongs to kText
// static final int kCopyArea = 16; // belongs to kCopyArea // static final int kCopyArea = 16; // belongs to kCopyArea
// static final int kExternal = 17; // belongs to kExternal // static final int kExternal = 17; // belongs to kExternal
static final int kCommonParameterCount = 1 + 1 + 4 + 4; // type + change flags + color info (type(1) align(1) and @Native static final int kCommonParameterCount = 1 + 1 + 4 + 4; // type + change flags + color info (type(1) align(1) and
// value(2)) + parameters ((x1, y1, x2, y2) OR (x, y, w, h)) // value(2)) + parameters ((x1, y1, x2, y2) OR (x, y, w, h))
static final int kLineParametersCount = kCommonParameterCount; // kCommonParameterCount @Native static final int kLineParametersCount = kCommonParameterCount; // kCommonParameterCount
static final int kRectParametersCount = kCommonParameterCount + 1; // kCommonParameterCount + isfill @Native static final int kRectParametersCount = kCommonParameterCount + 1; // kCommonParameterCount + isfill
static final int kRoundRectParametersCount = kCommonParameterCount + 2 + 1; // kCommonParameterCount + arcW + arcH + @Native static final int kRoundRectParametersCount = kCommonParameterCount + 2 + 1; // kCommonParameterCount + arcW + arcH +
// isfill // isfill
static final int kOvalParametersCount = kCommonParameterCount + 1; // kCommonParameterCount + isfill @Native static final int kOvalParametersCount = kCommonParameterCount + 1; // kCommonParameterCount + isfill
static final int kArcParametersCount = kCommonParameterCount + 2 + 1 + 1;// kCommonParameterCount + startAngle + @Native static final int kArcParametersCount = kCommonParameterCount + 2 + 1 + 1;// kCommonParameterCount + startAngle +
// arcAngle + isfill + type // arcAngle + isfill + type
static final int kPolygonParametersCount = 0; // not supported @Native static final int kPolygonParametersCount = 0; // not supported
static final int kShapeParametersCount = 0; // not supported @Native static final int kShapeParametersCount = 0; // not supported
static final int kImageParametersCount = kCommonParameterCount + 2 + 2 + 4 + 4; // flip horz vert + w&h + src + dst @Native static final int kImageParametersCount = kCommonParameterCount + 2 + 2 + 4 + 4; // flip horz vert + w&h + src + dst
static final int kStringParametersCount = 0; // not supported @Native static final int kStringParametersCount = 0; // not supported
static final int kGlyphsParametersCount = 0; // not supported @Native static final int kGlyphsParametersCount = 0; // not supported
static final int kUnicodesParametersCount = 0; // not supported @Native static final int kUnicodesParametersCount = 0; // not supported
static final int kPixelParametersCount = 0; // not supported @Native static final int kPixelParametersCount = 0; // not supported
static final int kExternalParametersCount = 0; // not supported @Native static final int kExternalParametersCount = 0; // not supported
// for intParameters // for intParameters
// states info // states info
static final int kChangeFlagIndex = 0; // kBoundsChangedBit | .. | kFontChangedBit @Native static final int kChangeFlagIndex = 0; // kBoundsChangedBit | .. | kFontChangedBit
// bounds info // bounds info
static final int kBoundsXIndex = 1; @Native static final int kBoundsXIndex = 1;
static final int kBoundsYIndex = 2; @Native static final int kBoundsYIndex = 2;
static final int kBoundsWidthIndex = 3; @Native static final int kBoundsWidthIndex = 3;
static final int kBoundsHeightIndex = 4; @Native static final int kBoundsHeightIndex = 4;
// clip info // clip info
static final int kClipStateIndex = 5; @Native static final int kClipStateIndex = 5;
static final int kClipNumTypesIndex = 6; @Native static final int kClipNumTypesIndex = 6;
static final int kClipNumCoordsIndex = 7; @Native static final int kClipNumCoordsIndex = 7;
static final int kClipWindingRuleIndex = 8; @Native static final int kClipWindingRuleIndex = 8;
static final int kClipXIndex = 9; @Native static final int kClipXIndex = 9;
static final int kClipYIndex = 10; @Native static final int kClipYIndex = 10;
static final int kClipWidthIndex = 11; @Native static final int kClipWidthIndex = 11;
static final int kClipHeightIndex = 12; @Native static final int kClipHeightIndex = 12;
// ctm info // ctm info
static final int kCTMaIndex = 13; @Native static final int kCTMaIndex = 13;
static final int kCTMbIndex = 14; @Native static final int kCTMbIndex = 14;
static final int kCTMcIndex = 15; @Native static final int kCTMcIndex = 15;
static final int kCTMdIndex = 16; @Native static final int kCTMdIndex = 16;
static final int kCTMtxIndex = 17; @Native static final int kCTMtxIndex = 17;
static final int kCTMtyIndex = 18; @Native static final int kCTMtyIndex = 18;
// color info // color info
static final int kColorStateIndex = 19; // kColorSimple or kColorGradient or kColorTexture @Native static final int kColorStateIndex = 19; // kColorSimple or kColorGradient or kColorTexture
static final int kColorRGBValueIndex = 20; // if kColorSimple @Native static final int kColorRGBValueIndex = 20; // if kColorSimple
static final int kColorIndexValueIndex = 21; // if kColorSystem @Native static final int kColorIndexValueIndex = 21; // if kColorSystem
static final int kColorPointerIndex = 22; // @Native static final int kColorPointerIndex = 22; //
static final int kColorPointerIndex2 = 23; // @Native static final int kColorPointerIndex2 = 23; //
static final int kColorRGBValue1Index = 24; // if kColorGradient @Native static final int kColorRGBValue1Index = 24; // if kColorGradient
static final int kColorWidthIndex = 25; // if kColorTexture @Native static final int kColorWidthIndex = 25; // if kColorTexture
static final int kColorRGBValue2Index = 26; // if kColorGradient @Native static final int kColorRGBValue2Index = 26; // if kColorGradient
static final int kColorHeightIndex = 27; // if kColorTexture @Native static final int kColorHeightIndex = 27; // if kColorTexture
static final int kColorIsCyclicIndex = 28; // if kColorGradient (kColorNonCyclic or kColorCyclic) @Native static final int kColorIsCyclicIndex = 28; // if kColorGradient (kColorNonCyclic or kColorCyclic)
static final int kColorx1Index = 29; @Native static final int kColorx1Index = 29;
static final int kColortxIndex = 30; @Native static final int kColortxIndex = 30;
static final int kColory1Index = 31; @Native static final int kColory1Index = 31;
static final int kColortyIndex = 32; @Native static final int kColortyIndex = 32;
static final int kColorx2Index = 33; @Native static final int kColorx2Index = 33;
static final int kColorsxIndex = 34; @Native static final int kColorsxIndex = 34;
static final int kColory2Index = 35; @Native static final int kColory2Index = 35;
static final int kColorsyIndex = 36; @Native static final int kColorsyIndex = 36;
// composite info // composite info
static final int kCompositeRuleIndex = 37; // kCGCompositeClear or ... or kCGCompositeXor @Native static final int kCompositeRuleIndex = 37; // kCGCompositeClear or ... or kCGCompositeXor
static final int kCompositeValueIndex = 38; @Native static final int kCompositeValueIndex = 38;
// stroke info // stroke info
static final int kStrokeJoinIndex = 39; // see BasicStroke.java @Native static final int kStrokeJoinIndex = 39; // see BasicStroke.java
static final int kStrokeCapIndex = 40; // see BasicStroke.java @Native static final int kStrokeCapIndex = 40; // see BasicStroke.java
static final int kStrokeWidthIndex = 41; @Native static final int kStrokeWidthIndex = 41;
static final int kStrokeDashPhaseIndex = 42; @Native static final int kStrokeDashPhaseIndex = 42;
static final int kStrokeLimitIndex = 43; @Native static final int kStrokeLimitIndex = 43;
// hints info // hints info
static final int kHintsAntialiasIndex = 44; @Native static final int kHintsAntialiasIndex = 44;
static final int kHintsTextAntialiasIndex = 45; @Native static final int kHintsTextAntialiasIndex = 45;
static final int kHintsFractionalMetricsIndex = 46; @Native static final int kHintsFractionalMetricsIndex = 46;
static final int kHintsRenderingIndex = 47; @Native static final int kHintsRenderingIndex = 47;
static final int kHintsInterpolationIndex = 48; @Native static final int kHintsInterpolationIndex = 48;
// live resizing info // live resizing info
static final int kCanDrawDuringLiveResizeIndex = 49; @Native static final int kCanDrawDuringLiveResizeIndex = 49;
static final int kSizeOfParameters = kCanDrawDuringLiveResizeIndex + 1; @Native static final int kSizeOfParameters = kCanDrawDuringLiveResizeIndex + 1;
// for objectParameters // for objectParameters
static final int kClipCoordinatesIndex = 0; @Native static final int kClipCoordinatesIndex = 0;
static final int kClipTypesIndex = 1; @Native static final int kClipTypesIndex = 1;
static final int kTextureImageIndex = 2; @Native static final int kTextureImageIndex = 2;
static final int kStrokeDashArrayIndex = 3; @Native static final int kStrokeDashArrayIndex = 3;
static final int kFontIndex = 4; @Native static final int kFontIndex = 4;
static final int kFontPaintIndex = 5; @Native static final int kFontPaintIndex = 5;
// possible state changes // possible state changes
static final int kBoundsChangedBit = 1 << 0; @Native static final int kBoundsChangedBit = 1 << 0;
static final int kBoundsNotChangedBit = ~kBoundsChangedBit; @Native static final int kBoundsNotChangedBit = ~kBoundsChangedBit;
static final int kClipChangedBit = 1 << 1; @Native static final int kClipChangedBit = 1 << 1;
static final int kClipNotChangedBit = ~kClipChangedBit; @Native static final int kClipNotChangedBit = ~kClipChangedBit;
static final int kCTMChangedBit = 1 << 2; @Native static final int kCTMChangedBit = 1 << 2;
static final int kCTMNotChangedBit = ~kCTMChangedBit; @Native static final int kCTMNotChangedBit = ~kCTMChangedBit;
static final int kColorChangedBit = 1 << 3; @Native static final int kColorChangedBit = 1 << 3;
static final int kColorNotChangedBit = ~kColorChangedBit; @Native static final int kColorNotChangedBit = ~kColorChangedBit;
static final int kCompositeChangedBit = 1 << 4; @Native static final int kCompositeChangedBit = 1 << 4;
static final int kCompositeNotChangedBit = ~kCompositeChangedBit; @Native static final int kCompositeNotChangedBit = ~kCompositeChangedBit;
static final int kStrokeChangedBit = 1 << 5; @Native static final int kStrokeChangedBit = 1 << 5;
static final int kStrokeNotChangedBit = ~kStrokeChangedBit; @Native static final int kStrokeNotChangedBit = ~kStrokeChangedBit;
static final int kHintsChangedBit = 1 << 6; @Native static final int kHintsChangedBit = 1 << 6;
static final int kHintsNotChangedBit = ~kHintsChangedBit; @Native static final int kHintsNotChangedBit = ~kHintsChangedBit;
static final int kFontChangedBit = 1 << 7; @Native static final int kFontChangedBit = 1 << 7;
static final int kFontNotChangedBit = ~kFontChangedBit; @Native static final int kFontNotChangedBit = ~kFontChangedBit;
static final int kEverythingChangedFlag = 0xffffffff; @Native static final int kEverythingChangedFlag = 0xffffffff;
// possible color states // possible color states
static final int kColorSimple = 0; @Native static final int kColorSimple = 0;
static final int kColorSystem = 1; @Native static final int kColorSystem = 1;
static final int kColorGradient = 2; @Native static final int kColorGradient = 2;
static final int kColorTexture = 3; @Native static final int kColorTexture = 3;
// possible gradient color states // possible gradient color states
static final int kColorNonCyclic = 0; @Native static final int kColorNonCyclic = 0;
static final int kColorCyclic = 1; @Native static final int kColorCyclic = 1;
// possible clip states // possible clip states
static final int kClipRect = 0; @Native static final int kClipRect = 0;
static final int kClipShape = 1; @Native static final int kClipShape = 1;
static int getRendererTypeForPrimitive(int primitiveType) { static int getRendererTypeForPrimitive(int primitiveType) {
switch (primitiveType) { switch (primitiveType) {
......
/* /*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,10 +25,7 @@ ...@@ -25,10 +25,7 @@
package sun.lwawt.macosx; package sun.lwawt.macosx;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class CocoaConstants { public final class CocoaConstants {
private CocoaConstants(){} private CocoaConstants(){}
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
{- {-
/* /*
* Copyright (c) 2011,2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -34,7 +34,7 @@ Otherwise, see http://www.haskell.org/ghc/ ...@@ -34,7 +34,7 @@ Otherwise, see http://www.haskell.org/ghc/
import Data.List import Data.List
import Data.Maybe import Data.Maybe
import Char import Data.Char
data Width = W32 | W64 data Width = W32 | W64
deriving (Show, Eq, Bounded, Enum) deriving (Show, Eq, Bounded, Enum)
...@@ -196,8 +196,6 @@ sizeofRet nt = ...@@ -196,8 +196,6 @@ sizeofRet nt =
c2java ntype = c2java ntype =
unlines [ unlines [
"// native " ++ ntypeS ++ " -> java " ++ jprimS, "// native " ++ ntypeS ++ " -> java " ++ jprimS,
"/* No native methods here, but the constants are needed in the supporting JNI code */",
"@GenerateNativeHeader",
"public static final class " ++ className ++ " extends PrimitiveCoder<" ++ jclassS ++ ">{", "public static final class " ++ className ++ " extends PrimitiveCoder<" ++ jclassS ++ ">{",
"\tpublic static final " ++ className ++ " INST = new " ++ className ++ "();", "\tpublic static final " ++ className ++ " INST = new " ++ className ++ "();",
"\tpublic " ++ className ++ "(){ super("++ffitypeVal ntype++", \"" ++ [encoding ntype] ++ "\", "++jclassS++".class, "++jprimS++".class); }", "\tpublic " ++ className ++ "(){ super("++ffitypeVal ntype++", \"" ++ [encoding ntype] ++ "\", "++jclassS++".class, "++jprimS++".class); }",
...@@ -248,13 +246,10 @@ main = do ...@@ -248,13 +246,10 @@ main = do
putStrLn "package com.apple.jobjc;" putStrLn "package com.apple.jobjc;"
putStrLn "import com.apple.jobjc.JObjCRuntime.Width;" putStrLn "import com.apple.jobjc.JObjCRuntime.Width;"
putStrLn "import javax.tools.annotation.GenerateNativeHeader;"
putStrLn "// Auto generated by PrimitiveCoder.hs" putStrLn "// Auto generated by PrimitiveCoder.hs"
putStrLn "// Do not edit by hand." putStrLn "// Do not edit by hand."
putStrLn "/* No native methods here, but the constants are needed in the supporting JNI code */"
putStrLn "@GenerateNativeHeader"
putStrLn "public abstract class PrimitiveCoder<T> extends Coder<T>{" putStrLn "public abstract class PrimitiveCoder<T> extends Coder<T>{"
putStrLn "\tpublic PrimitiveCoder(int ffiTypeCode, String objCEncoding, Class jclass, Class jprim){" putStrLn "\tpublic PrimitiveCoder(int ffiTypeCode, String objCEncoding, Class jclass, Class jprim){"
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,10 +24,7 @@ ...@@ -24,10 +24,7 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class CFType extends Pointer<Void> { public class CFType extends Pointer<Void> {
protected CFType(long ptr) { super(ptr); } protected CFType(long ptr) { super(ptr); }
protected CFType(Pointer<?> ptr) { super(ptr.ptr); } protected CFType(Pointer<?> ptr) { super(ptr.ptr); }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -35,7 +35,6 @@ import com.apple.jobjc.PrimitiveCoder.SCharCoder; ...@@ -35,7 +35,6 @@ import com.apple.jobjc.PrimitiveCoder.SCharCoder;
import com.apple.jobjc.PrimitiveCoder.SIntCoder; import com.apple.jobjc.PrimitiveCoder.SIntCoder;
import com.apple.jobjc.PrimitiveCoder.SLongLongCoder; import com.apple.jobjc.PrimitiveCoder.SLongLongCoder;
import com.apple.jobjc.PrimitiveCoder.SShortCoder; import com.apple.jobjc.PrimitiveCoder.SShortCoder;
import javax.tools.annotation.GenerateNativeHeader;
public abstract class Coder<T> { public abstract class Coder<T> {
private static native long getNativeFFITypePtrForCode(final int code); private static native long getNativeFFITypePtrForCode(final int code);
...@@ -143,8 +142,6 @@ public abstract class Coder<T> { ...@@ -143,8 +142,6 @@ public abstract class Coder<T> {
// //
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class VoidCoder extends Coder<Object>{ public static final class VoidCoder extends Coder<Object>{
public static final VoidCoder INST = new VoidCoder(); public static final VoidCoder INST = new VoidCoder();
public VoidCoder(){ super(FFI_VOID, "v", Void.class, void.class); } public VoidCoder(){ super(FFI_VOID, "v", Void.class, void.class); }
...@@ -153,8 +150,6 @@ public abstract class Coder<T> { ...@@ -153,8 +150,6 @@ public abstract class Coder<T> {
@Override public void push(JObjCRuntime runtime, long addr, Object x) { throw new RuntimeException("Trying to push a Void."); } @Override public void push(JObjCRuntime runtime, long addr, Object x) { throw new RuntimeException("Trying to push a Void."); }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class UnknownCoder extends Coder<Object> { public static final class UnknownCoder extends Coder<Object> {
public static final UnknownCoder INST = new UnknownCoder(); public static final UnknownCoder INST = new UnknownCoder();
public UnknownCoder(){ super(-1, "?", null, null); } public UnknownCoder(){ super(-1, "?", null, null); }
...@@ -163,8 +158,6 @@ public abstract class Coder<T> { ...@@ -163,8 +158,6 @@ public abstract class Coder<T> {
@Override public Object pop(JObjCRuntime runtime, long addr) { throw new RuntimeException("Coder not implemented"); } @Override public Object pop(JObjCRuntime runtime, long addr) { throw new RuntimeException("Coder not implemented"); }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class PrimitivePointerCoder extends Coder<Long> { public static final class PrimitivePointerCoder extends Coder<Long> {
public static final PrimitivePointerCoder INST = new PrimitivePointerCoder(); public static final PrimitivePointerCoder INST = new PrimitivePointerCoder();
public PrimitivePointerCoder(){ super(Coder.FFI_PTR, "^?", Long.class, long.class); } public PrimitivePointerCoder(){ super(Coder.FFI_PTR, "^?", Long.class, long.class); }
...@@ -194,8 +187,6 @@ public abstract class Coder<T> { ...@@ -194,8 +187,6 @@ public abstract class Coder<T> {
@Override public void push(JObjCRuntime runtime, long addr, Long x) { push(runtime, addr, (long) x); } @Override public void push(JObjCRuntime runtime, long addr, Long x) { push(runtime, addr, (long) x); }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class PointerCoder extends Coder<Pointer> { public static final class PointerCoder extends Coder<Pointer> {
public static final PointerCoder INST = new PointerCoder(); public static final PointerCoder INST = new PointerCoder();
public PointerCoder(){ super(FFI_PTR, "^?", Pointer.class); } public PointerCoder(){ super(FFI_PTR, "^?", Pointer.class); }
...@@ -209,8 +200,6 @@ public abstract class Coder<T> { ...@@ -209,8 +200,6 @@ public abstract class Coder<T> {
} }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class SELCoder extends Coder<SEL> { public static final class SELCoder extends Coder<SEL> {
public static final SELCoder INST = new SELCoder(); public static final SELCoder INST = new SELCoder();
public SELCoder(){ super(FFI_PTR, ":", SEL.class); } public SELCoder(){ super(FFI_PTR, ":", SEL.class); }
...@@ -224,8 +213,6 @@ public abstract class Coder<T> { ...@@ -224,8 +213,6 @@ public abstract class Coder<T> {
} }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static abstract class StructCoder extends Coder<Struct> { public static abstract class StructCoder extends Coder<Struct> {
private final FFIType ffiType; private final FFIType ffiType;
final int sizeof; final int sizeof;
...@@ -267,8 +254,6 @@ public abstract class Coder<T> { ...@@ -267,8 +254,6 @@ public abstract class Coder<T> {
} }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class IDCoder extends Coder<ID>{ public static final class IDCoder extends Coder<ID>{
public static final IDCoder INST = new IDCoder(); public static final IDCoder INST = new IDCoder();
public IDCoder(){ super(FFI_PTR, "@", ID.class); } public IDCoder(){ super(FFI_PTR, "@", ID.class); }
...@@ -287,8 +272,6 @@ public abstract class Coder<T> { ...@@ -287,8 +272,6 @@ public abstract class Coder<T> {
} }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class NSClassCoder extends Coder<NSClass>{ public static final class NSClassCoder extends Coder<NSClass>{
public static final NSClassCoder INST = new NSClassCoder(); public static final NSClassCoder INST = new NSClassCoder();
public NSClassCoder(){ super(FFI_PTR, "#", NSClass.class); } public NSClassCoder(){ super(FFI_PTR, "#", NSClass.class); }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,10 +26,7 @@ package com.apple.jobjc; ...@@ -26,10 +26,7 @@ package com.apple.jobjc;
import com.apple.jobjc.Coder.PrimitivePointerCoder; import com.apple.jobjc.Coder.PrimitivePointerCoder;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
class FFIType{ class FFIType{
private static native void makeFFIType(long ffi_type_buf, long elements_buf); private static native void makeFFIType(long ffi_type_buf, long elements_buf);
private static native int getFFITypeSizeof(); private static native int getFFITypeSizeof();
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,10 +24,7 @@ ...@@ -24,10 +24,7 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class Function { public class Function {
private static native long getFxnPtrForFunctionName(final String functionName); private static native long getFxnPtrForFunctionName(final String functionName);
private static native long getFxnPtrForFunctionNameAndLib(final long libPtr, final String functionName); private static native long getFxnPtrForFunctionNameAndLib(final long libPtr, final String functionName);
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -29,10 +29,7 @@ import java.lang.reflect.Constructor; ...@@ -29,10 +29,7 @@ import java.lang.reflect.Constructor;
import java.util.LinkedHashMap; import java.util.LinkedHashMap;
import java.util.Map; import java.util.Map;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class ID extends Pointer<Void>{ public class ID extends Pointer<Void>{
static native String getNativeDescription(final long objPtr); static native String getNativeDescription(final long objPtr);
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -30,18 +30,13 @@ import com.apple.jobjc.Coder.PrimitivePointerCoder; ...@@ -30,18 +30,13 @@ import com.apple.jobjc.Coder.PrimitivePointerCoder;
import com.apple.jobjc.Coder.SELCoder; import com.apple.jobjc.Coder.SELCoder;
import com.apple.jobjc.Coder.StructCoder; import com.apple.jobjc.Coder.StructCoder;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class Invoke { public abstract class Invoke {
public abstract void invoke(NativeArgumentBuffer argBuf); public abstract void invoke(NativeArgumentBuffer argBuf);
public abstract void invoke(NativeArgumentBuffer buffer, Struct retvalStruct); public abstract void invoke(NativeArgumentBuffer buffer, Struct retvalStruct);
// //
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class FunCall extends Invoke{ public static final class FunCall extends Invoke{
static native void invoke(long cifPtr, long fxnPtr, long retValPtr, long argsPtr); static native void invoke(long cifPtr, long fxnPtr, long retValPtr, long argsPtr);
...@@ -78,8 +73,6 @@ public abstract class Invoke { ...@@ -78,8 +73,6 @@ public abstract class Invoke {
} }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class MsgSend extends Invoke{ public static final class MsgSend extends Invoke{
static{ System.load("/usr/lib/libobjc.dylib"); } static{ System.load("/usr/lib/libobjc.dylib"); }
...@@ -165,8 +158,6 @@ public abstract class Invoke { ...@@ -165,8 +158,6 @@ public abstract class Invoke {
} }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class MsgSendSuper extends Invoke{ public static final class MsgSendSuper extends Invoke{
static{ System.load("/usr/lib/libobjc.dylib"); } static{ System.load("/usr/lib/libobjc.dylib"); }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -31,16 +31,11 @@ import java.util.List; ...@@ -31,16 +31,11 @@ import java.util.List;
import sun.misc.Unsafe; import sun.misc.Unsafe;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class JObjCRuntime { public final class JObjCRuntime {
static { System.loadLibrary("JObjC"); } static { System.loadLibrary("JObjC"); }
@GenerateNativeHeader
public static enum Arch{ ppc, i386, x86_64 }; public static enum Arch{ ppc, i386, x86_64 };
@GenerateNativeHeader
public static enum Width{ W32, W64 }; public static enum Width{ W32, W64 };
public static final Arch ARCH = getArch(); public static final Arch ARCH = getArch();
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,10 +25,7 @@ ...@@ -25,10 +25,7 @@
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class MacOSXFramework { public class MacOSXFramework {
private static native long retainFramework(final String frameworkName); private static native long retainFramework(final String frameworkName);
private static native void releaseFramework(final long frameworkPtr); private static native void releaseFramework(final long frameworkPtr);
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,13 +27,8 @@ package com.apple.jobjc; ...@@ -27,13 +27,8 @@ package com.apple.jobjc;
import java.lang.ref.WeakReference; import java.lang.ref.WeakReference;
import java.lang.reflect.Constructor; import java.lang.reflect.Constructor;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class NSClass<T extends ID> extends ID { public class NSClass<T extends ID> extends ID {
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static class NSClassNotFoundException extends RuntimeException{ public static class NSClassNotFoundException extends RuntimeException{
public NSClassNotFoundException(String m){ super(m); } public NSClassNotFoundException(String m){ super(m); }
public NSClassNotFoundException(String m, Throwable cause){ super(m, cause); } public NSClassNotFoundException(String m, Throwable cause){ super(m, cause); }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,10 +28,7 @@ import java.nio.ByteOrder; ...@@ -28,10 +28,7 @@ import java.nio.ByteOrder;
import com.apple.jobjc.Coder.PrimitivePointerCoder; import com.apple.jobjc.Coder.PrimitivePointerCoder;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class NativeArgumentBuffer{ public final class NativeArgumentBuffer{
private static final ThreadLocal<NativeArgumentBuffer> threadLocal = new ThreadLocal<NativeArgumentBuffer>(); private static final ThreadLocal<NativeArgumentBuffer> threadLocal = new ThreadLocal<NativeArgumentBuffer>();
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,13 +27,10 @@ package com.apple.jobjc; ...@@ -27,13 +27,10 @@ package com.apple.jobjc;
import java.nio.ByteBuffer; import java.nio.ByteBuffer;
import java.nio.ByteOrder; import java.nio.ByteOrder;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* A wrapper around a direct ByteBuffer and its native pointer. For documentation, @see java.nio.ByteBuffer * A wrapper around a direct ByteBuffer and its native pointer. For documentation, @see java.nio.ByteBuffer
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class NativeBuffer { public class NativeBuffer {
static native long getPtrOfBuffer(final ByteBuffer byteBuffer); static native long getPtrOfBuffer(final ByteBuffer byteBuffer);
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,10 +24,7 @@ ...@@ -24,10 +24,7 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class NativeObjectLifecycleManager { public abstract class NativeObjectLifecycleManager {
private static native void retainNativeObject(final long ptr); private static native void retainNativeObject(final long ptr);
private static native void releaseNativeObject(final long ptr); private static native void releaseNativeObject(final long ptr);
...@@ -37,8 +34,6 @@ public abstract class NativeObjectLifecycleManager { ...@@ -37,8 +34,6 @@ public abstract class NativeObjectLifecycleManager {
abstract void end(final long ptr); abstract void end(final long ptr);
boolean shouldPreRetain() { return false; } boolean shouldPreRetain() { return false; }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static class CFRetainRelease extends NativeObjectLifecycleManager { public static class CFRetainRelease extends NativeObjectLifecycleManager {
public static final NativeObjectLifecycleManager INST = new CFRetainRelease(); public static final NativeObjectLifecycleManager INST = new CFRetainRelease();
@Override void begin(final long ptr) { retainNativeObject(ptr); } @Override void begin(final long ptr) { retainNativeObject(ptr); }
...@@ -46,16 +41,12 @@ public abstract class NativeObjectLifecycleManager { ...@@ -46,16 +41,12 @@ public abstract class NativeObjectLifecycleManager {
@Override boolean shouldPreRetain() { return true; } @Override boolean shouldPreRetain() { return true; }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static class Free extends NativeObjectLifecycleManager { public static class Free extends NativeObjectLifecycleManager {
public static final NativeObjectLifecycleManager INST = new Free(); public static final NativeObjectLifecycleManager INST = new Free();
@Override void begin(final long ptr) { } @Override void begin(final long ptr) { }
@Override void end(final long ptr) { freeNativeObject(ptr); } @Override void end(final long ptr) { freeNativeObject(ptr); }
} }
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static class Nothing extends NativeObjectLifecycleManager { public static class Nothing extends NativeObjectLifecycleManager {
public static final NativeObjectLifecycleManager INST = new Nothing(); public static final NativeObjectLifecycleManager INST = new Nothing();
@Override void begin(final long ptr) { } @Override void begin(final long ptr) { }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,10 +24,7 @@ ...@@ -24,10 +24,7 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class Opaque extends Pointer<Void> { public class Opaque extends Pointer<Void> {
protected Opaque(long ptr) { super(ptr); } protected Opaque(long ptr) { super(ptr); }
protected Opaque(Pointer<?> ptr) { super(ptr.ptr); } protected Opaque(Pointer<?> ptr) { super(ptr.ptr); }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,10 +24,7 @@ ...@@ -24,10 +24,7 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class Pointer <T> implements Comparable<Pointer<T>>{ public class Pointer <T> implements Comparable<Pointer<T>>{
long ptr; long ptr;
......
/* /*
* Copyright (c) 2011,2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,11 +24,8 @@ ...@@ -24,11 +24,8 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import com.apple.jobjc.JObjCRuntime.Width; import com.apple.jobjc.JObjCRuntime.Width;
import javax.tools.annotation.GenerateNativeHeader;
// Auto generated by PrimitiveCoder.hs // Auto generated by PrimitiveCoder.hs
// Do not edit by hand. // Do not edit by hand.
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class PrimitiveCoder<T> extends Coder<T>{ public abstract class PrimitiveCoder<T> extends Coder<T>{
public PrimitiveCoder(int ffiTypeCode, String objCEncoding, Class jclass, Class jprim){ public PrimitiveCoder(int ffiTypeCode, String objCEncoding, Class jclass, Class jprim){
super(ffiTypeCode, objCEncoding, jclass, jprim); super(ffiTypeCode, objCEncoding, jclass, jprim);
...@@ -130,8 +127,6 @@ public abstract class PrimitiveCoder<T> extends Coder<T>{ ...@@ -130,8 +127,6 @@ public abstract class PrimitiveCoder<T> extends Coder<T>{
// native BOOL -> java boolean // native BOOL -> java boolean
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class BoolCoder extends PrimitiveCoder<Boolean>{ public static final class BoolCoder extends PrimitiveCoder<Boolean>{
public static final BoolCoder INST = new BoolCoder(); public static final BoolCoder INST = new BoolCoder();
public BoolCoder(){ super(FFI_SINT8, "B", Boolean.class, boolean.class); } public BoolCoder(){ super(FFI_SINT8, "B", Boolean.class, boolean.class); }
...@@ -175,8 +170,6 @@ public static final class BoolCoder extends PrimitiveCoder<Boolean>{ ...@@ -175,8 +170,6 @@ public static final class BoolCoder extends PrimitiveCoder<Boolean>{
} }
// native schar -> java byte // native schar -> java byte
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class SCharCoder extends PrimitiveCoder<Byte>{ public static final class SCharCoder extends PrimitiveCoder<Byte>{
public static final SCharCoder INST = new SCharCoder(); public static final SCharCoder INST = new SCharCoder();
public SCharCoder(){ super(FFI_SINT8, "c", Byte.class, byte.class); } public SCharCoder(){ super(FFI_SINT8, "c", Byte.class, byte.class); }
...@@ -220,8 +213,6 @@ public static final class SCharCoder extends PrimitiveCoder<Byte>{ ...@@ -220,8 +213,6 @@ public static final class SCharCoder extends PrimitiveCoder<Byte>{
} }
// native uchar -> java byte // native uchar -> java byte
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class UCharCoder extends PrimitiveCoder<Byte>{ public static final class UCharCoder extends PrimitiveCoder<Byte>{
public static final UCharCoder INST = new UCharCoder(); public static final UCharCoder INST = new UCharCoder();
public UCharCoder(){ super(FFI_UINT8, "C", Byte.class, byte.class); } public UCharCoder(){ super(FFI_UINT8, "C", Byte.class, byte.class); }
...@@ -265,8 +256,6 @@ public static final class UCharCoder extends PrimitiveCoder<Byte>{ ...@@ -265,8 +256,6 @@ public static final class UCharCoder extends PrimitiveCoder<Byte>{
} }
// native sshort -> java short // native sshort -> java short
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class SShortCoder extends PrimitiveCoder<Short>{ public static final class SShortCoder extends PrimitiveCoder<Short>{
public static final SShortCoder INST = new SShortCoder(); public static final SShortCoder INST = new SShortCoder();
public SShortCoder(){ super(FFI_SINT16, "s", Short.class, short.class); } public SShortCoder(){ super(FFI_SINT16, "s", Short.class, short.class); }
...@@ -310,8 +299,6 @@ public static final class SShortCoder extends PrimitiveCoder<Short>{ ...@@ -310,8 +299,6 @@ public static final class SShortCoder extends PrimitiveCoder<Short>{
} }
// native ushort -> java short // native ushort -> java short
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class UShortCoder extends PrimitiveCoder<Short>{ public static final class UShortCoder extends PrimitiveCoder<Short>{
public static final UShortCoder INST = new UShortCoder(); public static final UShortCoder INST = new UShortCoder();
public UShortCoder(){ super(FFI_UINT16, "S", Short.class, short.class); } public UShortCoder(){ super(FFI_UINT16, "S", Short.class, short.class); }
...@@ -355,8 +342,6 @@ public static final class UShortCoder extends PrimitiveCoder<Short>{ ...@@ -355,8 +342,6 @@ public static final class UShortCoder extends PrimitiveCoder<Short>{
} }
// native sint -> java int // native sint -> java int
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class SIntCoder extends PrimitiveCoder<Integer>{ public static final class SIntCoder extends PrimitiveCoder<Integer>{
public static final SIntCoder INST = new SIntCoder(); public static final SIntCoder INST = new SIntCoder();
public SIntCoder(){ super(FFI_SINT32, "i", Integer.class, int.class); } public SIntCoder(){ super(FFI_SINT32, "i", Integer.class, int.class); }
...@@ -400,8 +385,6 @@ public static final class SIntCoder extends PrimitiveCoder<Integer>{ ...@@ -400,8 +385,6 @@ public static final class SIntCoder extends PrimitiveCoder<Integer>{
} }
// native uint -> java int // native uint -> java int
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class UIntCoder extends PrimitiveCoder<Integer>{ public static final class UIntCoder extends PrimitiveCoder<Integer>{
public static final UIntCoder INST = new UIntCoder(); public static final UIntCoder INST = new UIntCoder();
public UIntCoder(){ super(FFI_UINT32, "I", Integer.class, int.class); } public UIntCoder(){ super(FFI_UINT32, "I", Integer.class, int.class); }
...@@ -445,8 +428,6 @@ public static final class UIntCoder extends PrimitiveCoder<Integer>{ ...@@ -445,8 +428,6 @@ public static final class UIntCoder extends PrimitiveCoder<Integer>{
} }
// native slong -> java long // native slong -> java long
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class SLongCoder extends PrimitiveCoder<Long>{ public static final class SLongCoder extends PrimitiveCoder<Long>{
public static final SLongCoder INST = new SLongCoder(); public static final SLongCoder INST = new SLongCoder();
public SLongCoder(){ super((JObjCRuntime.IS64 ? (FFI_SINT64) : (FFI_SINT32)), "l", Long.class, long.class); } public SLongCoder(){ super((JObjCRuntime.IS64 ? (FFI_SINT64) : (FFI_SINT32)), "l", Long.class, long.class); }
...@@ -496,8 +477,6 @@ public static final class SLongCoder extends PrimitiveCoder<Long>{ ...@@ -496,8 +477,6 @@ public static final class SLongCoder extends PrimitiveCoder<Long>{
} }
// native ulong -> java long // native ulong -> java long
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class ULongCoder extends PrimitiveCoder<Long>{ public static final class ULongCoder extends PrimitiveCoder<Long>{
public static final ULongCoder INST = new ULongCoder(); public static final ULongCoder INST = new ULongCoder();
public ULongCoder(){ super((JObjCRuntime.IS64 ? (FFI_UINT64) : (FFI_UINT32)), "L", Long.class, long.class); } public ULongCoder(){ super((JObjCRuntime.IS64 ? (FFI_UINT64) : (FFI_UINT32)), "L", Long.class, long.class); }
...@@ -547,8 +526,6 @@ public static final class ULongCoder extends PrimitiveCoder<Long>{ ...@@ -547,8 +526,6 @@ public static final class ULongCoder extends PrimitiveCoder<Long>{
} }
// native slonglong -> java long // native slonglong -> java long
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class SLongLongCoder extends PrimitiveCoder<Long>{ public static final class SLongLongCoder extends PrimitiveCoder<Long>{
public static final SLongLongCoder INST = new SLongLongCoder(); public static final SLongLongCoder INST = new SLongLongCoder();
public SLongLongCoder(){ super(FFI_SINT64, "q", Long.class, long.class); } public SLongLongCoder(){ super(FFI_SINT64, "q", Long.class, long.class); }
...@@ -592,8 +569,6 @@ public static final class SLongLongCoder extends PrimitiveCoder<Long>{ ...@@ -592,8 +569,6 @@ public static final class SLongLongCoder extends PrimitiveCoder<Long>{
} }
// native ulonglong -> java long // native ulonglong -> java long
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class ULongLongCoder extends PrimitiveCoder<Long>{ public static final class ULongLongCoder extends PrimitiveCoder<Long>{
public static final ULongLongCoder INST = new ULongLongCoder(); public static final ULongLongCoder INST = new ULongLongCoder();
public ULongLongCoder(){ super(FFI_UINT64, "Q", Long.class, long.class); } public ULongLongCoder(){ super(FFI_UINT64, "Q", Long.class, long.class); }
...@@ -637,8 +612,6 @@ public static final class ULongLongCoder extends PrimitiveCoder<Long>{ ...@@ -637,8 +612,6 @@ public static final class ULongLongCoder extends PrimitiveCoder<Long>{
} }
// native float -> java float // native float -> java float
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class FloatCoder extends PrimitiveCoder<Float>{ public static final class FloatCoder extends PrimitiveCoder<Float>{
public static final FloatCoder INST = new FloatCoder(); public static final FloatCoder INST = new FloatCoder();
public FloatCoder(){ super(FFI_FLOAT, "f", Float.class, float.class); } public FloatCoder(){ super(FFI_FLOAT, "f", Float.class, float.class); }
...@@ -682,8 +655,6 @@ public static final class FloatCoder extends PrimitiveCoder<Float>{ ...@@ -682,8 +655,6 @@ public static final class FloatCoder extends PrimitiveCoder<Float>{
} }
// native double -> java double // native double -> java double
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public static final class DoubleCoder extends PrimitiveCoder<Double>{ public static final class DoubleCoder extends PrimitiveCoder<Double>{
public static final DoubleCoder INST = new DoubleCoder(); public static final DoubleCoder INST = new DoubleCoder();
public DoubleCoder(){ super(FFI_DOUBLE, "d", Double.class, double.class); } public DoubleCoder(){ super(FFI_DOUBLE, "d", Double.class, double.class); }
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,10 +24,7 @@ ...@@ -24,10 +24,7 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class SEL { public class SEL {
static native long getSelectorPtr(String selectorName); static native long getSelectorPtr(String selectorName);
static native String getSelectorName(long ptr); static native String getSelectorName(long ptr);
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,13 +24,10 @@ ...@@ -24,13 +24,10 @@
*/ */
package com.apple.jobjc; package com.apple.jobjc;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* A struct is malloced on the C heap and accessed in Java through a ByteBuffer. * A struct is malloced on the C heap and accessed in Java through a ByteBuffer.
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class Struct{ public abstract class Struct{
protected final NativeBuffer raw; protected final NativeBuffer raw;
private final JObjCRuntime runtime; private final JObjCRuntime runtime;
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -33,10 +33,7 @@ import com.apple.jobjc.Coder.PrimitivePointerCoder; ...@@ -33,10 +33,7 @@ import com.apple.jobjc.Coder.PrimitivePointerCoder;
import com.apple.jobjc.Coder.VoidCoder; import com.apple.jobjc.Coder.VoidCoder;
import com.apple.jobjc.Invoke.MsgSend; import com.apple.jobjc.Invoke.MsgSend;
import javax.tools.annotation.GenerateNativeHeader;
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
final class Subclassing { final class Subclassing {
static native long allocateClassPair(long superClass, String name); static native long allocateClassPair(long superClass, String name);
static native boolean addIVarForJObj(long clazz); static native boolean addIVarForJObj(long clazz);
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -24,8 +24,6 @@ ...@@ -24,8 +24,6 @@
*/ */
#include "com_apple_jobjc_Invoke_FunCall.h" #include "com_apple_jobjc_Invoke_FunCall.h"
#include "com_apple_jobjc_Invoke_MsgSend.h"
#include "com_apple_jobjc_Invoke_MsgSendSuper.h"
#include <ffi/ffi.h> #include <ffi/ffi.h>
#include <objc/message.h> #include <objc/message.h>
#include <JavaNativeFoundation/JavaNativeFoundation.h> #include <JavaNativeFoundation/JavaNativeFoundation.h>
......
/* /*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -23,6 +23,5 @@ ...@@ -23,6 +23,5 @@
* questions. * questions.
*/ */
#include "com_apple_jobjc_JObjCRuntime.h"
#include "Cocoa/Cocoa.h" #include "Cocoa/Cocoa.h"
...@@ -501,10 +501,22 @@ static inline void doDrawGlyphsPipe_getGlyphVectorLengthAndAlloc ...@@ -501,10 +501,22 @@ static inline void doDrawGlyphsPipe_getGlyphVectorLengthAndAlloc
int *uniChars = (int *)malloc(sizeof(int) * length); int *uniChars = (int *)malloc(sizeof(int) * length);
CGSize *advances = (CGSize *)malloc(sizeof(CGSize) * length); CGSize *advances = (CGSize *)malloc(sizeof(CGSize) * length);
if (glyphs == NULL || advances == NULL) if (glyphs == NULL || uniChars == NULL || advances == NULL)
{ {
(*env)->DeleteLocalRef(env, glyphsArray); (*env)->DeleteLocalRef(env, glyphsArray);
[NSException raise:NSMallocException format:@"%s-%s:%d", THIS_FILE, __FUNCTION__, __LINE__]; [NSException raise:NSMallocException format:@"%s-%s:%d", THIS_FILE, __FUNCTION__, __LINE__];
if (glyphs)
{
free(glyphs);
}
if (uniChars)
{
free(uniChars);
}
if (advances)
{
free(advances);
}
return; return;
} }
......
/* /*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,7 +26,6 @@ ...@@ -26,7 +26,6 @@
#import "PrinterView.h" #import "PrinterView.h"
#import "java_awt_print_Pageable.h" #import "java_awt_print_Pageable.h"
#import "java_awt_print_Printable.h"
#import "java_awt_print_PageFormat.h" #import "java_awt_print_PageFormat.h"
#import <JavaNativeFoundation/JavaNativeFoundation.h> #import <JavaNativeFoundation/JavaNativeFoundation.h>
......
...@@ -32,8 +32,8 @@ ...@@ -32,8 +32,8 @@
static CFDateFormatterStyle convertDateFormatterStyle(jint javaStyle); static CFDateFormatterStyle convertDateFormatterStyle(jint javaStyle);
static CFNumberFormatterStyle convertNumberFormatterStyle(jint javaStyle); static CFNumberFormatterStyle convertNumberFormatterStyle(jint javaStyle);
static void copyArrayElements(JNIEnv *env, CFArrayRef cfarray, jobjectArray jarray, CFIndex sindex, int dindex, int count); static void copyArrayElements(JNIEnv *env, CFArrayRef cfarray, jobjectArray jarray, CFIndex sindex, int dindex, int count);
static jstring getNumberSymbolString(JNIEnv *env, jstring jdefault, CFStringRef type); static jstring getNumberSymbolString(JNIEnv *env, jstring jlangtag, jstring jdefault, CFStringRef type);
static jchar getNumberSymbolChar(jchar jdefault, CFStringRef type); static jchar getNumberSymbolChar(JNIEnv *env, jstring jlangtag, jchar jdefault, CFStringRef type);
// from java_props_macosx.c // from java_props_macosx.c
extern char * getMacOSXLocale(int cat); extern char * getMacOSXLocale(int cat);
...@@ -322,7 +322,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte ...@@ -322,7 +322,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte
*/ */
JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getCurrencySymbol JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getCurrencySymbol
(JNIEnv *env, jclass cls, jstring jlangtag, jstring currencySymbol) { (JNIEnv *env, jclass cls, jstring jlangtag, jstring currencySymbol) {
return getNumberSymbolString(env, currencySymbol, kCFNumberFormatterCurrencySymbol); return getNumberSymbolString(env, jlangtag, currencySymbol, kCFNumberFormatterCurrencySymbol);
} }
/* /*
...@@ -332,7 +332,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte ...@@ -332,7 +332,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getDecimalSeparator JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getDecimalSeparator
(JNIEnv *env, jclass cls, jstring jlangtag, jchar decimalSeparator) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar decimalSeparator) {
return getNumberSymbolChar(decimalSeparator, kCFNumberFormatterDecimalSeparator); return getNumberSymbolChar(env, jlangtag, decimalSeparator, kCFNumberFormatterDecimalSeparator);
} }
/* /*
...@@ -342,7 +342,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -342,7 +342,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getGroupingSeparator JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getGroupingSeparator
(JNIEnv *env, jclass cls, jstring jlangtag, jchar groupingSeparator) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar groupingSeparator) {
return getNumberSymbolChar(groupingSeparator, kCFNumberFormatterGroupingSeparator); return getNumberSymbolChar(env, jlangtag, groupingSeparator, kCFNumberFormatterGroupingSeparator);
} }
/* /*
...@@ -352,7 +352,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -352,7 +352,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getInfinity JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getInfinity
(JNIEnv *env, jclass cls, jstring jlangtag, jstring infinity) { (JNIEnv *env, jclass cls, jstring jlangtag, jstring infinity) {
return getNumberSymbolString(env, infinity, kCFNumberFormatterInfinitySymbol); return getNumberSymbolString(env, jlangtag, infinity, kCFNumberFormatterInfinitySymbol);
} }
/* /*
...@@ -362,7 +362,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte ...@@ -362,7 +362,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte
*/ */
JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getInternationalCurrencySymbol JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getInternationalCurrencySymbol
(JNIEnv *env, jclass cls, jstring jlangtag, jstring internationalCurrencySymbol) { (JNIEnv *env, jclass cls, jstring jlangtag, jstring internationalCurrencySymbol) {
return getNumberSymbolString(env, internationalCurrencySymbol, kCFNumberFormatterInternationalCurrencySymbol); return getNumberSymbolString(env, jlangtag, internationalCurrencySymbol, kCFNumberFormatterInternationalCurrencySymbol);
} }
/* /*
...@@ -372,7 +372,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte ...@@ -372,7 +372,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getMinusSign JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getMinusSign
(JNIEnv *env, jclass cls, jstring jlangtag, jchar minusSign) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar minusSign) {
return getNumberSymbolChar(minusSign, kCFNumberFormatterMinusSign); return getNumberSymbolChar(env, jlangtag, minusSign, kCFNumberFormatterMinusSign);
} }
/* /*
...@@ -382,7 +382,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -382,7 +382,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getMonetaryDecimalSeparator JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getMonetaryDecimalSeparator
(JNIEnv *env, jclass cls, jstring jlangtag, jchar monetaryDecimalSeparator) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar monetaryDecimalSeparator) {
return getNumberSymbolChar(monetaryDecimalSeparator, kCFNumberFormatterCurrencyDecimalSeparator); return getNumberSymbolChar(env, jlangtag, monetaryDecimalSeparator, kCFNumberFormatterCurrencyDecimalSeparator);
} }
/* /*
...@@ -392,7 +392,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -392,7 +392,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getNaN JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getNaN
(JNIEnv *env, jclass cls, jstring jlangtag, jstring nan) { (JNIEnv *env, jclass cls, jstring jlangtag, jstring nan) {
return getNumberSymbolString(env, nan, kCFNumberFormatterNaNSymbol); return getNumberSymbolString(env, jlangtag, nan, kCFNumberFormatterNaNSymbol);
} }
/* /*
...@@ -402,7 +402,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte ...@@ -402,7 +402,7 @@ JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapte
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getPercent JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getPercent
(JNIEnv *env, jclass cls, jstring jlangtag, jchar percent) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar percent) {
return getNumberSymbolChar(percent, kCFNumberFormatterPercentSymbol); return getNumberSymbolChar(env, jlangtag, percent, kCFNumberFormatterPercentSymbol);
} }
/* /*
...@@ -412,7 +412,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -412,7 +412,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getPerMill JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getPerMill
(JNIEnv *env, jclass cls, jstring jlangtag, jchar perMill) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar perMill) {
return getNumberSymbolChar(perMill, kCFNumberFormatterPerMillSymbol); return getNumberSymbolChar(env, jlangtag, perMill, kCFNumberFormatterPerMillSymbol);
} }
/* /*
...@@ -422,7 +422,36 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -422,7 +422,36 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getZeroDigit JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getZeroDigit
(JNIEnv *env, jclass cls, jstring jlangtag, jchar zeroDigit) { (JNIEnv *env, jclass cls, jstring jlangtag, jchar zeroDigit) {
return getNumberSymbolChar(zeroDigit, kCFNumberFormatterZeroSymbol); // The following code *should* work, but not for some reason :o
//
//return getNumberSymbolChar(env, jlangtag, zeroDigit, kCFNumberFormatterZeroSymbol);
//
// so here is a workaround.
jchar ret = zeroDigit;
CFLocaleRef cflocale = CFLocaleCopyCurrent();
if (cflocale != NULL) {
CFNumberFormatterRef nf = CFNumberFormatterCreate(kCFAllocatorDefault,
cflocale,
kCFNumberFormatterNoStyle);
if (nf != NULL) {
int zero = 0;
CFStringRef str = CFNumberFormatterCreateStringWithValue(kCFAllocatorDefault,
nf, kCFNumberIntType, &zero);
if (str != NULL) {
if (CFStringGetLength(str) > 0) {
ret = CFStringGetCharacterAtIndex(str, 0);
}
CFRelease(str);
}
CFRelease(nf);
}
CFRelease(cflocale);
}
return ret;
} }
/* /*
...@@ -432,7 +461,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI ...@@ -432,7 +461,7 @@ JNIEXPORT jchar JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterI
*/ */
JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getExponentSeparator JNIEXPORT jstring JNICALL Java_sun_util_locale_provider_HostLocaleProviderAdapterImpl_getExponentSeparator
(JNIEnv *env, jclass cls, jstring jlangtag, jstring exponent) { (JNIEnv *env, jclass cls, jstring jlangtag, jstring exponent) {
return getNumberSymbolString(env, exponent, kCFNumberFormatterExponentSymbol); return getNumberSymbolString(env, jlangtag, exponent, kCFNumberFormatterExponentSymbol);
} }
/* /*
...@@ -625,7 +654,7 @@ static void copyArrayElements(JNIEnv *env, CFArrayRef cfarray, jobjectArray jarr ...@@ -625,7 +654,7 @@ static void copyArrayElements(JNIEnv *env, CFArrayRef cfarray, jobjectArray jarr
} }
} }
static jstring getNumberSymbolString(JNIEnv *env, jstring jdefault, CFStringRef type) { static jstring getNumberSymbolString(JNIEnv *env, jstring jlangtag, jstring jdefault, CFStringRef type) {
char buf[BUFLEN]; char buf[BUFLEN];
jstring ret = jdefault; jstring ret = jdefault;
CFLocaleRef cflocale = CFLocaleCopyCurrent(); CFLocaleRef cflocale = CFLocaleCopyCurrent();
...@@ -633,7 +662,7 @@ static jstring getNumberSymbolString(JNIEnv *env, jstring jdefault, CFStringRef ...@@ -633,7 +662,7 @@ static jstring getNumberSymbolString(JNIEnv *env, jstring jdefault, CFStringRef
if (cflocale != NULL) { if (cflocale != NULL) {
CFNumberFormatterRef nf = CFNumberFormatterCreate(kCFAllocatorDefault, CFNumberFormatterRef nf = CFNumberFormatterCreate(kCFAllocatorDefault,
cflocale, cflocale,
kCFNumberFormatterDecimalStyle); kCFNumberFormatterNoStyle);
if (nf != NULL) { if (nf != NULL) {
CFStringRef str = CFNumberFormatterCopyProperty(nf, type); CFStringRef str = CFNumberFormatterCopyProperty(nf, type);
if (str != NULL) { if (str != NULL) {
...@@ -651,21 +680,21 @@ static jstring getNumberSymbolString(JNIEnv *env, jstring jdefault, CFStringRef ...@@ -651,21 +680,21 @@ static jstring getNumberSymbolString(JNIEnv *env, jstring jdefault, CFStringRef
return ret; return ret;
} }
static jchar getNumberSymbolChar(jchar jdefault, CFStringRef type) { static jchar getNumberSymbolChar(JNIEnv *env, jstring jlangtag, jchar jdefault, CFStringRef type) {
char buf[BUFLEN];
jchar ret = jdefault; jchar ret = jdefault;
CFLocaleRef cflocale = CFLocaleCopyCurrent(); CFLocaleRef cflocale = CFLocaleCopyCurrent();
if (cflocale != NULL) { if (cflocale != NULL) {
CFNumberFormatterRef nf = CFNumberFormatterCreate(kCFAllocatorDefault, CFNumberFormatterRef nf = CFNumberFormatterCreate(kCFAllocatorDefault,
cflocale, cflocale,
kCFNumberFormatterDecimalStyle); kCFNumberFormatterNoStyle);
if (nf != NULL) { if (nf != NULL) {
CFStringRef str = CFNumberFormatterCopyProperty(nf, type); CFStringRef str = CFNumberFormatterCopyProperty(nf, type);
if (str != NULL) { if (str != NULL) {
CFStringGetCString(str, buf, BUFLEN, kCFStringEncodingUTF8); if (CFStringGetLength(str) > 0) {
ret = CFStringGetCharacterAtIndex(str, 0);
}
CFRelease(str); CFRelease(str);
ret = buf[0];
} }
CFRelease(nf); CFRelease(nf);
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
/* Implemented in linker_md.c */ /* Implemented in linker_md.c */
void dbgsysBuildLibName(char *, int, char *, char *); void dbgsysBuildLibName(char *, int, const char *, const char *);
void * dbgsysLoadLibrary(const char *, char *err_buf, int err_buflen); void * dbgsysLoadLibrary(const char *, char *err_buf, int err_buflen);
void dbgsysUnloadLibrary(void *); void dbgsysUnloadLibrary(void *);
void * dbgsysFindLibraryEntry(void *, const char *); void * dbgsysFindLibraryEntry(void *, const char *);
......
...@@ -97,12 +97,12 @@ findTransportOnLoad(void *handle) ...@@ -97,12 +97,12 @@ findTransportOnLoad(void *handle)
/* Load transport library (directory=="" means do system search) */ /* Load transport library (directory=="" means do system search) */
static void * static void *
loadTransportLibrary(char *libdir, char *name) loadTransportLibrary(const char *libdir, const char *name)
{ {
void *handle; void *handle;
char libname[MAXPATHLEN+2]; char libname[MAXPATHLEN+2];
char buf[MAXPATHLEN*2+100]; char buf[MAXPATHLEN*2+100];
char *plibdir; const char *plibdir;
/* Convert libdir from UTF-8 to platform encoding */ /* Convert libdir from UTF-8 to platform encoding */
plibdir = NULL; plibdir = NULL;
...@@ -131,12 +131,12 @@ loadTransportLibrary(char *libdir, char *name) ...@@ -131,12 +131,12 @@ loadTransportLibrary(char *libdir, char *name)
* JDK 1.2 javai.c v1.61 * JDK 1.2 javai.c v1.61
*/ */
static jdwpError static jdwpError
loadTransport(char *name, jdwpTransportEnv **transportPtr) loadTransport(const char *name, jdwpTransportEnv **transportPtr)
{ {
JNIEnv *env; JNIEnv *env;
jdwpTransport_OnLoad_t onLoad; jdwpTransport_OnLoad_t onLoad;
void *handle; void *handle;
char *libdir; const char *libdir;
/* Make sure library name is not empty */ /* Make sure library name is not empty */
if (name == NULL) { if (name == NULL) {
......
/* /*
* Copyright (c) 1996, 2003, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,7 @@ package java.awt; ...@@ -27,7 +27,7 @@ package java.awt;
import java.awt.event.*; import java.awt.event.*;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The interface for objects which have an adjustable numeric value * The interface for objects which have an adjustable numeric value
...@@ -36,24 +36,22 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -36,24 +36,22 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Amy Fowler * @author Amy Fowler
* @author Tim Prinzing * @author Tim Prinzing
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface Adjustable { public interface Adjustable {
/** /**
* Indicates that the <code>Adjustable</code> has horizontal orientation. * Indicates that the <code>Adjustable</code> has horizontal orientation.
*/ */
public static final int HORIZONTAL = 0; @Native public static final int HORIZONTAL = 0;
/** /**
* Indicates that the <code>Adjustable</code> has vertical orientation. * Indicates that the <code>Adjustable</code> has vertical orientation.
*/ */
public static final int VERTICAL = 1; @Native public static final int VERTICAL = 1;
/** /**
* Indicates that the <code>Adjustable</code> has no orientation. * Indicates that the <code>Adjustable</code> has no orientation.
*/ */
public static final int NO_ORIENTATION = 2; @Native public static final int NO_ORIENTATION = 2;
/** /**
* Gets the orientation of the adjustable object. * Gets the orientation of the adjustable object.
......
/* /*
* Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
package java.awt; package java.awt;
import java.awt.image.ColorModel; import java.awt.image.ColorModel;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
import sun.java2d.SunCompositeContext; import sun.java2d.SunCompositeContext;
/** /**
...@@ -350,8 +350,6 @@ import sun.java2d.SunCompositeContext; ...@@ -350,8 +350,6 @@ import sun.java2d.SunCompositeContext;
* @see CompositeContext * @see CompositeContext
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class AlphaComposite implements Composite { public final class AlphaComposite implements Composite {
/** /**
* Both the color and the alpha of the destination are cleared * Both the color and the alpha of the destination are cleared
...@@ -364,7 +362,7 @@ public final class AlphaComposite implements Composite { ...@@ -364,7 +362,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = 0 * <em>C<sub>r</sub></em> = 0
*</pre> *</pre>
*/ */
public static final int CLEAR = 1; @Native public static final int CLEAR = 1;
/** /**
* The source is copied to the destination * The source is copied to the destination
...@@ -377,7 +375,7 @@ public final class AlphaComposite implements Composite { ...@@ -377,7 +375,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em> * <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>
*</pre> *</pre>
*/ */
public static final int SRC = 2; @Native public static final int SRC = 2;
/** /**
* The destination is left untouched * The destination is left untouched
...@@ -390,7 +388,7 @@ public final class AlphaComposite implements Composite { ...@@ -390,7 +388,7 @@ public final class AlphaComposite implements Composite {
*</pre> *</pre>
* @since 1.4 * @since 1.4
*/ */
public static final int DST = 9; @Native public static final int DST = 9;
// Note that DST was added in 1.4 so it is numbered out of order... // Note that DST was added in 1.4 so it is numbered out of order...
/** /**
...@@ -403,7 +401,7 @@ public final class AlphaComposite implements Composite { ...@@ -403,7 +401,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em> + <em>C<sub>d</sub></em>*(1-<em>A<sub>s</sub></em>) * <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em> + <em>C<sub>d</sub></em>*(1-<em>A<sub>s</sub></em>)
*</pre> *</pre>
*/ */
public static final int SRC_OVER = 3; @Native public static final int SRC_OVER = 3;
/** /**
* The destination is composited over the source and * The destination is composited over the source and
...@@ -416,7 +414,7 @@ public final class AlphaComposite implements Composite { ...@@ -416,7 +414,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>*(1-<em>A<sub>d</sub></em>) + <em>C<sub>d</sub></em> * <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>*(1-<em>A<sub>d</sub></em>) + <em>C<sub>d</sub></em>
*</pre> *</pre>
*/ */
public static final int DST_OVER = 4; @Native public static final int DST_OVER = 4;
/** /**
* The part of the source lying inside of the destination replaces * The part of the source lying inside of the destination replaces
...@@ -429,7 +427,7 @@ public final class AlphaComposite implements Composite { ...@@ -429,7 +427,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>*<em>A<sub>d</sub></em> * <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>*<em>A<sub>d</sub></em>
*</pre> *</pre>
*/ */
public static final int SRC_IN = 5; @Native public static final int SRC_IN = 5;
/** /**
* The part of the destination lying inside of the source * The part of the destination lying inside of the source
...@@ -442,7 +440,7 @@ public final class AlphaComposite implements Composite { ...@@ -442,7 +440,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>d</sub></em>*<em>A<sub>s</sub></em> * <em>C<sub>r</sub></em> = <em>C<sub>d</sub></em>*<em>A<sub>s</sub></em>
*</pre> *</pre>
*/ */
public static final int DST_IN = 6; @Native public static final int DST_IN = 6;
/** /**
* The part of the source lying outside of the destination * The part of the source lying outside of the destination
...@@ -455,7 +453,7 @@ public final class AlphaComposite implements Composite { ...@@ -455,7 +453,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>*(1-<em>A<sub>d</sub></em>) * <em>C<sub>r</sub></em> = <em>C<sub>s</sub></em>*(1-<em>A<sub>d</sub></em>)
*</pre> *</pre>
*/ */
public static final int SRC_OUT = 7; @Native public static final int SRC_OUT = 7;
/** /**
* The part of the destination lying outside of the source * The part of the destination lying outside of the source
...@@ -468,7 +466,7 @@ public final class AlphaComposite implements Composite { ...@@ -468,7 +466,7 @@ public final class AlphaComposite implements Composite {
* <em>C<sub>r</sub></em> = <em>C<sub>d</sub></em>*(1-<em>A<sub>s</sub></em>) * <em>C<sub>r</sub></em> = <em>C<sub>d</sub></em>*(1-<em>A<sub>s</sub></em>)
*</pre> *</pre>
*/ */
public static final int DST_OUT = 8; @Native public static final int DST_OUT = 8;
// Rule 9 is DST which is defined above where it fits into the // Rule 9 is DST which is defined above where it fits into the
// list logically, rather than numerically // list logically, rather than numerically
...@@ -487,7 +485,7 @@ public final class AlphaComposite implements Composite { ...@@ -487,7 +485,7 @@ public final class AlphaComposite implements Composite {
*</pre> *</pre>
* @since 1.4 * @since 1.4
*/ */
public static final int SRC_ATOP = 10; @Native public static final int SRC_ATOP = 10;
/** /**
* The part of the destination lying inside of the source * The part of the destination lying inside of the source
...@@ -501,7 +499,7 @@ public final class AlphaComposite implements Composite { ...@@ -501,7 +499,7 @@ public final class AlphaComposite implements Composite {
*</pre> *</pre>
* @since 1.4 * @since 1.4
*/ */
public static final int DST_ATOP = 11; @Native public static final int DST_ATOP = 11;
/** /**
* The part of the source that lies outside of the destination * The part of the source that lies outside of the destination
...@@ -516,7 +514,7 @@ public final class AlphaComposite implements Composite { ...@@ -516,7 +514,7 @@ public final class AlphaComposite implements Composite {
*</pre> *</pre>
* @since 1.4 * @since 1.4
*/ */
public static final int XOR = 12; @Native public static final int XOR = 12;
/** /**
* <code>AlphaComposite</code> object that implements the opaque CLEAR rule * <code>AlphaComposite</code> object that implements the opaque CLEAR rule
...@@ -606,8 +604,8 @@ public final class AlphaComposite implements Composite { ...@@ -606,8 +604,8 @@ public final class AlphaComposite implements Composite {
*/ */
public static final AlphaComposite Xor = new AlphaComposite(XOR); public static final AlphaComposite Xor = new AlphaComposite(XOR);
private static final int MIN_RULE = CLEAR; @Native private static final int MIN_RULE = CLEAR;
private static final int MAX_RULE = XOR; @Native private static final int MAX_RULE = XOR;
float extraAlpha; float extraAlpha;
int rule; int rule;
......
/* /*
* Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,7 @@ package java.awt; ...@@ -27,7 +27,7 @@ package java.awt;
import java.beans.ConstructorProperties; import java.beans.ConstructorProperties;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The <code>BasicStroke</code> class defines a basic set of rendering * The <code>BasicStroke</code> class defines a basic set of rendering
...@@ -111,47 +111,45 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -111,47 +111,45 @@ import javax.tools.annotation.GenerateNativeHeader;
* @see Graphics2D * @see Graphics2D
* @author Jim Graham * @author Jim Graham
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class BasicStroke implements Stroke { public class BasicStroke implements Stroke {
/** /**
* Joins path segments by extending their outside edges until * Joins path segments by extending their outside edges until
* they meet. * they meet.
*/ */
public final static int JOIN_MITER = 0; @Native public final static int JOIN_MITER = 0;
/** /**
* Joins path segments by rounding off the corner at a radius * Joins path segments by rounding off the corner at a radius
* of half the line width. * of half the line width.
*/ */
public final static int JOIN_ROUND = 1; @Native public final static int JOIN_ROUND = 1;
/** /**
* Joins path segments by connecting the outer corners of their * Joins path segments by connecting the outer corners of their
* wide outlines with a straight segment. * wide outlines with a straight segment.
*/ */
public final static int JOIN_BEVEL = 2; @Native public final static int JOIN_BEVEL = 2;
/** /**
* Ends unclosed subpaths and dash segments with no added * Ends unclosed subpaths and dash segments with no added
* decoration. * decoration.
*/ */
public final static int CAP_BUTT = 0; @Native public final static int CAP_BUTT = 0;
/** /**
* Ends unclosed subpaths and dash segments with a round * Ends unclosed subpaths and dash segments with a round
* decoration that has a radius equal to half of the width * decoration that has a radius equal to half of the width
* of the pen. * of the pen.
*/ */
public final static int CAP_ROUND = 1; @Native public final static int CAP_ROUND = 1;
/** /**
* Ends unclosed subpaths and dash segments with a square * Ends unclosed subpaths and dash segments with a square
* projection that extends beyond the end of the segment * projection that extends beyond the end of the segment
* to a distance equal to half of the line width. * to a distance equal to half of the line width.
*/ */
public final static int CAP_SQUARE = 2; @Native public final static int CAP_SQUARE = 2;
float width; float width;
......
/* /*
* Copyright (c) 1995, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -34,7 +34,6 @@ import java.io.IOException; ...@@ -34,7 +34,6 @@ import java.io.IOException;
import javax.accessibility.*; import javax.accessibility.*;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* The <code>Choice</code> class presents a pop-up menu of choices. * The <code>Choice</code> class presents a pop-up menu of choices.
...@@ -71,8 +70,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -71,8 +70,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Arthur van Hoff * @author Arthur van Hoff
* @since JDK1.0 * @since JDK1.0
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class Choice extends Component implements ItemSelectable, Accessible { public class Choice extends Component implements ItemSelectable, Accessible {
/** /**
* The items for the <code>Choice</code>. * The items for the <code>Choice</code>.
......
/* /*
* Copyright (c) 2000, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
package java.awt; package java.awt;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The <code>DisplayMode</code> class encapsulates the bit depth, height, * The <code>DisplayMode</code> class encapsulates the bit depth, height,
...@@ -46,8 +46,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -46,8 +46,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @since 1.4 * @since 1.4
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class DisplayMode { public final class DisplayMode {
private Dimension size; private Dimension size;
...@@ -94,7 +92,7 @@ public final class DisplayMode { ...@@ -94,7 +92,7 @@ public final class DisplayMode {
* display mode. * display mode.
* @see #getBitDepth * @see #getBitDepth
*/ */
public final static int BIT_DEPTH_MULTI = -1; @Native public final static int BIT_DEPTH_MULTI = -1;
/** /**
* Returns the bit depth of the display, in bits per pixel. This may be * Returns the bit depth of the display, in bits per pixel. This may be
...@@ -112,7 +110,7 @@ public final class DisplayMode { ...@@ -112,7 +110,7 @@ public final class DisplayMode {
* Value of the refresh rate if not known. * Value of the refresh rate if not known.
* @see #getRefreshRate * @see #getRefreshRate
*/ */
public final static int REFRESH_RATE_UNKNOWN = 0; @Native public final static int REFRESH_RATE_UNKNOWN = 0;
/** /**
* Returns the refresh rate of the display, in hertz. This may be * Returns the refresh rate of the display, in hertz. This may be
......
/* /*
* Copyright (c) 1995, 2007, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -33,7 +33,6 @@ import java.awt.image.ReplicateScaleFilter; ...@@ -33,7 +33,6 @@ import java.awt.image.ReplicateScaleFilter;
import sun.awt.image.SurfaceManager; import sun.awt.image.SurfaceManager;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* The abstract class <code>Image</code> is the superclass of all * The abstract class <code>Image</code> is the superclass of all
...@@ -44,8 +43,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -44,8 +43,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Arthur van Hoff * @author Arthur van Hoff
* @since JDK1.0 * @since JDK1.0
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class Image { public abstract class Image {
/** /**
......
/* /*
* Copyright (c) 1995, 2007, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -33,7 +33,6 @@ import java.io.ObjectOutputStream; ...@@ -33,7 +33,6 @@ import java.io.ObjectOutputStream;
import java.io.ObjectInputStream; import java.io.ObjectInputStream;
import java.io.IOException; import java.io.IOException;
import javax.accessibility.*; import javax.accessibility.*;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
...@@ -107,8 +106,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -107,8 +106,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @see java.awt.event.ActionListener * @see java.awt.event.ActionListener
* @since JDK1.0 * @since JDK1.0
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class List extends Component implements ItemSelectable, Accessible { public class List extends Component implements ItemSelectable, Accessible {
/** /**
* A vector created to contain items which will become * A vector created to contain items which will become
......
/* /*
* Copyright (c) 1996, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,7 +28,6 @@ package java.awt; ...@@ -28,7 +28,6 @@ package java.awt;
import java.awt.peer.PopupMenuPeer; import java.awt.peer.PopupMenuPeer;
import javax.accessibility.*; import javax.accessibility.*;
import javax.tools.annotation.GenerateNativeHeader;
import sun.awt.AWTAccessor; import sun.awt.AWTAccessor;
...@@ -44,8 +43,6 @@ import sun.awt.AWTAccessor; ...@@ -44,8 +43,6 @@ import sun.awt.AWTAccessor;
* *
* @author Amy Fowler * @author Amy Fowler
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class PopupMenu extends Menu { public class PopupMenu extends Menu {
private static final String base = "popup"; private static final String base = "popup";
......
/* /*
* Copyright (c) 1996, 2007, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,7 +26,7 @@ package java.awt; ...@@ -26,7 +26,7 @@ package java.awt;
import java.io.ObjectStreamException; import java.io.ObjectStreamException;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* A class to encapsulate symbolic colors representing the color of * A class to encapsulate symbolic colors representing the color of
...@@ -49,8 +49,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -49,8 +49,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Carl Quinn * @author Carl Quinn
* @author Amy Fowler * @author Amy Fowler
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class SystemColor extends Color implements java.io.Serializable { public final class SystemColor extends Color implements java.io.Serializable {
/** /**
...@@ -58,187 +56,187 @@ public final class SystemColor extends Color implements java.io.Serializable { ...@@ -58,187 +56,187 @@ public final class SystemColor extends Color implements java.io.Serializable {
* {@link #desktop} system color. * {@link #desktop} system color.
* @see SystemColor#desktop * @see SystemColor#desktop
*/ */
public final static int DESKTOP = 0; @Native public final static int DESKTOP = 0;
/** /**
* The array index for the * The array index for the
* {@link #activeCaption} system color. * {@link #activeCaption} system color.
* @see SystemColor#activeCaption * @see SystemColor#activeCaption
*/ */
public final static int ACTIVE_CAPTION = 1; @Native public final static int ACTIVE_CAPTION = 1;
/** /**
* The array index for the * The array index for the
* {@link #activeCaptionText} system color. * {@link #activeCaptionText} system color.
* @see SystemColor#activeCaptionText * @see SystemColor#activeCaptionText
*/ */
public final static int ACTIVE_CAPTION_TEXT = 2; @Native public final static int ACTIVE_CAPTION_TEXT = 2;
/** /**
* The array index for the * The array index for the
* {@link #activeCaptionBorder} system color. * {@link #activeCaptionBorder} system color.
* @see SystemColor#activeCaptionBorder * @see SystemColor#activeCaptionBorder
*/ */
public final static int ACTIVE_CAPTION_BORDER = 3; @Native public final static int ACTIVE_CAPTION_BORDER = 3;
/** /**
* The array index for the * The array index for the
* {@link #inactiveCaption} system color. * {@link #inactiveCaption} system color.
* @see SystemColor#inactiveCaption * @see SystemColor#inactiveCaption
*/ */
public final static int INACTIVE_CAPTION = 4; @Native public final static int INACTIVE_CAPTION = 4;
/** /**
* The array index for the * The array index for the
* {@link #inactiveCaptionText} system color. * {@link #inactiveCaptionText} system color.
* @see SystemColor#inactiveCaptionText * @see SystemColor#inactiveCaptionText
*/ */
public final static int INACTIVE_CAPTION_TEXT = 5; @Native public final static int INACTIVE_CAPTION_TEXT = 5;
/** /**
* The array index for the * The array index for the
* {@link #inactiveCaptionBorder} system color. * {@link #inactiveCaptionBorder} system color.
* @see SystemColor#inactiveCaptionBorder * @see SystemColor#inactiveCaptionBorder
*/ */
public final static int INACTIVE_CAPTION_BORDER = 6; @Native public final static int INACTIVE_CAPTION_BORDER = 6;
/** /**
* The array index for the * The array index for the
* {@link #window} system color. * {@link #window} system color.
* @see SystemColor#window * @see SystemColor#window
*/ */
public final static int WINDOW = 7; @Native public final static int WINDOW = 7;
/** /**
* The array index for the * The array index for the
* {@link #windowBorder} system color. * {@link #windowBorder} system color.
* @see SystemColor#windowBorder * @see SystemColor#windowBorder
*/ */
public final static int WINDOW_BORDER = 8; @Native public final static int WINDOW_BORDER = 8;
/** /**
* The array index for the * The array index for the
* {@link #windowText} system color. * {@link #windowText} system color.
* @see SystemColor#windowText * @see SystemColor#windowText
*/ */
public final static int WINDOW_TEXT = 9; @Native public final static int WINDOW_TEXT = 9;
/** /**
* The array index for the * The array index for the
* {@link #menu} system color. * {@link #menu} system color.
* @see SystemColor#menu * @see SystemColor#menu
*/ */
public final static int MENU = 10; @Native public final static int MENU = 10;
/** /**
* The array index for the * The array index for the
* {@link #menuText} system color. * {@link #menuText} system color.
* @see SystemColor#menuText * @see SystemColor#menuText
*/ */
public final static int MENU_TEXT = 11; @Native public final static int MENU_TEXT = 11;
/** /**
* The array index for the * The array index for the
* {@link #text} system color. * {@link #text} system color.
* @see SystemColor#text * @see SystemColor#text
*/ */
public final static int TEXT = 12; @Native public final static int TEXT = 12;
/** /**
* The array index for the * The array index for the
* {@link #textText} system color. * {@link #textText} system color.
* @see SystemColor#textText * @see SystemColor#textText
*/ */
public final static int TEXT_TEXT = 13; @Native public final static int TEXT_TEXT = 13;
/** /**
* The array index for the * The array index for the
* {@link #textHighlight} system color. * {@link #textHighlight} system color.
* @see SystemColor#textHighlight * @see SystemColor#textHighlight
*/ */
public final static int TEXT_HIGHLIGHT = 14; @Native public final static int TEXT_HIGHLIGHT = 14;
/** /**
* The array index for the * The array index for the
* {@link #textHighlightText} system color. * {@link #textHighlightText} system color.
* @see SystemColor#textHighlightText * @see SystemColor#textHighlightText
*/ */
public final static int TEXT_HIGHLIGHT_TEXT = 15; @Native public final static int TEXT_HIGHLIGHT_TEXT = 15;
/** /**
* The array index for the * The array index for the
* {@link #textInactiveText} system color. * {@link #textInactiveText} system color.
* @see SystemColor#textInactiveText * @see SystemColor#textInactiveText
*/ */
public final static int TEXT_INACTIVE_TEXT = 16; @Native public final static int TEXT_INACTIVE_TEXT = 16;
/** /**
* The array index for the * The array index for the
* {@link #control} system color. * {@link #control} system color.
* @see SystemColor#control * @see SystemColor#control
*/ */
public final static int CONTROL = 17; @Native public final static int CONTROL = 17;
/** /**
* The array index for the * The array index for the
* {@link #controlText} system color. * {@link #controlText} system color.
* @see SystemColor#controlText * @see SystemColor#controlText
*/ */
public final static int CONTROL_TEXT = 18; @Native public final static int CONTROL_TEXT = 18;
/** /**
* The array index for the * The array index for the
* {@link #controlHighlight} system color. * {@link #controlHighlight} system color.
* @see SystemColor#controlHighlight * @see SystemColor#controlHighlight
*/ */
public final static int CONTROL_HIGHLIGHT = 19; @Native public final static int CONTROL_HIGHLIGHT = 19;
/** /**
* The array index for the * The array index for the
* {@link #controlLtHighlight} system color. * {@link #controlLtHighlight} system color.
* @see SystemColor#controlLtHighlight * @see SystemColor#controlLtHighlight
*/ */
public final static int CONTROL_LT_HIGHLIGHT = 20; @Native public final static int CONTROL_LT_HIGHLIGHT = 20;
/** /**
* The array index for the * The array index for the
* {@link #controlShadow} system color. * {@link #controlShadow} system color.
* @see SystemColor#controlShadow * @see SystemColor#controlShadow
*/ */
public final static int CONTROL_SHADOW = 21; @Native public final static int CONTROL_SHADOW = 21;
/** /**
* The array index for the * The array index for the
* {@link #controlDkShadow} system color. * {@link #controlDkShadow} system color.
* @see SystemColor#controlDkShadow * @see SystemColor#controlDkShadow
*/ */
public final static int CONTROL_DK_SHADOW = 22; @Native public final static int CONTROL_DK_SHADOW = 22;
/** /**
* The array index for the * The array index for the
* {@link #scrollbar} system color. * {@link #scrollbar} system color.
* @see SystemColor#scrollbar * @see SystemColor#scrollbar
*/ */
public final static int SCROLLBAR = 23; @Native public final static int SCROLLBAR = 23;
/** /**
* The array index for the * The array index for the
* {@link #info} system color. * {@link #info} system color.
* @see SystemColor#info * @see SystemColor#info
*/ */
public final static int INFO = 24; @Native public final static int INFO = 24;
/** /**
* The array index for the * The array index for the
* {@link #infoText} system color. * {@link #infoText} system color.
* @see SystemColor#infoText * @see SystemColor#infoText
*/ */
public final static int INFO_TEXT = 25; @Native public final static int INFO_TEXT = 25;
/** /**
* The number of system colors in the array. * The number of system colors in the array.
*/ */
public final static int NUM_COLORS = 26; @Native public final static int NUM_COLORS = 26;
/******************************************************************************************/ /******************************************************************************************/
......
/* /*
* Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -35,7 +35,6 @@ import java.text.BreakIterator; ...@@ -35,7 +35,6 @@ import java.text.BreakIterator;
import javax.swing.text.AttributeSet; import javax.swing.text.AttributeSet;
import javax.accessibility.*; import javax.accessibility.*;
import java.awt.im.InputMethodRequests; import java.awt.im.InputMethodRequests;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* The <code>TextComponent</code> class is the superclass of * The <code>TextComponent</code> class is the superclass of
...@@ -57,8 +56,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -57,8 +56,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Arthur van Hoff * @author Arthur van Hoff
* @since JDK1.0 * @since JDK1.0
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class TextComponent extends Component implements Accessible { public class TextComponent extends Component implements Accessible {
/** /**
......
/* /*
* Copyright (c) 1997, 1999, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,34 +25,32 @@ ...@@ -25,34 +25,32 @@
package java.awt; package java.awt;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The <code>Transparency</code> interface defines the common transparency * The <code>Transparency</code> interface defines the common transparency
* modes for implementing classes. * modes for implementing classes.
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface Transparency { public interface Transparency {
/** /**
* Represents image data that is guaranteed to be completely opaque, * Represents image data that is guaranteed to be completely opaque,
* meaning that all pixels have an alpha value of 1.0. * meaning that all pixels have an alpha value of 1.0.
*/ */
public final static int OPAQUE = 1; @Native public final static int OPAQUE = 1;
/** /**
* Represents image data that is guaranteed to be either completely * Represents image data that is guaranteed to be either completely
* opaque, with an alpha value of 1.0, or completely transparent, * opaque, with an alpha value of 1.0, or completely transparent,
* with an alpha value of 0.0. * with an alpha value of 0.0.
*/ */
public final static int BITMASK = 2; @Native public final static int BITMASK = 2;
/** /**
* Represents image data that contains or might contain arbitrary * Represents image data that contains or might contain arbitrary
* alpha values between and including 0.0 and 1.0. * alpha values between and including 0.0 and 1.0.
*/ */
public final static int TRANSLUCENT = 3; @Native public final static int TRANSLUCENT = 3;
/** /**
* Returns the type of this <code>Transparency</code>. * Returns the type of this <code>Transparency</code>.
......
/* /*
* Copyright (c) 1997, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
package java.awt.color; package java.awt.color;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
import sun.java2d.cmm.PCMM; import sun.java2d.cmm.PCMM;
import sun.java2d.cmm.CMSManager; import sun.java2d.cmm.CMSManager;
...@@ -95,8 +95,6 @@ import sun.java2d.cmm.CMSManager; ...@@ -95,8 +95,6 @@ import sun.java2d.cmm.CMSManager;
* @see ICC_ColorSpace * @see ICC_ColorSpace
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class ColorSpace implements java.io.Serializable { public abstract class ColorSpace implements java.io.Serializable {
static final long serialVersionUID = -409452704308689724L; static final long serialVersionUID = -409452704308689724L;
...@@ -115,127 +113,127 @@ public abstract class ColorSpace implements java.io.Serializable { ...@@ -115,127 +113,127 @@ public abstract class ColorSpace implements java.io.Serializable {
/** /**
* Any of the family of XYZ color spaces. * Any of the family of XYZ color spaces.
*/ */
public static final int TYPE_XYZ = 0; @Native public static final int TYPE_XYZ = 0;
/** /**
* Any of the family of Lab color spaces. * Any of the family of Lab color spaces.
*/ */
public static final int TYPE_Lab = 1; @Native public static final int TYPE_Lab = 1;
/** /**
* Any of the family of Luv color spaces. * Any of the family of Luv color spaces.
*/ */
public static final int TYPE_Luv = 2; @Native public static final int TYPE_Luv = 2;
/** /**
* Any of the family of YCbCr color spaces. * Any of the family of YCbCr color spaces.
*/ */
public static final int TYPE_YCbCr = 3; @Native public static final int TYPE_YCbCr = 3;
/** /**
* Any of the family of Yxy color spaces. * Any of the family of Yxy color spaces.
*/ */
public static final int TYPE_Yxy = 4; @Native public static final int TYPE_Yxy = 4;
/** /**
* Any of the family of RGB color spaces. * Any of the family of RGB color spaces.
*/ */
public static final int TYPE_RGB = 5; @Native public static final int TYPE_RGB = 5;
/** /**
* Any of the family of GRAY color spaces. * Any of the family of GRAY color spaces.
*/ */
public static final int TYPE_GRAY = 6; @Native public static final int TYPE_GRAY = 6;
/** /**
* Any of the family of HSV color spaces. * Any of the family of HSV color spaces.
*/ */
public static final int TYPE_HSV = 7; @Native public static final int TYPE_HSV = 7;
/** /**
* Any of the family of HLS color spaces. * Any of the family of HLS color spaces.
*/ */
public static final int TYPE_HLS = 8; @Native public static final int TYPE_HLS = 8;
/** /**
* Any of the family of CMYK color spaces. * Any of the family of CMYK color spaces.
*/ */
public static final int TYPE_CMYK = 9; @Native public static final int TYPE_CMYK = 9;
/** /**
* Any of the family of CMY color spaces. * Any of the family of CMY color spaces.
*/ */
public static final int TYPE_CMY = 11; @Native public static final int TYPE_CMY = 11;
/** /**
* Generic 2 component color spaces. * Generic 2 component color spaces.
*/ */
public static final int TYPE_2CLR = 12; @Native public static final int TYPE_2CLR = 12;
/** /**
* Generic 3 component color spaces. * Generic 3 component color spaces.
*/ */
public static final int TYPE_3CLR = 13; @Native public static final int TYPE_3CLR = 13;
/** /**
* Generic 4 component color spaces. * Generic 4 component color spaces.
*/ */
public static final int TYPE_4CLR = 14; @Native public static final int TYPE_4CLR = 14;
/** /**
* Generic 5 component color spaces. * Generic 5 component color spaces.
*/ */
public static final int TYPE_5CLR = 15; @Native public static final int TYPE_5CLR = 15;
/** /**
* Generic 6 component color spaces. * Generic 6 component color spaces.
*/ */
public static final int TYPE_6CLR = 16; @Native public static final int TYPE_6CLR = 16;
/** /**
* Generic 7 component color spaces. * Generic 7 component color spaces.
*/ */
public static final int TYPE_7CLR = 17; @Native public static final int TYPE_7CLR = 17;
/** /**
* Generic 8 component color spaces. * Generic 8 component color spaces.
*/ */
public static final int TYPE_8CLR = 18; @Native public static final int TYPE_8CLR = 18;
/** /**
* Generic 9 component color spaces. * Generic 9 component color spaces.
*/ */
public static final int TYPE_9CLR = 19; @Native public static final int TYPE_9CLR = 19;
/** /**
* Generic 10 component color spaces. * Generic 10 component color spaces.
*/ */
public static final int TYPE_ACLR = 20; @Native public static final int TYPE_ACLR = 20;
/** /**
* Generic 11 component color spaces. * Generic 11 component color spaces.
*/ */
public static final int TYPE_BCLR = 21; @Native public static final int TYPE_BCLR = 21;
/** /**
* Generic 12 component color spaces. * Generic 12 component color spaces.
*/ */
public static final int TYPE_CCLR = 22; @Native public static final int TYPE_CCLR = 22;
/** /**
* Generic 13 component color spaces. * Generic 13 component color spaces.
*/ */
public static final int TYPE_DCLR = 23; @Native public static final int TYPE_DCLR = 23;
/** /**
* Generic 14 component color spaces. * Generic 14 component color spaces.
*/ */
public static final int TYPE_ECLR = 24; @Native public static final int TYPE_ECLR = 24;
/** /**
* Generic 15 component color spaces. * Generic 15 component color spaces.
*/ */
public static final int TYPE_FCLR = 25; @Native public static final int TYPE_FCLR = 25;
/** /**
* The sRGB color space defined at * The sRGB color space defined at
...@@ -243,28 +241,28 @@ public abstract class ColorSpace implements java.io.Serializable { ...@@ -243,28 +241,28 @@ public abstract class ColorSpace implements java.io.Serializable {
* http://www.w3.org/pub/WWW/Graphics/Color/sRGB.html * http://www.w3.org/pub/WWW/Graphics/Color/sRGB.html
* </A>. * </A>.
*/ */
public static final int CS_sRGB = 1000; @Native public static final int CS_sRGB = 1000;
/** /**
* A built-in linear RGB color space. This space is based on the * A built-in linear RGB color space. This space is based on the
* same RGB primaries as CS_sRGB, but has a linear tone reproduction curve. * same RGB primaries as CS_sRGB, but has a linear tone reproduction curve.
*/ */
public static final int CS_LINEAR_RGB = 1004; @Native public static final int CS_LINEAR_RGB = 1004;
/** /**
* The CIEXYZ conversion color space defined above. * The CIEXYZ conversion color space defined above.
*/ */
public static final int CS_CIEXYZ = 1001; @Native public static final int CS_CIEXYZ = 1001;
/** /**
* The Photo YCC conversion color space. * The Photo YCC conversion color space.
*/ */
public static final int CS_PYCC = 1002; @Native public static final int CS_PYCC = 1002;
/** /**
* The built-in linear gray scale color space. * The built-in linear gray scale color space.
*/ */
public static final int CS_GRAY = 1003; @Native public static final int CS_GRAY = 1003;
/** /**
......
/* /*
* Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -58,7 +58,6 @@ import java.util.StringTokenizer; ...@@ -58,7 +58,6 @@ import java.util.StringTokenizer;
import java.security.AccessController; import java.security.AccessController;
import java.security.PrivilegedAction; import java.security.PrivilegedAction;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* A representation of color profile data for device independent and * A representation of color profile data for device independent and
...@@ -90,8 +89,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -90,8 +89,6 @@ import javax.tools.annotation.GenerateNativeHeader;
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class ICC_Profile implements Serializable { public class ICC_Profile implements Serializable {
private static final long serialVersionUID = -3938515861990936766L; private static final long serialVersionUID = -3938515861990936766L;
......
/* /*
* Copyright (c) 1996, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,6 @@ package java.awt.datatransfer; ...@@ -27,7 +27,6 @@ package java.awt.datatransfer;
import java.io.*; import java.io.*;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* A <code>Transferable</code> which implements the capability required * A <code>Transferable</code> which implements the capability required
...@@ -43,8 +42,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -43,8 +42,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @see java.awt.datatransfer.DataFlavor#stringFlavor * @see java.awt.datatransfer.DataFlavor#stringFlavor
* @see java.awt.datatransfer.DataFlavor#plainTextFlavor * @see java.awt.datatransfer.DataFlavor#plainTextFlavor
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class StringSelection implements Transferable, ClipboardOwner { public class StringSelection implements Transferable, ClipboardOwner {
private static final int STRING = 0; private static final int STRING = 0;
......
/* /*
* Copyright (c) 1997, 1999, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,15 +25,13 @@ ...@@ -25,15 +25,13 @@
package java.awt.dnd; package java.awt.dnd;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* This class contains constant values representing * This class contains constant values representing
* the type of action(s) to be performed by a Drag and Drop operation. * the type of action(s) to be performed by a Drag and Drop operation.
* @since 1.2 * @since 1.2
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public final class DnDConstants { public final class DnDConstants {
private DnDConstants() {} // define null private constructor. private DnDConstants() {} // define null private constructor.
...@@ -41,23 +39,23 @@ public final class DnDConstants { ...@@ -41,23 +39,23 @@ public final class DnDConstants {
/** /**
* An <code>int</code> representing no action. * An <code>int</code> representing no action.
*/ */
public static final int ACTION_NONE = 0x0; @Native public static final int ACTION_NONE = 0x0;
/** /**
* An <code>int</code> representing a &quot;copy&quot; action. * An <code>int</code> representing a &quot;copy&quot; action.
*/ */
public static final int ACTION_COPY = 0x1; @Native public static final int ACTION_COPY = 0x1;
/** /**
* An <code>int</code> representing a &quot;move&quot; action. * An <code>int</code> representing a &quot;move&quot; action.
*/ */
public static final int ACTION_MOVE = 0x2; @Native public static final int ACTION_MOVE = 0x2;
/** /**
* An <code>int</code> representing a &quot;copy&quot; or * An <code>int</code> representing a &quot;copy&quot; or
* &quot;move&quot; action. * &quot;move&quot; action.
*/ */
public static final int ACTION_COPY_OR_MOVE = ACTION_COPY | ACTION_MOVE; @Native public static final int ACTION_COPY_OR_MOVE = ACTION_COPY | ACTION_MOVE;
/** /**
* An <code>int</code> representing a &quot;link&quot; action. * An <code>int</code> representing a &quot;link&quot; action.
...@@ -75,12 +73,12 @@ public final class DnDConstants { ...@@ -75,12 +73,12 @@ public final class DnDConstants {
* results for the user. * results for the user.
*/ */
public static final int ACTION_LINK = 0x40000000; @Native public static final int ACTION_LINK = 0x40000000;
/** /**
* An <code>int</code> representing a &quot;reference&quot; * An <code>int</code> representing a &quot;reference&quot;
* action (synonym for ACTION_LINK). * action (synonym for ACTION_LINK).
*/ */
public static final int ACTION_REFERENCE = ACTION_LINK; @Native public static final int ACTION_REFERENCE = ACTION_LINK;
} }
/* /*
* Copyright (c) 1996, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,7 @@ package java.awt.event; ...@@ -27,7 +27,7 @@ package java.awt.event;
import java.awt.AWTEvent; import java.awt.AWTEvent;
import java.awt.Event; import java.awt.Event;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* A semantic event which indicates that a component-defined action occurred. * A semantic event which indicates that a component-defined action occurred.
...@@ -57,8 +57,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -57,8 +57,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Carl Quinn * @author Carl Quinn
* @since 1.1 * @since 1.1
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class ActionEvent extends AWTEvent { public class ActionEvent extends AWTEvent {
/** /**
...@@ -99,7 +97,7 @@ public class ActionEvent extends AWTEvent { ...@@ -99,7 +97,7 @@ public class ActionEvent extends AWTEvent {
/** /**
* This event id indicates that a meaningful action occured. * This event id indicates that a meaningful action occured.
*/ */
public static final int ACTION_PERFORMED = ACTION_FIRST; //Event.ACTION_EVENT @Native public static final int ACTION_PERFORMED = ACTION_FIRST; //Event.ACTION_EVENT
/** /**
* The nonlocalized string that gives more details * The nonlocalized string that gives more details
......
/* /*
* Copyright (c) 1996, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,9 +27,8 @@ package java.awt.event; ...@@ -27,9 +27,8 @@ package java.awt.event;
import java.awt.Adjustable; import java.awt.Adjustable;
import java.awt.AWTEvent; import java.awt.AWTEvent;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* The adjustment event emitted by Adjustable objects like * The adjustment event emitted by Adjustable objects like
...@@ -57,8 +56,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -57,8 +56,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Amy Fowler * @author Amy Fowler
* @since 1.1 * @since 1.1
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class AdjustmentEvent extends AWTEvent { public class AdjustmentEvent extends AWTEvent {
/** /**
...@@ -79,27 +76,27 @@ public class AdjustmentEvent extends AWTEvent { ...@@ -79,27 +76,27 @@ public class AdjustmentEvent extends AWTEvent {
/** /**
* The unit increment adjustment type. * The unit increment adjustment type.
*/ */
public static final int UNIT_INCREMENT = 1; @Native public static final int UNIT_INCREMENT = 1;
/** /**
* The unit decrement adjustment type. * The unit decrement adjustment type.
*/ */
public static final int UNIT_DECREMENT = 2; @Native public static final int UNIT_DECREMENT = 2;
/** /**
* The block decrement adjustment type. * The block decrement adjustment type.
*/ */
public static final int BLOCK_DECREMENT = 3; @Native public static final int BLOCK_DECREMENT = 3;
/** /**
* The block increment adjustment type. * The block increment adjustment type.
*/ */
public static final int BLOCK_INCREMENT = 4; @Native public static final int BLOCK_INCREMENT = 4;
/** /**
* The absolute tracking adjustment type. * The absolute tracking adjustment type.
*/ */
public static final int TRACK = 5; @Native public static final int TRACK = 5;
/** /**
* The adjustable object that fired the event. * The adjustable object that fired the event.
......
/* /*
* Copyright (c) 1996, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,7 +28,7 @@ package java.awt.event; ...@@ -28,7 +28,7 @@ package java.awt.event;
import java.awt.AWTEvent; import java.awt.AWTEvent;
import java.awt.Component; import java.awt.Component;
import java.awt.Rectangle; import java.awt.Rectangle;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* A low-level event which indicates that a component moved, changed * A low-level event which indicates that a component moved, changed
...@@ -65,8 +65,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -65,8 +65,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author Carl Quinn * @author Carl Quinn
* @since 1.1 * @since 1.1
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class ComponentEvent extends AWTEvent { public class ComponentEvent extends AWTEvent {
/** /**
...@@ -82,22 +80,22 @@ public class ComponentEvent extends AWTEvent { ...@@ -82,22 +80,22 @@ public class ComponentEvent extends AWTEvent {
/** /**
* This event indicates that the component's position changed. * This event indicates that the component's position changed.
*/ */
public static final int COMPONENT_MOVED = COMPONENT_FIRST; @Native public static final int COMPONENT_MOVED = COMPONENT_FIRST;
/** /**
* This event indicates that the component's size changed. * This event indicates that the component's size changed.
*/ */
public static final int COMPONENT_RESIZED = 1 + COMPONENT_FIRST; @Native public static final int COMPONENT_RESIZED = 1 + COMPONENT_FIRST;
/** /**
* This event indicates that the component was made visible. * This event indicates that the component was made visible.
*/ */
public static final int COMPONENT_SHOWN = 2 + COMPONENT_FIRST; @Native public static final int COMPONENT_SHOWN = 2 + COMPONENT_FIRST;
/** /**
* This event indicates that the component was rendered invisible. * This event indicates that the component was rendered invisible.
*/ */
public static final int COMPONENT_HIDDEN = 3 + COMPONENT_FIRST; @Native public static final int COMPONENT_HIDDEN = 3 + COMPONENT_FIRST;
/* /*
* JDK 1.1 serialVersionUID * JDK 1.1 serialVersionUID
......
/* /*
* Copyright (c) 1996, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,7 +26,6 @@ ...@@ -26,7 +26,6 @@
package java.awt.event; package java.awt.event;
import java.awt.Component; import java.awt.Component;
import javax.tools.annotation.GenerateNativeHeader;
import sun.awt.AppContext; import sun.awt.AppContext;
import sun.awt.SunToolkit; import sun.awt.SunToolkit;
...@@ -64,8 +63,6 @@ import sun.awt.SunToolkit; ...@@ -64,8 +63,6 @@ import sun.awt.SunToolkit;
* @author Amy Fowler * @author Amy Fowler
* @since 1.1 * @since 1.1
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class FocusEvent extends ComponentEvent { public class FocusEvent extends ComponentEvent {
/** /**
......
/* /*
* Copyright (c) 1997, 2007, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -33,7 +33,7 @@ import java.io.IOException; ...@@ -33,7 +33,7 @@ import java.io.IOException;
import java.io.ObjectInputStream; import java.io.ObjectInputStream;
import java.text.AttributedCharacterIterator; import java.text.AttributedCharacterIterator;
import java.text.CharacterIterator; import java.text.CharacterIterator;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* Input method events contain information about text that is being * Input method events contain information about text that is being
...@@ -56,8 +56,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -56,8 +56,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @author JavaSoft Asia/Pacific * @author JavaSoft Asia/Pacific
* @since 1.2 * @since 1.2
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class InputMethodEvent extends AWTEvent { public class InputMethodEvent extends AWTEvent {
/** /**
...@@ -68,25 +66,25 @@ public class InputMethodEvent extends AWTEvent { ...@@ -68,25 +66,25 @@ public class InputMethodEvent extends AWTEvent {
/** /**
* Marks the first integer id for the range of input method event ids. * Marks the first integer id for the range of input method event ids.
*/ */
public static final int INPUT_METHOD_FIRST = 1100; @Native public static final int INPUT_METHOD_FIRST = 1100;
/** /**
* The event type indicating changed input method text. This event is * The event type indicating changed input method text. This event is
* generated by input methods while processing input. * generated by input methods while processing input.
*/ */
public static final int INPUT_METHOD_TEXT_CHANGED = INPUT_METHOD_FIRST; @Native public static final int INPUT_METHOD_TEXT_CHANGED = INPUT_METHOD_FIRST;
/** /**
* The event type indicating a changed insertion point in input method text. * The event type indicating a changed insertion point in input method text.
* This event is * This event is
* generated by input methods while processing input if only the caret changed. * generated by input methods while processing input if only the caret changed.
*/ */
public static final int CARET_POSITION_CHANGED = INPUT_METHOD_FIRST + 1; @Native public static final int CARET_POSITION_CHANGED = INPUT_METHOD_FIRST + 1;
/** /**
* Marks the last integer id for the range of input method event ids. * Marks the last integer id for the range of input method event ids.
*/ */
public static final int INPUT_METHOD_LAST = INPUT_METHOD_FIRST + 1; @Native public static final int INPUT_METHOD_LAST = INPUT_METHOD_FIRST + 1;
/** /**
* The time stamp that indicates when the event was created. * The time stamp that indicates when the event was created.
......
/* /*
* Copyright (c) 2000, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,7 @@ package java.awt.event; ...@@ -27,7 +27,7 @@ package java.awt.event;
import java.awt.Component; import java.awt.Component;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* An event which indicates that the mouse wheel was rotated in a component. * An event which indicates that the mouse wheel was rotated in a component.
...@@ -99,8 +99,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -99,8 +99,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @since 1.4 * @since 1.4
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class MouseWheelEvent extends MouseEvent { public class MouseWheelEvent extends MouseEvent {
/** /**
...@@ -109,7 +107,7 @@ public class MouseWheelEvent extends MouseEvent { ...@@ -109,7 +107,7 @@ public class MouseWheelEvent extends MouseEvent {
* *
* @see #getScrollType * @see #getScrollType
*/ */
public static final int WHEEL_UNIT_SCROLL = 0; @Native public static final int WHEEL_UNIT_SCROLL = 0;
/** /**
* Constant representing scrolling by a "block" (like scrolling * Constant representing scrolling by a "block" (like scrolling
...@@ -117,7 +115,7 @@ public class MouseWheelEvent extends MouseEvent { ...@@ -117,7 +115,7 @@ public class MouseWheelEvent extends MouseEvent {
* *
* @see #getScrollType * @see #getScrollType
*/ */
public static final int WHEEL_BLOCK_SCROLL = 1; @Native public static final int WHEEL_BLOCK_SCROLL = 1;
/** /**
* Indicates what sort of scrolling should take place in response to this * Indicates what sort of scrolling should take place in response to this
......
/* /*
* Copyright (c) 1996, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
package java.awt.event; package java.awt.event;
import java.awt.Window; import java.awt.Window;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
import sun.awt.AppContext; import sun.awt.AppContext;
import sun.awt.SunToolkit; import sun.awt.SunToolkit;
...@@ -56,8 +56,6 @@ import sun.awt.SunToolkit; ...@@ -56,8 +56,6 @@ import sun.awt.SunToolkit;
* *
* @since JDK1.1 * @since JDK1.1
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class WindowEvent extends ComponentEvent { public class WindowEvent extends ComponentEvent {
/** /**
...@@ -69,7 +67,7 @@ public class WindowEvent extends ComponentEvent { ...@@ -69,7 +67,7 @@ public class WindowEvent extends ComponentEvent {
* The window opened event. This event is delivered only * The window opened event. This event is delivered only
* the first time a window is made visible. * the first time a window is made visible.
*/ */
public static final int WINDOW_OPENED = WINDOW_FIRST; // 200 @Native public static final int WINDOW_OPENED = WINDOW_FIRST; // 200
/** /**
* The "window is closing" event. This event is delivered when * The "window is closing" event. This event is delivered when
...@@ -78,13 +76,13 @@ public class WindowEvent extends ComponentEvent { ...@@ -78,13 +76,13 @@ public class WindowEvent extends ComponentEvent {
* while processing this event, the window close operation will be * while processing this event, the window close operation will be
* cancelled. * cancelled.
*/ */
public static final int WINDOW_CLOSING = 1 + WINDOW_FIRST; //Event.WINDOW_DESTROY @Native public static final int WINDOW_CLOSING = 1 + WINDOW_FIRST; //Event.WINDOW_DESTROY
/** /**
* The window closed event. This event is delivered after * The window closed event. This event is delivered after
* the window has been closed as the result of a call to dispose. * the window has been closed as the result of a call to dispose.
*/ */
public static final int WINDOW_CLOSED = 2 + WINDOW_FIRST; @Native public static final int WINDOW_CLOSED = 2 + WINDOW_FIRST;
/** /**
* The window iconified event. This event is delivered when * The window iconified event. This event is delivered when
...@@ -93,13 +91,13 @@ public class WindowEvent extends ComponentEvent { ...@@ -93,13 +91,13 @@ public class WindowEvent extends ComponentEvent {
* the icon specified in the window's iconImage property. * the icon specified in the window's iconImage property.
* @see java.awt.Frame#setIconImage * @see java.awt.Frame#setIconImage
*/ */
public static final int WINDOW_ICONIFIED = 3 + WINDOW_FIRST; //Event.WINDOW_ICONIFY @Native public static final int WINDOW_ICONIFIED = 3 + WINDOW_FIRST; //Event.WINDOW_ICONIFY
/** /**
* The window deiconified event type. This event is delivered when * The window deiconified event type. This event is delivered when
* the window has been changed from a minimized to a normal state. * the window has been changed from a minimized to a normal state.
*/ */
public static final int WINDOW_DEICONIFIED = 4 + WINDOW_FIRST; //Event.WINDOW_DEICONIFY @Native public static final int WINDOW_DEICONIFIED = 4 + WINDOW_FIRST; //Event.WINDOW_DEICONIFY
/** /**
* The window-activated event type. This event is delivered when the Window * The window-activated event type. This event is delivered when the Window
...@@ -109,7 +107,7 @@ public class WindowEvent extends ComponentEvent { ...@@ -109,7 +107,7 @@ public class WindowEvent extends ComponentEvent {
* active Window is always either the focused Window, or the first Frame or * active Window is always either the focused Window, or the first Frame or
* Dialog that is an owner of the focused Window. * Dialog that is an owner of the focused Window.
*/ */
public static final int WINDOW_ACTIVATED = 5 + WINDOW_FIRST; @Native public static final int WINDOW_ACTIVATED = 5 + WINDOW_FIRST;
/** /**
* The window-deactivated event type. This event is delivered when the * The window-deactivated event type. This event is delivered when the
...@@ -119,21 +117,21 @@ public class WindowEvent extends ComponentEvent { ...@@ -119,21 +117,21 @@ public class WindowEvent extends ComponentEvent {
* title bar. The active Window is always either the focused Window, or the * title bar. The active Window is always either the focused Window, or the
* first Frame or Dialog that is an owner of the focused Window. * first Frame or Dialog that is an owner of the focused Window.
*/ */
public static final int WINDOW_DEACTIVATED = 6 + WINDOW_FIRST; @Native public static final int WINDOW_DEACTIVATED = 6 + WINDOW_FIRST;
/** /**
* The window-gained-focus event type. This event is delivered when the * The window-gained-focus event type. This event is delivered when the
* Window becomes the focused Window, which means that the Window, or one * Window becomes the focused Window, which means that the Window, or one
* of its subcomponents, will receive keyboard events. * of its subcomponents, will receive keyboard events.
*/ */
public static final int WINDOW_GAINED_FOCUS = 7 + WINDOW_FIRST; @Native public static final int WINDOW_GAINED_FOCUS = 7 + WINDOW_FIRST;
/** /**
* The window-lost-focus event type. This event is delivered when a Window * The window-lost-focus event type. This event is delivered when a Window
* is no longer the focused Window, which means keyboard events will no * is no longer the focused Window, which means keyboard events will no
* longer be delivered to the Window or any of its subcomponents. * longer be delivered to the Window or any of its subcomponents.
*/ */
public static final int WINDOW_LOST_FOCUS = 8 + WINDOW_FIRST; @Native public static final int WINDOW_LOST_FOCUS = 8 + WINDOW_FIRST;
/** /**
* The window-state-changed event type. This event is delivered * The window-state-changed event type. This event is delivered
...@@ -141,7 +139,7 @@ public class WindowEvent extends ComponentEvent { ...@@ -141,7 +139,7 @@ public class WindowEvent extends ComponentEvent {
* iconified, maximized etc. * iconified, maximized etc.
* @since 1.4 * @since 1.4
*/ */
public static final int WINDOW_STATE_CHANGED = 9 + WINDOW_FIRST; @Native public static final int WINDOW_STATE_CHANGED = 9 + WINDOW_FIRST;
/** /**
* The last number in the range of ids used for window events. * The last number in the range of ids used for window events.
......
/* /*
* Copyright (c) 1997, 2000, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
package java.awt.geom; package java.awt.geom;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The <code>PathIterator</code> interface provides the mechanism * The <code>PathIterator</code> interface provides the mechanism
...@@ -59,8 +59,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -59,8 +59,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* *
* @author Jim Graham * @author Jim Graham
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface PathIterator { public interface PathIterator {
/** /**
* The winding rule constant for specifying an even-odd rule * The winding rule constant for specifying an even-odd rule
...@@ -69,7 +67,7 @@ public interface PathIterator { ...@@ -69,7 +67,7 @@ public interface PathIterator {
* path if a ray drawn in any direction from that point to * path if a ray drawn in any direction from that point to
* infinity is crossed by path segments an odd number of times. * infinity is crossed by path segments an odd number of times.
*/ */
public static final int WIND_EVEN_ODD = 0; @Native public static final int WIND_EVEN_ODD = 0;
/** /**
* The winding rule constant for specifying a non-zero rule * The winding rule constant for specifying a non-zero rule
...@@ -80,20 +78,20 @@ public interface PathIterator { ...@@ -80,20 +78,20 @@ public interface PathIterator {
* of times in the counter-clockwise direction than the * of times in the counter-clockwise direction than the
* clockwise direction. * clockwise direction.
*/ */
public static final int WIND_NON_ZERO = 1; @Native public static final int WIND_NON_ZERO = 1;
/** /**
* The segment type constant for a point that specifies the * The segment type constant for a point that specifies the
* starting location for a new subpath. * starting location for a new subpath.
*/ */
public static final int SEG_MOVETO = 0; @Native public static final int SEG_MOVETO = 0;
/** /**
* The segment type constant for a point that specifies the * The segment type constant for a point that specifies the
* end point of a line to be drawn from the most recently * end point of a line to be drawn from the most recently
* specified point. * specified point.
*/ */
public static final int SEG_LINETO = 1; @Native public static final int SEG_LINETO = 1;
/** /**
* The segment type constant for the pair of points that specify * The segment type constant for the pair of points that specify
...@@ -115,7 +113,7 @@ public interface PathIterator { ...@@ -115,7 +113,7 @@ public interface PathIterator {
* = n! / (m! * (n-m)!) * = n! / (m! * (n-m)!)
* </pre> * </pre>
*/ */
public static final int SEG_QUADTO = 2; @Native public static final int SEG_QUADTO = 2;
/** /**
* The segment type constant for the set of 3 points that specify * The segment type constant for the set of 3 points that specify
...@@ -139,14 +137,14 @@ public interface PathIterator { ...@@ -139,14 +137,14 @@ public interface PathIterator {
* </pre> * </pre>
* This form of curve is commonly known as a B&eacute;zier curve. * This form of curve is commonly known as a B&eacute;zier curve.
*/ */
public static final int SEG_CUBICTO = 3; @Native public static final int SEG_CUBICTO = 3;
/** /**
* The segment type constant that specifies that * The segment type constant that specifies that
* the preceding subpath should be closed by appending a line segment * the preceding subpath should be closed by appending a line segment
* back to the point corresponding to the most recent SEG_MOVETO. * back to the point corresponding to the most recent SEG_MOVETO.
*/ */
public static final int SEG_CLOSE = 4; @Native public static final int SEG_CLOSE = 4;
/** /**
* Returns the winding rule for determining the interior of the * Returns the winding rule for determining the interior of the
......
/* /*
* Copyright (c) 1997, 2005, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -34,7 +34,7 @@ import java.awt.GraphicsEnvironment; ...@@ -34,7 +34,7 @@ import java.awt.GraphicsEnvironment;
import java.awt.Rectangle; import java.awt.Rectangle;
import java.awt.RenderingHints; import java.awt.RenderingHints;
import java.awt.Transparency; import java.awt.Transparency;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
import sun.awt.image.ImagingLib; import sun.awt.image.ImagingLib;
/** /**
...@@ -63,8 +63,6 @@ import sun.awt.image.ImagingLib; ...@@ -63,8 +63,6 @@ import sun.awt.image.ImagingLib;
* @see java.awt.RenderingHints#KEY_COLOR_RENDERING * @see java.awt.RenderingHints#KEY_COLOR_RENDERING
* @see java.awt.RenderingHints#KEY_DITHERING * @see java.awt.RenderingHints#KEY_DITHERING
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class AffineTransformOp implements BufferedImageOp, RasterOp { public class AffineTransformOp implements BufferedImageOp, RasterOp {
private AffineTransform xform; private AffineTransform xform;
RenderingHints hints; RenderingHints hints;
...@@ -72,17 +70,17 @@ public class AffineTransformOp implements BufferedImageOp, RasterOp { ...@@ -72,17 +70,17 @@ public class AffineTransformOp implements BufferedImageOp, RasterOp {
/** /**
* Nearest-neighbor interpolation type. * Nearest-neighbor interpolation type.
*/ */
public static final int TYPE_NEAREST_NEIGHBOR = 1; @Native public static final int TYPE_NEAREST_NEIGHBOR = 1;
/** /**
* Bilinear interpolation type. * Bilinear interpolation type.
*/ */
public static final int TYPE_BILINEAR = 2; @Native public static final int TYPE_BILINEAR = 2;
/** /**
* Bicubic interpolation type. * Bicubic interpolation type.
*/ */
public static final int TYPE_BICUBIC = 3; @Native public static final int TYPE_BICUBIC = 3;
int interpolationType = TYPE_NEAREST_NEIGHBOR; int interpolationType = TYPE_NEAREST_NEIGHBOR;
......
/* /*
* Copyright (c) 1997, 2000, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -30,7 +30,7 @@ import java.awt.geom.Rectangle2D; ...@@ -30,7 +30,7 @@ import java.awt.geom.Rectangle2D;
import java.awt.Rectangle; import java.awt.Rectangle;
import java.awt.RenderingHints; import java.awt.RenderingHints;
import java.awt.geom.Point2D; import java.awt.geom.Point2D;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
import sun.awt.image.ImagingLib; import sun.awt.image.ImagingLib;
/** /**
...@@ -66,8 +66,6 @@ import sun.awt.image.ImagingLib; ...@@ -66,8 +66,6 @@ import sun.awt.image.ImagingLib;
* @see java.awt.RenderingHints#KEY_COLOR_RENDERING * @see java.awt.RenderingHints#KEY_COLOR_RENDERING
* @see java.awt.RenderingHints#KEY_DITHERING * @see java.awt.RenderingHints#KEY_DITHERING
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class ConvolveOp implements BufferedImageOp, RasterOp { public class ConvolveOp implements BufferedImageOp, RasterOp {
Kernel kernel; Kernel kernel;
int edgeHint; int edgeHint;
...@@ -81,13 +79,13 @@ public class ConvolveOp implements BufferedImageOp, RasterOp { ...@@ -81,13 +79,13 @@ public class ConvolveOp implements BufferedImageOp, RasterOp {
* is the default. * is the default.
*/ */
public static final int EDGE_ZERO_FILL = 0; @Native public static final int EDGE_ZERO_FILL = 0;
/** /**
* Pixels at the edge of the source image are copied to * Pixels at the edge of the source image are copied to
* the corresponding pixels in the destination without modification. * the corresponding pixels in the destination without modification.
*/ */
public static final int EDGE_NO_OP = 1; @Native public static final int EDGE_NO_OP = 1;
/** /**
* Constructs a ConvolveOp given a Kernel, an edge condition, and a * Constructs a ConvolveOp given a Kernel, an edge condition, and a
......
/* /*
* Copyright (c) 1997, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -41,7 +41,7 @@ import sun.java2d.StateTrackableDelegate; ...@@ -41,7 +41,7 @@ import sun.java2d.StateTrackableDelegate;
import sun.awt.image.SunWritableRaster; import sun.awt.image.SunWritableRaster;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* This class exists to wrap one or more data arrays. Each data array in * This class exists to wrap one or more data arrays. Each data array in
...@@ -67,30 +67,28 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -67,30 +67,28 @@ import javax.tools.annotation.GenerateNativeHeader;
* @see java.awt.image.Raster * @see java.awt.image.Raster
* @see java.awt.image.SampleModel * @see java.awt.image.SampleModel
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public abstract class DataBuffer { public abstract class DataBuffer {
/** Tag for unsigned byte data. */ /** Tag for unsigned byte data. */
public static final int TYPE_BYTE = 0; @Native public static final int TYPE_BYTE = 0;
/** Tag for unsigned short data. */ /** Tag for unsigned short data. */
public static final int TYPE_USHORT = 1; @Native public static final int TYPE_USHORT = 1;
/** Tag for signed short data. Placeholder for future use. */ /** Tag for signed short data. Placeholder for future use. */
public static final int TYPE_SHORT = 2; @Native public static final int TYPE_SHORT = 2;
/** Tag for int data. */ /** Tag for int data. */
public static final int TYPE_INT = 3; @Native public static final int TYPE_INT = 3;
/** Tag for float data. Placeholder for future use. */ /** Tag for float data. Placeholder for future use. */
public static final int TYPE_FLOAT = 4; @Native public static final int TYPE_FLOAT = 4;
/** Tag for double data. Placeholder for future use. */ /** Tag for double data. Placeholder for future use. */
public static final int TYPE_DOUBLE = 5; @Native public static final int TYPE_DOUBLE = 5;
/** Tag for undefined data. */ /** Tag for undefined data. */
public static final int TYPE_UNDEFINED = 32; @Native public static final int TYPE_UNDEFINED = 32;
/** The data type of this DataBuffer. */ /** The data type of this DataBuffer. */
protected int dataType; protected int dataType;
......
/* /*
* Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,6 @@ package java.awt.image; ...@@ -27,7 +27,6 @@ package java.awt.image;
import java.util.Hashtable; import java.util.Hashtable;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* The interface for objects expressing interest in image data through * The interface for objects expressing interest in image data through
...@@ -39,8 +38,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -39,8 +38,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* *
* @author Jim Graham * @author Jim Graham
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface ImageConsumer { public interface ImageConsumer {
/** /**
* The dimensions of the source image are reported using the * The dimensions of the source image are reported using the
......
/* /*
* Copyright (c) 1995, 1999, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,6 @@ package java.awt.image; ...@@ -27,7 +27,6 @@ package java.awt.image;
import java.awt.Image; import java.awt.Image;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* An asynchronous update interface for receiving notifications about * An asynchronous update interface for receiving notifications about
...@@ -35,8 +34,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -35,8 +34,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* *
* @author Jim Graham * @author Jim Graham
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface ImageObserver { public interface ImageObserver {
/** /**
* This method is called when information about an image which was * This method is called when information about an image which was
......
/* /*
* Copyright (c) 1995, 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -32,7 +32,6 @@ import java.awt.image.ImageObserver; ...@@ -32,7 +32,6 @@ import java.awt.image.ImageObserver;
import java.awt.image.ColorModel; import java.awt.image.ColorModel;
import java.awt.image.VolatileImage; import java.awt.image.VolatileImage;
import java.awt.GraphicsConfiguration; import java.awt.GraphicsConfiguration;
import javax.tools.annotation.GenerateNativeHeader;
import sun.awt.CausedFocusEvent; import sun.awt.CausedFocusEvent;
import sun.java2d.pipe.Region; import sun.java2d.pipe.Region;
...@@ -50,8 +49,6 @@ import sun.java2d.pipe.Region; ...@@ -50,8 +49,6 @@ import sun.java2d.pipe.Region;
* nor invoke any of the peer methods directly on the peer * nor invoke any of the peer methods directly on the peer
* instances. * instances.
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface ComponentPeer { public interface ComponentPeer {
/** /**
......
/* /*
* Copyright (c) 1997, 2000, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -29,14 +29,12 @@ import java.awt.geom.AffineTransform; ...@@ -29,14 +29,12 @@ import java.awt.geom.AffineTransform;
import java.awt.geom.Point2D; import java.awt.geom.Point2D;
import java.awt.geom.Rectangle2D; import java.awt.geom.Rectangle2D;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The <code>PageFormat</code> class describes the size and * The <code>PageFormat</code> class describes the size and
* orientation of a page to be printed. * orientation of a page to be printed.
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public class PageFormat implements Cloneable public class PageFormat implements Cloneable
{ {
...@@ -48,21 +46,21 @@ public class PageFormat implements Cloneable ...@@ -48,21 +46,21 @@ public class PageFormat implements Cloneable
* Note that this is not the Macintosh landscape but * Note that this is not the Macintosh landscape but
* is the Window's and PostScript landscape. * is the Window's and PostScript landscape.
*/ */
public static final int LANDSCAPE = 0; @Native public static final int LANDSCAPE = 0;
/** /**
* The origin is at the top left of the paper with * The origin is at the top left of the paper with
* x running to the right and y running down the * x running to the right and y running down the
* paper. * paper.
*/ */
public static final int PORTRAIT = 1; @Native public static final int PORTRAIT = 1;
/** /**
* The origin is at the top right of the paper with x * The origin is at the top right of the paper with x
* running top to bottom and y running right to left. * running top to bottom and y running right to left.
* Note that this is the Macintosh landscape. * Note that this is the Macintosh landscape.
*/ */
public static final int REVERSE_LANDSCAPE = 2; @Native public static final int REVERSE_LANDSCAPE = 2;
/* Instance Variables */ /* Instance Variables */
......
/* /*
* Copyright (c) 1998, 2000, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
package java.awt.print; package java.awt.print;
import javax.tools.annotation.GenerateNativeHeader; import java.lang.annotation.Native;
/** /**
* The <code>Pageable</code> implementation represents a set of * The <code>Pageable</code> implementation represents a set of
...@@ -35,8 +35,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -35,8 +35,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @see java.awt.print.PageFormat * @see java.awt.print.PageFormat
* @see java.awt.print.Printable * @see java.awt.print.Printable
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface Pageable { public interface Pageable {
/** /**
...@@ -45,7 +43,7 @@ public interface Pageable { ...@@ -45,7 +43,7 @@ public interface Pageable {
* method if a <code>Pageable</code> implementation does not know * method if a <code>Pageable</code> implementation does not know
* the number of pages in its set. * the number of pages in its set.
*/ */
int UNKNOWN_NUMBER_OF_PAGES = -1; @Native int UNKNOWN_NUMBER_OF_PAGES = -1;
/** /**
* Returns the number of pages in the set. * Returns the number of pages in the set.
......
/* /*
* Copyright (c) 1997, 2005, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -27,7 +27,6 @@ package java.awt.print; ...@@ -27,7 +27,6 @@ package java.awt.print;
import java.awt.Graphics; import java.awt.Graphics;
import javax.tools.annotation.GenerateNativeHeader;
/** /**
* The <code>Printable</code> interface is implemented * The <code>Printable</code> interface is implemented
...@@ -100,8 +99,6 @@ import javax.tools.annotation.GenerateNativeHeader; ...@@ -100,8 +99,6 @@ import javax.tools.annotation.GenerateNativeHeader;
* @see java.awt.print.PageFormat * @see java.awt.print.PageFormat
* @see java.awt.print.PrinterJob * @see java.awt.print.PrinterJob
*/ */
/* No native methods here, but the constants are needed in the supporting JNI code */
@GenerateNativeHeader
public interface Printable { public interface Printable {
/** /**
......
...@@ -236,7 +236,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -236,7 +236,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
if ((index < 0) || (index >= count)) { if ((index < 0) || (index >= count)) {
throw new StringIndexOutOfBoundsException(index); throw new StringIndexOutOfBoundsException(index);
} }
return Character.codePointAt(value, index); return Character.codePointAtImpl(value, index, count);
} }
/** /**
...@@ -265,7 +265,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -265,7 +265,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
if ((i < 0) || (i >= count)) { if ((i < 0) || (i >= count)) {
throw new StringIndexOutOfBoundsException(index); throw new StringIndexOutOfBoundsException(index);
} }
return Character.codePointBefore(value, index); return Character.codePointBeforeImpl(value, index, 0);
} }
/** /**
...@@ -415,7 +415,8 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -415,7 +415,8 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
* @return a reference to this object. * @return a reference to this object.
*/ */
public AbstractStringBuilder append(String str) { public AbstractStringBuilder append(String str) {
if (str == null) str = "null"; if (str == null)
return appendNull();
int len = str.length(); int len = str.length();
ensureCapacityInternal(count + len); ensureCapacityInternal(count + len);
str.getChars(0, len, value, count); str.getChars(0, len, value, count);
...@@ -426,7 +427,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -426,7 +427,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
// Documentation in subclasses because of synchro difference // Documentation in subclasses because of synchro difference
public AbstractStringBuilder append(StringBuffer sb) { public AbstractStringBuilder append(StringBuffer sb) {
if (sb == null) if (sb == null)
return append("null"); return appendNull();
int len = sb.length(); int len = sb.length();
ensureCapacityInternal(count + len); ensureCapacityInternal(count + len);
sb.getChars(0, len, value, count); sb.getChars(0, len, value, count);
...@@ -439,7 +440,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -439,7 +440,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
*/ */
AbstractStringBuilder append(AbstractStringBuilder asb) { AbstractStringBuilder append(AbstractStringBuilder asb) {
if (asb == null) if (asb == null)
return append("null"); return appendNull();
int len = asb.length(); int len = asb.length();
ensureCapacityInternal(count + len); ensureCapacityInternal(count + len);
asb.getChars(0, len, value, count); asb.getChars(0, len, value, count);
...@@ -451,7 +452,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -451,7 +452,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
@Override @Override
public AbstractStringBuilder append(CharSequence s) { public AbstractStringBuilder append(CharSequence s) {
if (s == null) if (s == null)
s = "null"; return appendNull();
if (s instanceof String) if (s instanceof String)
return this.append((String)s); return this.append((String)s);
if (s instanceof AbstractStringBuilder) if (s instanceof AbstractStringBuilder)
...@@ -460,6 +461,18 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -460,6 +461,18 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
return this.append(s, 0, s.length()); return this.append(s, 0, s.length());
} }
private AbstractStringBuilder appendNull() {
int c = count;
ensureCapacityInternal(c + 4);
final char[] value = this.value;
value[c++] = 'n';
value[c++] = 'u';
value[c++] = 'l';
value[c++] = 'l';
count = c;
return this;
}
/** /**
* Appends a subsequence of the specified {@code CharSequence} to this * Appends a subsequence of the specified {@code CharSequence} to this
* sequence. * sequence.
...@@ -1370,32 +1383,37 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence { ...@@ -1370,32 +1383,37 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
* @return a reference to this object. * @return a reference to this object.
*/ */
public AbstractStringBuilder reverse() { public AbstractStringBuilder reverse() {
boolean hasSurrogate = false; boolean hasSurrogates = false;
int n = count - 1; int n = count - 1;
for (int j = (n-1) >> 1; j >= 0; --j) { for (int j = (n-1) >> 1; j >= 0; j--) {
char temp = value[j]; int k = n - j;
char temp2 = value[n - j]; char cj = value[j];
if (!hasSurrogate) { char ck = value[k];
hasSurrogate = (temp >= Character.MIN_SURROGATE && temp <= Character.MAX_SURROGATE) value[j] = ck;
|| (temp2 >= Character.MIN_SURROGATE && temp2 <= Character.MAX_SURROGATE); value[k] = cj;
if (Character.isSurrogate(cj) ||
Character.isSurrogate(ck)) {
hasSurrogates = true;
} }
value[j] = temp2;
value[n - j] = temp;
} }
if (hasSurrogate) { if (hasSurrogates) {
// Reverse back all valid surrogate pairs reverseAllValidSurrogatePairs();
for (int i = 0; i < count - 1; i++) { }
char c2 = value[i]; return this;
if (Character.isLowSurrogate(c2)) { }
char c1 = value[i + 1];
if (Character.isHighSurrogate(c1)) { /** Outlined helper method for reverse() */
value[i++] = c1; private void reverseAllValidSurrogatePairs() {
value[i] = c2; for (int i = 0; i < count - 1; i++) {
} char c2 = value[i];
if (Character.isLowSurrogate(c2)) {
char c1 = value[i + 1];
if (Character.isHighSurrogate(c1)) {
value[i++] = c1;
value[i] = c2;
} }
} }
} }
return this;
} }
/** /**
......
...@@ -4862,13 +4862,11 @@ class Character implements java.io.Serializable, Comparable<Character> { ...@@ -4862,13 +4862,11 @@ class Character implements java.io.Serializable, Comparable<Character> {
* @since 1.5 * @since 1.5
*/ */
public static int codePointAt(CharSequence seq, int index) { public static int codePointAt(CharSequence seq, int index) {
char c1 = seq.charAt(index++); char c1 = seq.charAt(index);
if (isHighSurrogate(c1)) { if (isHighSurrogate(c1) && ++index < seq.length()) {
if (index < seq.length()) { char c2 = seq.charAt(index);
char c2 = seq.charAt(index); if (isLowSurrogate(c2)) {
if (isLowSurrogate(c2)) { return toCodePoint(c1, c2);
return toCodePoint(c1, c2);
}
} }
} }
return c1; return c1;
...@@ -4931,15 +4929,13 @@ class Character implements java.io.Serializable, Comparable<Character> { ...@@ -4931,15 +4929,13 @@ class Character implements java.io.Serializable, Comparable<Character> {
return codePointAtImpl(a, index, limit); return codePointAtImpl(a, index, limit);
} }
// throws ArrayIndexOutofBoundsException if index out of bounds // throws ArrayIndexOutOfBoundsException if index out of bounds
static int codePointAtImpl(char[] a, int index, int limit) { static int codePointAtImpl(char[] a, int index, int limit) {
char c1 = a[index++]; char c1 = a[index];
if (isHighSurrogate(c1)) { if (isHighSurrogate(c1) && ++index < limit) {
if (index < limit) { char c2 = a[index];
char c2 = a[index]; if (isLowSurrogate(c2)) {
if (isLowSurrogate(c2)) { return toCodePoint(c1, c2);
return toCodePoint(c1, c2);
}
} }
} }
return c1; return c1;
...@@ -4968,12 +4964,10 @@ class Character implements java.io.Serializable, Comparable<Character> { ...@@ -4968,12 +4964,10 @@ class Character implements java.io.Serializable, Comparable<Character> {
*/ */
public static int codePointBefore(CharSequence seq, int index) { public static int codePointBefore(CharSequence seq, int index) {
char c2 = seq.charAt(--index); char c2 = seq.charAt(--index);
if (isLowSurrogate(c2)) { if (isLowSurrogate(c2) && index > 0) {
if (index > 0) { char c1 = seq.charAt(--index);
char c1 = seq.charAt(--index); if (isHighSurrogate(c1)) {
if (isHighSurrogate(c1)) { return toCodePoint(c1, c2);
return toCodePoint(c1, c2);
}
} }
} }
return c2; return c2;
...@@ -5038,15 +5032,13 @@ class Character implements java.io.Serializable, Comparable<Character> { ...@@ -5038,15 +5032,13 @@ class Character implements java.io.Serializable, Comparable<Character> {
return codePointBeforeImpl(a, index, start); return codePointBeforeImpl(a, index, start);
} }
// throws ArrayIndexOutofBoundsException if index-1 out of bounds // throws ArrayIndexOutOfBoundsException if index-1 out of bounds
static int codePointBeforeImpl(char[] a, int index, int start) { static int codePointBeforeImpl(char[] a, int index, int start) {
char c2 = a[--index]; char c2 = a[--index];
if (isLowSurrogate(c2)) { if (isLowSurrogate(c2) && index > start) {
if (index > start) { char c1 = a[--index];
char c1 = a[--index]; if (isHighSurrogate(c1)) {
if (isHighSurrogate(c1)) { return toCodePoint(c1, c2);
return toCodePoint(c1, c2);
}
} }
} }
return c2; return c2;
......
...@@ -113,8 +113,7 @@ import sun.reflect.misc.ReflectUtil; ...@@ -113,8 +113,7 @@ import sun.reflect.misc.ReflectUtil;
* @see java.lang.ClassLoader#defineClass(byte[], int, int) * @see java.lang.ClassLoader#defineClass(byte[], int, int)
* @since JDK1.0 * @since JDK1.0
*/ */
public final public final class Class<T> implements java.io.Serializable,
class Class<T> implements java.io.Serializable,
java.lang.reflect.GenericDeclaration, java.lang.reflect.GenericDeclaration,
java.lang.reflect.Type, java.lang.reflect.Type,
java.lang.reflect.AnnotatedElement { java.lang.reflect.AnnotatedElement {
...@@ -150,6 +149,75 @@ public final ...@@ -150,6 +149,75 @@ public final
+ getName(); + getName();
} }
/**
* Returns a string describing this {@code Class}, including
* information about modifiers and type parameters.
*
* The string is formatted as a list of type modifiers, if any,
* followed by the kind of type (empty string for primitive types
* and {@code class}, {@code enum}, {@code interface}, or {@code
* &#64;interface}, as appropriate), followed by the type's name,
* followed by an angle-bracketed comma-separated list of the
* type's type parameters, if any.
*
* A space is used to separate modifiers from one another and to
* separate any modifiers from the kind of type. The modifiers
* occur in canonical order. If there are no type parameters, the
* type parameter list is elided.
*
* <p>Note that since information about the runtime representation
* of a type is being generated, modifiers not present on the
* originating source code or illegal on the originating source
* code may be present.
*
* @return a string describing this {@code Class}, including
* information about modifiers and type parameters
*
* @since 1.8
*/
public String toGenericString() {
if (isPrimitive()) {
return toString();
} else {
StringBuilder sb = new StringBuilder();
// Class modifiers are a superset of interface modifiers
int modifiers = getModifiers() & Modifier.classModifiers();
if (modifiers != 0) {
sb.append(Modifier.toString(modifiers));
sb.append(' ');
}
if (isAnnotation()) {
sb.append('@');
}
if (isInterface()) { // Note: all annotation types are interfaces
sb.append("interface");
} else {
if (isEnum())
sb.append("enum");
else
sb.append("class");
}
sb.append(' ');
sb.append(getName());
TypeVariable<?>[] typeparms = getTypeParameters();
if (typeparms.length > 0) {
boolean first = true;
sb.append('<');
for(TypeVariable<?> typeparm: typeparms) {
if (!first)
sb.append(',');
sb.append(typeparm.getTypeName());
first = false;
}
sb.append('>');
}
return sb.toString();
}
}
/** /**
* Returns the {@code Class} object associated with the class or * Returns the {@code Class} object associated with the class or
...@@ -1163,6 +1231,32 @@ public final ...@@ -1163,6 +1231,32 @@ public final
return simpleName.substring(index); return simpleName.substring(index);
} }
/**
* Return an informative string for the name of this type.
*
* @return an informative string for the name of this type
* @since 1.8
*/
public String getTypeName() {
if (isArray()) {
try {
Class<?> cl = this;
int dimensions = 0;
while (cl.isArray()) {
dimensions++;
cl = cl.getComponentType();
}
StringBuilder sb = new StringBuilder();
sb.append(cl.getName());
for (int i = 0; i < dimensions; i++) {
sb.append("[]");
}
return sb.toString();
} catch (Throwable e) { /*FALLTHRU*/ }
}
return getName();
}
/** /**
* Character.isDigit answers {@code true} to some non-ascii * Character.isDigit answers {@code true} to some non-ascii
* digits. This one does not. * digits. This one does not.
......
...@@ -284,16 +284,20 @@ public final class Constructor<T> extends Executable { ...@@ -284,16 +284,20 @@ public final class Constructor<T> extends Executable {
* modifiers {@code public}, {@code protected} or * modifiers {@code public}, {@code protected} or
* {@code private}. Only one of these may appear, or none if the * {@code private}. Only one of these may appear, or none if the
* constructor has default (package) access. * constructor has default (package) access.
*
* @return a string describing this {@code Constructor}
* @jls 8.8.3. Constructor Modifiers
*/ */
public String toString() { public String toString() {
return sharedToString(Modifier.constructorModifiers(), return sharedToString(Modifier.constructorModifiers(),
false,
parameterTypes, parameterTypes,
exceptionTypes); exceptionTypes);
} }
@Override @Override
void specificToStringHeader(StringBuilder sb) { void specificToStringHeader(StringBuilder sb) {
sb.append(Field.getTypeName(getDeclaringClass())); sb.append(getDeclaringClass().getTypeName());
} }
/** /**
...@@ -328,10 +332,11 @@ public final class Constructor<T> extends Executable { ...@@ -328,10 +332,11 @@ public final class Constructor<T> extends Executable {
* include type parameters * include type parameters
* *
* @since 1.5 * @since 1.5
* @jls 8.8.3. Constructor Modifiers
*/ */
@Override @Override
public String toGenericString() { public String toGenericString() {
return sharedToGenericString(Modifier.constructorModifiers()); return sharedToGenericString(Modifier.constructorModifiers(), false);
} }
@Override @Override
......
...@@ -82,27 +82,38 @@ public abstract class Executable extends AccessibleObject ...@@ -82,27 +82,38 @@ public abstract class Executable extends AccessibleObject
void separateWithCommas(Class<?>[] types, StringBuilder sb) { void separateWithCommas(Class<?>[] types, StringBuilder sb) {
for (int j = 0; j < types.length; j++) { for (int j = 0; j < types.length; j++) {
sb.append(Field.getTypeName(types[j])); sb.append(types[j].getTypeName());
if (j < (types.length - 1)) if (j < (types.length - 1))
sb.append(","); sb.append(",");
} }
} }
void printModifiersIfNonzero(StringBuilder sb, int mask) { void printModifiersIfNonzero(StringBuilder sb, int mask, boolean isDefault) {
int mod = getModifiers() & mask; int mod = getModifiers() & mask;
if (mod != 0) {
if (mod != 0 && !isDefault) {
sb.append(Modifier.toString(mod)).append(' '); sb.append(Modifier.toString(mod)).append(' ');
} else {
int access_mod = mod & Modifier.ACCESS_MODIFIERS;
if (access_mod != 0)
sb.append(Modifier.toString(access_mod)).append(' ');
if (isDefault)
sb.append("default ");
mod = (mod & ~Modifier.ACCESS_MODIFIERS);
if (mod != 0)
sb.append(Modifier.toString(mod)).append(' ');
} }
} }
String sharedToString(int modifierMask, String sharedToString(int modifierMask,
boolean isDefault,
Class<?>[] parameterTypes, Class<?>[] parameterTypes,
Class<?>[] exceptionTypes) { Class<?>[] exceptionTypes) {
try { try {
StringBuilder sb = new StringBuilder(); StringBuilder sb = new StringBuilder();
printModifiersIfNonzero(sb, modifierMask); printModifiersIfNonzero(sb, modifierMask, isDefault);
specificToStringHeader(sb); specificToStringHeader(sb);
sb.append('('); sb.append('(');
...@@ -124,11 +135,11 @@ public abstract class Executable extends AccessibleObject ...@@ -124,11 +135,11 @@ public abstract class Executable extends AccessibleObject
*/ */
abstract void specificToStringHeader(StringBuilder sb); abstract void specificToStringHeader(StringBuilder sb);
String sharedToGenericString(int modifierMask) { String sharedToGenericString(int modifierMask, boolean isDefault) {
try { try {
StringBuilder sb = new StringBuilder(); StringBuilder sb = new StringBuilder();
printModifiersIfNonzero(sb, modifierMask); printModifiersIfNonzero(sb, modifierMask, isDefault);
TypeVariable<?>[] typeparms = getTypeParameters(); TypeVariable<?>[] typeparms = getTypeParameters();
if (typeparms.length > 0) { if (typeparms.length > 0) {
...@@ -150,9 +161,7 @@ public abstract class Executable extends AccessibleObject ...@@ -150,9 +161,7 @@ public abstract class Executable extends AccessibleObject
sb.append('('); sb.append('(');
Type[] params = getGenericParameterTypes(); Type[] params = getGenericParameterTypes();
for (int j = 0; j < params.length; j++) { for (int j = 0; j < params.length; j++) {
String param = (params[j] instanceof Class)? String param = params[j].getTypeName();
Field.getTypeName((Class)params[j]):
(params[j].toString());
if (isVarArgs() && (j == params.length - 1)) // replace T[] with T... if (isVarArgs() && (j == params.length - 1)) // replace T[] with T...
param = param.replaceFirst("\\[\\]$", "..."); param = param.replaceFirst("\\[\\]$", "...");
sb.append(param); sb.append(param);
......
...@@ -43,8 +43,7 @@ import sun.reflect.ReflectionFactory; ...@@ -43,8 +43,7 @@ import sun.reflect.ReflectionFactory;
* @author Nakul Saraiya * @author Nakul Saraiya
* @author Kenneth Russell * @author Kenneth Russell
*/ */
public public class Modifier {
class Modifier {
/* /*
* Bootstrapping protocol between java.lang and java.lang.reflect * Bootstrapping protocol between java.lang and java.lang.reflect
...@@ -233,7 +232,7 @@ class Modifier { ...@@ -233,7 +232,7 @@ class Modifier {
* represented by {@code mod} * represented by {@code mod}
*/ */
public static String toString(int mod) { public static String toString(int mod) {
StringBuffer sb = new StringBuffer(); StringBuilder sb = new StringBuilder();
int len; int len;
if ((mod & PUBLIC) != 0) sb.append("public "); if ((mod & PUBLIC) != 0) sb.append("public ");
...@@ -389,6 +388,12 @@ class Modifier { ...@@ -389,6 +388,12 @@ class Modifier {
Modifier.STATIC | Modifier.FINAL | Modifier.TRANSIENT | Modifier.STATIC | Modifier.FINAL | Modifier.TRANSIENT |
Modifier.VOLATILE; Modifier.VOLATILE;
/**
*
*/
static final int ACCESS_MODIFIERS =
Modifier.PUBLIC | Modifier.PROTECTED | Modifier.PRIVATE;
/** /**
* Return an {@code int} value OR-ing together the source language * Return an {@code int} value OR-ing together the source language
* modifiers that can be applied to a class. * modifiers that can be applied to a class.
......
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册