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

com.pesegato.mermaid.PRadioGroup Maven / Gradle / Ivy

The newest version!
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.pesegato.mermaid;

import java.util.ArrayList;

/**
 *
 */
public class PRadioGroup {

    ArrayList pSwitchs = new ArrayList();
    PrismaticPane pp;
    int currentlyPressed=0;

    public void addSwitch(PSwitch pswitch) {
        pSwitchs.add(pswitch);
        pswitch.setRadioGroup(this);
    }
    
    public void setPrismaticPane(PrismaticPane pp){
        this.pp=pp;
    }

    void pressed(int number) {
        for (int i = 0; i < pSwitchs.size(); i++) {
            if (i != number) {
                pSwitchs.get(i).release();
            }
        }
        int numGiri=0;
        if (number




© 2015 - 2024 Weber Informatics LLC | Privacy Policy