Skip to content

Instantly share code, notes, and snippets.

@Brobin
Created February 18, 2014 21:11
Show Gist options
  • Save Brobin/9080180 to your computer and use it in GitHub Desktop.
Save Brobin/9080180 to your computer and use it in GitHub Desktop.
Compile and run you must
import java.net.MalformedURLException;
import java.net.URL;
import javax.swing.ImageIcon;
import javax.swing.JLabel;
import javax.swing.JOptionPane;
/**
* I got bored one day while learning about GUIs so I made this.
* */
public class Yoda {
public static void main(String[] args) {
try {
final URL gif = new URL(
"http://25.media.tumblr.com/070bcb9304068ca5a7740870f580312b/tumblr_msojo9T7y21rdrzfmo1_500.gif");
JLabel dancingYoda = new JLabel(new ImageIcon(gif));
JOptionPane.showMessageDialog(null, dancingYoda,
"Yoda FTW", JOptionPane.PLAIN_MESSAGE);
} catch (MalformedURLException e) {
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment