Blackjack

com.amoebacode.blackjack.display.button
Class SavePreferencesButton

java.lang.Object
  |
  +--com.amoebacode.blackjack.display.DisplayElement
        |
        +--com.amoebacode.blackjack.display.button.ButtonBase
              |
              +--com.amoebacode.blackjack.display.button.GameButton
                    |
                    +--com.amoebacode.blackjack.display.button.SaveButton
                          |
                          +--com.amoebacode.blackjack.display.button.SavePreferencesButton

class SavePreferencesButton
extends SaveButton

SavePreferencesButton manages the Save Preferences user button.

Version:
0.9
Author:
Jason Gurney

Fields inherited from class com.amoebacode.blackjack.display.button.SaveButton
WIDTH
 
Fields inherited from class com.amoebacode.blackjack.display.button.GameButton
game
 
Fields inherited from class com.amoebacode.blackjack.display.button.ButtonBase
button, buttonListener, HEIGHT
 
Fields inherited from class com.amoebacode.blackjack.display.DisplayElement
parent
 
Constructor Summary
protected SavePreferencesButton(GameDisplay game)
          Default protected constructor.
 
Method Summary
protected  java.lang.String getButtonText()
          Returns the button text.
protected  java.lang.String getToolTipText()
          Returns the help text that appears when the user mouses over the button.
protected  int getXPos()
          Returns the horizontal position of the button.
protected  int getYPos()
          Returns the vertical position of the button.
 void performAction()
          Saves the current preferences (called when the button is clicked).
 
Methods inherited from class com.amoebacode.blackjack.display.button.SaveButton
getWidth
 
Methods inherited from class com.amoebacode.blackjack.display.button.GameButton
actionPreamble, setupButton
 
Methods inherited from class com.amoebacode.blackjack.display.button.ButtonBase
activate, clear, disable, displayDisable, getButtonListener, getHeight, hide, setMouseEnteredBackground, setMouseExitedBackground
 
Methods inherited from class com.amoebacode.blackjack.display.DisplayElement
executeGameCommand, getDisplayManager, getGameDisplay, getParent, hasParent, playGameClip, queueAction, resumeQueue
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Constructor Detail

SavePreferencesButton

protected SavePreferencesButton(GameDisplay game)
Default protected constructor.
Parameters:
game - the GameDisplay parent
Method Detail

getButtonText

protected java.lang.String getButtonText()
Returns the button text.
Overrides:
getButtonText in class ButtonBase
Returns:
the button text

getXPos

protected int getXPos()
Returns the horizontal position of the button.
Overrides:
getXPos in class ButtonBase
Returns:
the horizontal position in pixels

getYPos

protected int getYPos()
Returns the vertical position of the button.
Overrides:
getYPos in class ButtonBase
Returns:
the vertical position in pixels

performAction

public void performAction()
Saves the current preferences (called when the button is clicked).
Overrides:
performAction in class GameButton

getToolTipText

protected java.lang.String getToolTipText()
Returns the help text that appears when the user mouses over the button.
Overrides:
getToolTipText in class ButtonBase
Returns:
the mouseover help text

Blackjack

Copyright © 2002 amoebacode.com.