applet

How to send audio data from Java Applet to Rails controller

Hi, I have to send the audio data in byte array obtain by recording from java applet at the client side to rails server at the controller in order to save. So, what encoding parameters at the applet side be used and in what form the audio data be converted like String or byte array so that rails correctly recieve data and then I can s...

Java Applet Graphics

I have class A class A extends JApllet { private B b; .... public void init() { // draw text getContentPane().add(new JLabel("First"), BorderLayout.CENTER); b = new B(); } } class B{ private C c; b(){ c = new C(); } } class C{ C(){ // And there I need draw Text ("Second") on Applet Panel } } How I ca...

Java for-loop problem

The problem is that I am trying to make certain tiles blocked so the player cannot walk on them. However, it's only reading the FIRST tile which is board[0][0] and everything else is not checked.... What am I doing wrong? :( Here's my code: import java.applet.*; import java.applet.Applet; import java.awt.*; import java.awt.Canvas.*; ...

How do I detect an array

OK so, is there an efficient way to detect on what array you're currently on by using the KeyListener? My code: http://www.javadan.pastebin.com/X68VyuGL What I am trying to do here is see if the current tile I am on is BLOCKED. Thanks. ...

GWTAI applet integration in GWT problem

Hi everybody. I'm working with gwtai to integrate a java applet into my gwt - project. Basic communication from my main application to the applet (such as invoking simple methods that return int or boolean values) works. But the main reason why I need to integrate this applet is, that I need it to connect to another server and receive ...

int[][] array not working - java applet

OK so the array is not working. My code: http://www.javadan.pastebin.com/C9QiVySe I am trying to check if blocked(lastX,lastY) of the following tile he is on. I count the tile the player is standing on by adding or minusing X and Y when they go up, down, left, or right. So if the player starts at 0,0, they press down twice and right on...

Java Applet - ArrayIndexOutOfBoundsException

OK so I am getting an ArrayIndexOutofBoundsException. I don't know why. Here's my code: /** Tile Generator Programmer: Dan J. Thanks to: g00se, pbl. Started May 23, 2010 **/ import java.awt.*; import java.awt.event.*; import java.applet.Applet; public class tileGen extends Applet implements KeyListener { Image[] tiles; // tile...

get direction google map api, how to use in applet

hi i hav an mapviewer applet with my map images and all of feautre need to word correctly(geo coordinate to pixel coordinate an viceversa , zoom in and out , ...) so i want to add a thing like Get Direction on google map to my mapviewer, can i use google api in my applet? how ? or is any suggestion to do that? ...

Java Applet - ArrayIndexOutOfBoundsException (pt 2)

Hi there, I fixed my previous problem. But now when on my tile map... if I try to go 9 tiles to the RIGHT, and on trying to get to the 9th tile.... I will get this error: Exception in thread "AWT-EventQueue-1" java.lang.ArrayIndexOutOfBoundsException: 8 at tileGen.blocked(tileGen.java:125) at tileGen.keyPressed(tileGen.java:58) ...

How do I send data from Java to Flash locally?

I have a website with a Java applet and a Flash application. I want the Java applet to send data to the Flash application locally. What's the best way to do this? The data I want to send are potentially large images (possibly up to 1MB in size). This means sending a base64 string to javascript and then to Flash would probably be too...

Calling Applets methods using Java Script hangs browser when JRE is disabled

Hi All , The applet methods work fine when JRE is enabled document.appletName.methodName() ; // Using Java Script . But when JRE is disabled using the Java Control Panel . on call of " document.appletName.methodName() " method , the browser starts to hang . How can we make the browser not to hang !! I am using Object Tag . Any...

java applet - array checking

OK so my code is here: http://www.so.pastebin.com/m7V8rQ2n What I want to know... let's say I have an image which I can redraw on tiles... is there a way to check for future tiles so I DON'T go out of bounds of my already defined tile map? Like if I were at the edge of a map... it would NOT let me go past it? Thanks. ...

New Session is created between consecutive servlet request from an Applet and a managed bean??

Hi, I want to pass parameters betweeen applet and jsf components So when a value of a input textbox changed, its binding backing bean makes connection to a servlet. The servlet create an attribute and save to HttpSession using (request.getSession(true)).setAttribute(name, value); Then at some event, applet will access another servlet. ...

JPopupMenu should not lose focus

Hello everyone, Question about JPopupMenu behavior. I would like the JPopupMenu not to loose focus when it comes up. Also when JPopupMenu is in focus, the user should be able to click/update other parts of the Applet. Is this possible? Reason is that this JPopupMenu is displaying some codes and it needs to be kept open for reference....

Javascript library to reliably delay-load java applets

I'd like to delay-load a Java Applet in the same way that SwfObject loads Flash SWFs-- you supply it a div id and it replaces the div's contents. This would allow the whole page to load before the Applet starts. However, I'd also like to use a best-practices Javascript library like deployJava.js or applet-fu. The problem with these li...

Improving legacy Java Applets both Performance and Appearance

I have a rather large legacy Java Applet that has several problems: It looks like shi$%#$ It loads up slowly It hangs on some browsers occasionally even with the latest JRE Because Java Applets have kind of gone the way of the dodo bird I can't find any recent reliable information on how to mitigate these problems. That being said I...

"java.lang.OutOfMemoryError: Java heap space" in image and array storage

I am currently working on an image processing demonstration in java (Applet). I am running into the problem where my arrays are too large and I am getting the "java.lang.OutOfMemoryError: Java heap space" error. The algorithm I run creates an NxD float array where: N is the number of pixel in the image and D is the coordinates of each ...

If applets are run in browser's JRE, why is a JRE needed on the machine?

Applets are run inside browser's JRE. Does this mean that you do not have to have JRE installed on your machine in order to run an applet? ...

How can I use Java to read/draw/interact with another Java window/applet

I am interested in writing a Java program which does the following. Attach to a currently running Swing window or applet, running in another JVM Alternatively, load a Java application so as to be able to do the above Read colors from the window Send mouse and keyboard events to the window I am hoping to make some sort of testing an...

java - POST vs JDBC

OK so here's the code: import java.io.BufferedReader; import java.io.InputStreamReader; import java.net.URL; public class Main { public static void main(String[] args) { try { URL my_url = new URL("http://www.viralpatel.net/blogs/"); BufferedReader br = new BufferedReader(new InputStreamReader(my_url...