src/codeandchords/ModuleMenu.java
public void buttonEvent(int id)
	{
		System.out.print("ModuleMenu: got buttonEvent with id " + id);

		this.fillHSBColors();

		// Reset whichever of the sliders is applicable:
		if(this.firstRGBSliderId > 0)
		{
			this.resetRGBSlidersTextfields();
			this.applyRGBModulate();
		}
		if(this.firstHSBSliderId > 0)
		{
			this.resetHSBSlidersTextfields();
			this.applyHSBModulate();
		}

		int	colorPos;
		int	cwId	= (id % 100) + 300;

		// if from colorSelect, set the ColorWheel to the correct color:
		if(cwId >= this.firstColorSelectCWId && cwId < (this.firstColorSelectCWId + colors[this.currentInput].length) && cwId != this.canvasColorSelectId)
		{
			colorPos	= (id % 100) - (this.firstColorSelectCWId % 100);
			System.out.println("Button event: about to call colorSelectCW for colorPos " + colorPos);
			/*
			 * Hey - it calls this with whatever is in colors currently... 
			 * So if dichrom put it there == oh wait, but that's for current input. So never mind. :P
			 */
			this.setColorSelectCW(colorPos, this.colors[this.currentInput][colorPos]);
		} else if(cwId >= this.firstSpecialColorsCWId && cwId < (this.firstSpecialColorsCWId + this.specialColorsPos[0].length))
		{
			// or if from specialColors, set that ColorWheel:
			colorPos	= (id % 100) - (this.firstSpecialColorsCWId % 100);
			System.out.println("specialColors colorPos = " + colorPos);
			this.setSpecialColorsCW(colorPos, this.colors[this.currentInput][this.specialColorsPos[this.currentInput][colorPos]]);
		}
	}
/**
	 * Called from MenuTemplate for Buttons that were added by the addColorWheelGroup() method and are 
	 * connected to a CW and CWTextfield (MenuTemplate has already updated the CW and Textfield values).
	 */
Called from MenuTemplate for Buttons that were added by the addColorWheelGroup() method and are
connected to a CW and CWTextfield (MenuTemplate has already updated the CW and Textfield values).
Called from MenuTemplate for Buttons that were added by the addColorWheelGroup () method and are connected to a CW and CWTextfield ( MenuTemplate has already updated the CW and Textfield values ) .
public void buttonEvent(int id)
	{
		System.out.print("ModuleMenu: got buttonEvent with id " + id);
		this.fillHSBColors();
		if(this.firstRGBSliderId > 0)
		{
			this.resetRGBSlidersTextfields();
			this.applyRGBModulate();
		}
		if(this.firstHSBSliderId > 0)
		{
			this.resetHSBSlidersTextfields();
			this.applyHSBModulate();
		}
		int	colorPos;
		int	cwId	= (id % 100) + 300;
		if(cwId >= this.firstColorSelectCWId && cwId < (this.firstColorSelectCWId + colors[this.currentInput].length) && cwId != this.canvasColorSelectId)
		{
			colorPos	= (id % 100) - (this.firstColorSelectCWId % 100);
			System.out.println("Button event: about to call colorSelectCW for colorPos " + colorPos);
			/*
			 * Hey - it calls this with whatever is in colors currently... 
			 * So if dichrom put it there == oh wait, but that's for current input. So never mind. :P
			 */
			this.setColorSelectCW(colorPos, this.colors[this.currentInput][colorPos]);
		} else if(cwId >= this.firstSpecialColorsCWId && cwId < (this.firstSpecialColorsCWId + this.specialColorsPos[0].length))
		{
			colorPos	= (id % 100) - (this.firstSpecialColorsCWId % 100);
			System.out.println("specialColors colorPos = " + colorPos);
			this.setSpecialColorsCW(colorPos, this.colors[this.currentInput][this.specialColorsPos[this.currentInput][colorPos]]);
		}
	}
public void buttonEvent ( int id ) { System . out . print ( "ModuleMenu: got buttonEvent with id " + id ) ; this . fillHSBColors ( ) ; if ( this . firstRGBSliderId > 0 ) { this . resetRGBSlidersTextfields ( ) ; this . applyRGBModulate ( ) ; } if ( this . firstHSBSliderId > 0 ) { this . resetHSBSlidersTextfields ( ) ; this . applyHSBModulate ( ) ; } int colorPos ; int cwId = ( id % 100 ) + 300 ; if ( cwId >= this . firstColorSelectCWId && cwId < ( this . firstColorSelectCWId + colors [ this . currentInput ] . length ) && cwId != this . canvasColorSelectId ) { colorPos = ( id % 100 ) - ( this . firstColorSelectCWId % 100 ) ; System . out . println ( "Button event: about to call colorSelectCW for colorPos " + colorPos ) ; /*
			 * Hey - it calls this with whatever is in colors currently... 
			 * So if dichrom put it there == oh wait, but that's for current input. So never mind. :P
			 */ this . setColorSelectCW ( colorPos , this . colors [ this . currentInput ] [ colorPos ] ) ; } else if ( cwId >= this . firstSpecialColorsCWId && cwId < ( this . firstSpecialColorsCWId + this . specialColorsPos [ 0 ] . length ) ) { colorPos = ( id % 100 ) - ( this . firstSpecialColorsCWId % 100 ) ; System . out . println ( "specialColors colorPos = " + colorPos ) ; this . setSpecialColorsCW ( colorPos , this . colors [ this . currentInput ] [ this . specialColorsPos [ this . currentInput ] [ colorPos ] ] ) ; } }
Called from MenuTemplate for Buttons that were added by the addColorWheelGroup() method and are
 connected to a CW and CWTextfield (MenuTemplate has already updated the CW and Textfield values).
Called from MenuTemplate for Buttons that were added by the addColorWheelGroup () method and are connected to a CW and CWTextfield ( MenuTemplate has already updated the CW and Textfield values ) .
// Reset whichever of the sliders is applicable: // if from colorSelect, set the ColorWheel to the correct color: // or if from specialColors, set that ColorWheel: