Class Barras

java.lang.Object
  |
  +--java.awt.Component
        |
        +--java.awt.Container
              |
              +--java.awt.Window
                    |
                    +--java.awt.Dialog
                          |
                          +--Barras
All Implemented Interfaces:
javax.accessibility.Accessible, java.awt.event.AdjustmentListener, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable

class Barras
extends java.awt.Dialog
implements java.awt.event.AdjustmentListener

Permite modificar un máximo de tres variables mediante barras de desplazamiento que aparecen en una sóla ventana. Se utiliza para modificar las dimensiones geométricas del edificio, el color de fondo y los colores del edificio y el suelo.

See Also:
Serialized Form

Inner classes inherited from class java.awt.Dialog
java.awt.Dialog.AccessibleAWTDialog
 
Inner classes inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Inner classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Inner classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.AWTTreeLock
 
Field Summary
private  Fotorred appletPoint
           
private  java.awt.Scrollbar barraX
           
private  java.awt.Scrollbar barraY
           
private  java.awt.Scrollbar barraZ
           
private  int controlColor
           
private  boolean controlDim
           
private  MenuFrame menuPoint
           
private  java.awt.Label title
           
private  java.awt.Label title1
           
private  java.awt.Label title2
           
private  float valorX
           
private  float valorY
           
private  float valorZ
           
 
Fields inherited from class java.awt.Dialog
base, keepBlocking, modal, nameCounter, resizable, serialVersionUID
 
Fields inherited from class java.awt.Window
active, dbg, focusMgr, inputContext, inputContextLock, OPENED, ownedWindowList, state, warningString, weakThis, windowListener, windowSerializedDataVersion
 
Fields inherited from class java.awt.Container
component, containerListener, containerSerializedDataVersion, dispatcher, layoutMgr, listeningBoundsChildren, listeningChildren, maxSize, ncomponents, printing, printingThreads
 
Fields inherited from class java.awt.Component
accessibleContext, actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, changeSupport, componentListener, componentListenerK, componentOrientation, componentSerializedDataVersion, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, graphicsConfig, hasFocus, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, name, nameExplicitlySet, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, privateKey, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowListenerK, x, y
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
Barras(java.lang.String s, Fotorred mainWin, MenuFrame menus, boolean contr, int contColor)
          Constructor
 
Method Summary
 void adjustmentValueChanged(java.awt.event.AdjustmentEvent e)
          Gestiona eventos de las barras de desplazamiento para modificar las magnitudes consideradas.
private  void crearBarrasColor(int rojo, int verde, int azul)
          Crea tres barras de desplazamiento para que el usuario cambie un color.
 void resetValues()
          Reinicia las barras de desplazamiento a los valores originales del edificio tipo.
 void setValues(float valorBarra1, float valorBarra2, float valorBarra3, int mult)
          Asigna a las barras de desplazamiento los valores pasados como parámetros.
 
Methods inherited from class java.awt.Dialog
, addNotify, conditionalShow, constructComponentName, dispose, disposeImpl, getAccessibleContext, getTitle, hide, hideAndDisposeHandler, initIDs, interruptBlocking, isModal, isResizable, paramString, setModal, setResizable, setTitle, show
 
Methods inherited from class java.awt.Window
addOwnedWindow, addWindowListener, adjustListeningChildren, applyResourceBundle, applyResourceBundle, connectOwnedWindow, dispatchEventImpl, eventEnabled, finalize, getFocusOwner, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getOwnedWindows, getOwner, getToolkit, getWarningString, isActive, isShowing, nextFocus, ownedInit, pack, postEvent, postProcessKeyEvent, postWindowEvent, preProcessKeyEvent, processEvent, processWindowEvent, readObject, removeOwnedWindow, removeWindowListener, resetGC, setCursor, setFocusOwner, setWarningString, toBack, toFront, transferFocus, writeObject
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, applyOrientation, checkGD, countComponents, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventToSelf, doLayout, findComponentAt, findComponentAt, findComponentAt, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getInsets, getLayout, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, getWindow, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, numListening, paint, paintComponents, paintHeavyweightComponents, postsOldMouseEvents, preferredSize, print, printComponents, printHeavyweightComponents, processContainerEvent, proxyEnableEvents, proxyRequestFocus, remove, remove, removeAll, removeContainerListener, removeNotify, setFont, setLayout, update, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, areInputMethodsEnabled, bounds, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getSize, getToolkitImpl, getTreeLock, getWidth, getWindowForObject, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

appletPoint

private Fotorred appletPoint

menuPoint

private MenuFrame menuPoint

barraX

private java.awt.Scrollbar barraX

barraY

private java.awt.Scrollbar barraY

barraZ

private java.awt.Scrollbar barraZ

valorX

private float valorX

valorY

private float valorY

valorZ

private float valorZ

title

private java.awt.Label title

title1

private java.awt.Label title1

title2

private java.awt.Label title2

controlDim

private boolean controlDim

controlColor

private int controlColor
Constructor Detail

Barras

public Barras(java.lang.String s,
              Fotorred mainWin,
              MenuFrame menus,
              boolean contr,
              int contColor)
Constructor
Parameters:
s - Título de la ventana.
mainWin - Enlace a la clase principal del programa.
menus - Enlace a la barra de menús flotante.
contr - Variable de control para seleccionar magnitud a modificar.
contColor - Variable de control para la gestión de colores.
Method Detail

crearBarrasColor

private void crearBarrasColor(int rojo,
                              int verde,
                              int azul)
Crea tres barras de desplazamiento para que el usuario cambie un color.
Parameters:
rojo - Grado inicial de color rojo (valor entre 0 y 1).
verde - Grado inicial de color verde (valor entre 0 y 1).
azul - Grado inicial de color azul (valor entre 0 y 1).

resetValues

public void resetValues()
Reinicia las barras de desplazamiento a los valores originales del edificio tipo.

setValues

public void setValues(float valorBarra1,
                      float valorBarra2,
                      float valorBarra3,
                      int mult)
Asigna a las barras de desplazamiento los valores pasados como parámetros.
Parameters:
valorBarra1 - Valor que se asignará a la primera barra de desplazamiento.
valorBarra2 - Valor que se asignará a la segunda barra de desplazamiento.
valorBarra3 - Valor que se asignará a la tercera barra de desplazamiento.
mult - factor de multiplicación que se debe aplicar a los valores pasados.

adjustmentValueChanged

public void adjustmentValueChanged(java.awt.event.AdjustmentEvent e)
Gestiona eventos de las barras de desplazamiento para modificar las magnitudes consideradas.
Specified by:
adjustmentValueChanged in interface java.awt.event.AdjustmentListener
Parameters:
e - Evento procedente de una barra de desplazamiento.