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

com.harium.etyl.ui.ButtonList Maven / Gradle / Ivy

There is a newer version: 1.0.18
Show newest version
package com.harium.etyl.ui;

import java.awt.Color;
import java.util.ArrayList;
import java.util.List;

import com.harium.etyl.commons.event.KeyEvent;
import com.harium.etyl.commons.event.PointerEvent;
import com.harium.etyl.commons.event.GUIEvent;
import com.harium.etyl.core.graphics.Graphics;
import com.harium.etyl.ui.base.BaseButton;

/**
 * 
 * @author yuripourre
 *
 */

public class ButtonList extends View{
	
	List buttons = new ArrayList();
	
	public ButtonList(int x, int y, int w, int h){
		super(x, y, w, h);
	}

	@Override
	public GUIEvent updateMouse(PointerEvent event){
		
		for(BaseButton button: buttons){
			button.updateMouse(event);
		}
		
		return GUIEvent.NONE;
	}

	@Override
	public void updateEvent(GUIEvent event) {
		// TODO Auto-generated method stub
		
	}
	
	//TODO Desenha o botao ou o scroll 
	public void draw(Graphics g){
		
		//BufferedImage bimg = g.getBimg();
		
		//g.setBimg(bimg.getSubimage(0, y, w, h));
		
		for(BaseButton button: buttons){
			if(button.getY()




© 2015 - 2025 Weber Informatics LLC | Privacy Policy