Skip to content

Commit

Permalink
Rename AccessibilityUtil => AccessibilityUtils, see phetsims/tasks#966
Browse files Browse the repository at this point in the history
  • Loading branch information
samreid committed Dec 30, 2019
1 parent 1206799 commit 0f81984
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions js/CCKCUtil.js → js/CCKCUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ define( require => {
const currentUnitsString = require( 'string!CIRCUIT_CONSTRUCTION_KIT_COMMON/currentUnits' );
const voltageUnitsString = require( 'string!CIRCUIT_CONSTRUCTION_KIT_COMMON/voltageUnits' );

const CCKCUtil = {
const CCKCUtils = {

/**
* Typically show 2 decimal places for current and voltage readouts in the play area, but if it is a smaller value,
Expand Down Expand Up @@ -74,5 +74,5 @@ define( require => {
}
};

return circuitConstructionKitCommon.register( 'CCKCUtil', CCKCUtil );
return circuitConstructionKitCommon.register( 'CCKCUtils', CCKCUtils );
} );
4 changes: 2 additions & 2 deletions js/view/AmmeterNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ define( require => {
// modules
const BooleanProperty = require( 'AXON/BooleanProperty' );
const CCKCConstants = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCConstants' );
const CCKCUtil = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtil' );
const CCKCUtils = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtils' );
const circuitConstructionKitCommon = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/circuitConstructionKitCommon' );
const Color = require( 'SCENERY/util/Color' );
const DerivedProperty = require( 'AXON/DerivedProperty' );
Expand Down Expand Up @@ -91,7 +91,7 @@ define( require => {
// Ammeters in this sim only show positive values, not direction (which is arbitrary anyways)
return current === null ? questionMarkString :
Math.abs( current ) > max ? maxString :
CCKCUtil.createCurrentReadout( current );
CCKCUtils.createCurrentReadout( current );
} );

const probeTextNode = new ProbeTextNode(
Expand Down
6 changes: 3 additions & 3 deletions js/view/CircuitLayerNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ define( require => {
const InductorNode = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/view/InductorNode' );
const CCKCConstants = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCConstants' );
const CCKCLightBulbNode = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/view/CCKCLightBulbNode' );
const CCKCUtil = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtil' );
const CCKCUtils = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtils' );
const ChargeNode = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/view/ChargeNode' );
const circuitConstructionKitCommon = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/circuitConstructionKitCommon' );
const CircuitElementNode = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/view/CircuitElementNode' );
Expand Down Expand Up @@ -275,12 +275,12 @@ define( require => {
Tandem.OPTIONAL
);

const updateShowValues = showValues => CCKCUtil.setInSceneGraph( showValues, this.valueLayer, valueNode );
const updateShowValues = showValues => CCKCUtils.setInSceneGraph( showValues, this.valueLayer, valueNode );
this.model.showValuesProperty.link( updateShowValues );

circuitElement.disposeEmitterCircuitElement.addListener( () => {
this.model.showValuesProperty.unlink( updateShowValues );
CCKCUtil.setInSceneGraph( false, this.valueLayer, valueNode );
CCKCUtils.setInSceneGraph( false, this.valueLayer, valueNode );
valueNode.dispose();
} );
}
Expand Down
6 changes: 3 additions & 3 deletions js/view/FixedCircuitElementNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ define( require => {
'use strict';

// modules
const CCKCUtil = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtil' );
const CCKCUtils = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtils' );
const circuitConstructionKitCommon = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/circuitConstructionKitCommon' );
const CircuitElementNode = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/view/CircuitElementNode' );
const CircuitElementViewType = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/model/CircuitElementViewType' );
Expand Down Expand Up @@ -268,7 +268,7 @@ define( require => {
*/
setSelectedCircuitElement( circuitElement ) {
const visible = ( circuitElement === this.circuitElement );
CCKCUtil.setInSceneGraph( visible, this.circuitLayerNode.highlightLayer, this.highlightNode );
CCKCUtils.setInSceneGraph( visible, this.circuitLayerNode.highlightLayer, this.highlightNode );
this.markAsDirty();
}

Expand All @@ -285,7 +285,7 @@ define( require => {
this.circuitElement.connectedEmitter.removeListener( this.moveToFrontListener );
this.circuitElement.vertexSelectedEmitter.removeListener( this.moveToFrontListener );
this.fixedCircuitElementNodePickable && this.circuitElement.interactiveProperty.unlink( this.pickableListener );
this.circuitLayerNode && this.highlightNode && CCKCUtil.setInSceneGraph( false, this.circuitLayerNode.highlightLayer, this.highlightNode );
this.circuitLayerNode && this.highlightNode && CCKCUtils.setInSceneGraph( false, this.circuitLayerNode.highlightLayer, this.highlightNode );
this.viewTypeProperty.unlink( this.viewPropertyListener );

if ( !this.isIcon && this.updateFireMultilink ) {
Expand Down
4 changes: 2 additions & 2 deletions js/view/SeriesAmmeterNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ define( require => {

// modules
const CCKCConstants = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCConstants' );
const CCKCUtil = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtil' );
const CCKCUtils = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtils' );
const circuitConstructionKitCommon = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/circuitConstructionKitCommon' );
const CircuitElementViewType = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/model/CircuitElementViewType' );
const Color = require( 'SCENERY/util/Color' );
Expand Down Expand Up @@ -89,7 +89,7 @@ define( require => {
if ( startConnection && endConnection ) {

// The ammeter doesn't indicate direction
readout = CCKCUtil.createCurrentReadout( seriesAmmeter.currentProperty.get() );
readout = CCKCUtils.createCurrentReadout( seriesAmmeter.currentProperty.get() );
}
}

Expand Down
10 changes: 5 additions & 5 deletions js/view/VertexNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ define( require => {
// modules
const CCKCConstants = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCConstants' );
const CCKCQueryParameters = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCQueryParameters' );
const CCKCUtil = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtil' );
const CCKCUtils = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtils' );
const Circle = require( 'SCENERY/nodes/Circle' );
const circuitConstructionKitCommon = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/circuitConstructionKitCommon' );
const Color = require( 'SCENERY/util/Color' );
Expand Down Expand Up @@ -230,8 +230,8 @@ define( require => {
vertex.selectedProperty.unlink( this.updateSelectedListener );
vertex.interactiveProperty.unlink( this.updatePickableListener );
vertex.relayerEmitter.removeListener( this.updateMoveToFront );
CCKCUtil.setInSceneGraph( false, circuitLayerNode.buttonLayer, cutButton );
CCKCUtil.setInSceneGraph( false, circuitLayerNode.highlightLayer, this.highlightNode );
CCKCUtils.setInSceneGraph( false, circuitLayerNode.buttonLayer, cutButton );
CCKCUtils.setInSceneGraph( false, circuitLayerNode.highlightLayer, this.highlightNode );
circuit.vertexGroup.removeMemberCreatedListener( this.updateStrokeListener );
circuit.vertexGroup.removeMemberDisposedListener( this.updateStrokeListener );

Expand Down Expand Up @@ -288,9 +288,9 @@ define( require => {
this.moveToFront();
this.focus();
}
CCKCUtil.setInSceneGraph( selected, this.circuitLayerNode.highlightLayer, this.highlightNode );
CCKCUtils.setInSceneGraph( selected, this.circuitLayerNode.highlightLayer, this.highlightNode );
const numberConnections = neighborCircuitElements.length;
CCKCUtil.setInSceneGraph( selected, this.circuitLayerNode.buttonLayer, this.cutButton );
CCKCUtils.setInSceneGraph( selected, this.circuitLayerNode.buttonLayer, this.cutButton );
selected && this.updateCutButtonPosition();

// Show a disabled button as a cue that the vertex could be cuttable, but it isn't right now.
Expand Down
4 changes: 2 additions & 2 deletions js/view/VoltmeterNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ define( require => {
const BooleanProperty = require( 'AXON/BooleanProperty' );
const CCKCConstants = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCConstants' );
const CCKCQueryParameters = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCQueryParameters' );
const CCKCUtil = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtil' );
const CCKCUtils = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/CCKCUtils' );
const circuitConstructionKitCommon = require( 'CIRCUIT_CONSTRUCTION_KIT_COMMON/circuitConstructionKitCommon' );
const Color = require( 'SCENERY/util/Color' );
const DerivedProperty = require( 'AXON/DerivedProperty' );
Expand Down Expand Up @@ -106,7 +106,7 @@ define( require => {

// Displays the voltage reading
const voltageReadoutProperty = new DerivedProperty( [ voltmeter.voltageProperty ], voltage =>
voltage === null ? questionMarkString : CCKCUtil.createVoltageReadout( voltage )
voltage === null ? questionMarkString : CCKCUtils.createVoltageReadout( voltage )
);

const probeTextNode = new ProbeTextNode(
Expand Down

0 comments on commit 0f81984

Please sign in to comment.