All Downloads are FREE. Search and download functionalities are using the official Maven repository.

java.com.generationjava.swing.MultiImagePanel Maven / Gradle / Ivy

The newest version!
package com.generationjava.swing;

import java.awt.Image;
import java.awt.Graphics;
import javax.swing.JPanel;
import java.util.ArrayList;
import java.util.List;


public class MultiImagePanel extends JPanel {

    // should we use BorderLayout consts here?
    static public final String EAST  = "EAST";
    static public final String NORTH = "NORTH";
    static public final String WEST  = "WEST";
    static public final String SOUTH = "SOUTH";

    private ArrayList myImages    = new ArrayList();
    private ArrayList myPositions = new ArrayList();

    public MultiImagePanel() {
    }

    public void paint(Graphics g) {
        super.paint(g);
        List imgs = getImages();
        if(imgs == null) return;
        int n = numberOfImages();
        for(int i=0;i




© 2015 - 2024 Weber Informatics LLC | Privacy Policy