From: <eli...@us...> - 2006-07-14 08:32:44
|
Revision: 2509 Author: elias_naur Date: 2006-07-14 01:32:01 -0700 (Fri, 14 Jul 2006) ViewCVS: http://svn.sourceforge.net/java-game-lib/?rev=2509&view=rev Log Message: ----------- Added a Controllers applet test Modified Paths: -------------- trunk/LWJGL/applet/applet.html trunk/LWJGL/build.xml trunk/LWJGL/libs/jinput.jar Added Paths: ----------- trunk/LWJGL/src/java/org/lwjgl/test/applet/ControllersTest.java Modified: trunk/LWJGL/applet/applet.html =================================================================== --- trunk/LWJGL/applet/applet.html 2006-07-13 18:56:19 UTC (rev 2508) +++ trunk/LWJGL/applet/applet.html 2006-07-14 08:32:01 UTC (rev 2509) @@ -1,6 +1,6 @@ <html> <body> - <applet code="org.lwjgl.test.applet.AppletTest" archive="lwjgl_applet.jar,lwjgl_util_applet.jar,lwjgl.jar,res.jar,lwjgl_util.jar,lwjgl_fmod3.jar,lwjgl_devil.jar,natives.jar" width="640" height="480"> + <applet code="org.lwjgl.test.applet.AppletTest" archive="lwjgl_applet.jar,lwjgl_util_applet.jar,lwjgl.jar,res.jar,lwjgl_util.jar,lwjgl_fmod3.jar,lwjgl_devil.jar,natives.jar,jinput.jar" width="640" height="480"> <param name="test" value="org.lwjgl.test.applet.OpenGL"> </applet> </body> Modified: trunk/LWJGL/build.xml =================================================================== --- trunk/LWJGL/build.xml 2006-07-13 18:56:19 UTC (rev 2508) +++ trunk/LWJGL/build.xml 2006-07-14 08:32:01 UTC (rev 2509) @@ -359,7 +359,7 @@ <condition property="native_path" value="libs/macosx"> <os name="Mac OS X" /> </condition> - <java classname="${test.mainclass}" classpath="${lwjgl.lib}/lwjgl.jar:${lwjgl.lib}/lwjgl_util.jar:${lwjgl.lib}/lwjgl_test.jar" fork="true"> + <java classname="${test.mainclass}" classpath="${lwjgl.lib}/lwjgl.jar:${lwjgl.lib}/lwjgl_util.jar:${lwjgl.lib}/lwjgl_test.jar:${lwjgl.lib}/jinput.jar" fork="true"> <jvmarg value="-Dorg.lwjgl.util.Debug=true"/> <jvmarg value="-Djava.library.path=${native_path}"/> </java> @@ -416,10 +416,12 @@ <copy file="${lwjgl.lib}/lwjgl_util.jar" todir="applet"/> <copy file="${lwjgl.lib}/lwjgl_fmod3.jar" todir="applet"/> <copy file="${lwjgl.lib}/lwjgl_devil.jar" todir="applet"/> + <copy file="${lwjgl.lib}/jinput.jar" todir="applet"/> <zip destfile="applet/res.jar"> <zipfileset dir="${lwjgl.res}" includes="Footsteps.wav, ILtest.tga, Missing_you.mod"/> </zip> <signjar jar="applet/lwjgl.jar" alias="lwjgl" keystore="applet/lwjglkeystore" storepass="123456"/> + <signjar jar="applet/jinput.jar" alias="lwjgl" keystore="applet/lwjglkeystore" storepass="123456"/> <signjar jar="applet/lwjgl_util_applet.jar" alias="lwjgl" keystore="applet/lwjglkeystore" storepass="123456"/> <signjar jar="applet/lwjgl_fmod3.jar" alias="lwjgl" keystore="applet/lwjglkeystore" storepass="123456"/> <signjar jar="applet/lwjgl_devil.jar" alias="lwjgl" keystore="applet/lwjglkeystore" storepass="123456"/> Modified: trunk/LWJGL/libs/jinput.jar =================================================================== (Binary files differ) Added: trunk/LWJGL/src/java/org/lwjgl/test/applet/ControllersTest.java =================================================================== --- trunk/LWJGL/src/java/org/lwjgl/test/applet/ControllersTest.java (rev 0) +++ trunk/LWJGL/src/java/org/lwjgl/test/applet/ControllersTest.java 2006-07-14 08:32:01 UTC (rev 2509) @@ -0,0 +1,52 @@ +/* + * Copyright (c) 2006 LWJGL Project + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * * Neither the name of 'LWJGL' nor the names of + * its contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +package org.lwjgl.test.applet; + +import java.awt.Canvas; + +import org.lwjgl.LWJGLException; +import org.lwjgl.input.Controllers; + +public class ControllersTest extends Canvas implements Test { + public void start() { + try { + Controllers.create(); + } catch (LWJGLException e) { + e.printStackTrace(); + return; + } + System.out.println("Controllers.getControllerCount() = " + Controllers.getControllerCount()); + } + + public void stop() { + } +} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |