|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.Window | +--java.awt.Frame | +--InterUtil
Gestion de l'interface graphique du jeux Awale
Inner classes inherited from class java.awt.Component |
java.awt.Component.AWTTreeLock |
Field Summary | |
protected int |
_attente
Variable determinant le temps d'attente de l'ordinateur |
private java.awt.Frame |
_frame
Frame permettant aux classes imbriquees de connaitre la frame principale |
ImagePlateau |
_imagePlateau
L'image du plateau qu'on affiche au centre de la frame |
private InterUtil |
_interUtil
InterUtil permettant aux classe imbriquees de connaitre l'interUtil en principale |
private Moteur |
_m
Le moteur du jeu |
private java.awt.MenuItem |
_miNouveau
MenuItem Nouveau, pouvant etre active/desactive |
private java.awt.MenuItem |
_miOuvrir
MenuItem Ouvrir, pouvant etre active/desactive |
private java.awt.MenuItem |
_miSauve
MenuItem Sauve, pouvant etre active/desactive |
private int[] |
_plateau
Le plateau de jeux qui est affiche actuellement |
private int[] |
_plateau_tmp
Plateau temporaire servant a determiner l'animation |
private java.awt.TextField |
_res1
Zone de texte qui affiche le nombre de graines dans la premiere reserve |
private java.awt.TextField |
_res2
Zone de texte qui affiche le nombre de graines dans la deuxieme reserve |
private int[] |
_reserves
Les reserves qui sont affichees actuellement |
private int[] |
_reserves_tmp
Reserves temporaires servant a determiner l'animation |
java.lang.Thread |
_th
Le thread servant a la gestion des animations |
protected int |
_vitesse
Variable determinant la vitesse des animations |
private java.awt.TextField |
_zoneTexte
Zone de texte ou s'affichent des imforamtion telles que le nombre de graines dans le trou pointe |
Fields inherited from class java.awt.Frame |
base,
CROSSHAIR_CURSOR,
DEFAULT_CURSOR,
E_RESIZE_CURSOR,
frameSerializedDataVersion,
HAND_CURSOR,
icon,
ICONIFIED,
mbManagement,
menuBar,
MOVE_CURSOR,
N_RESIZE_CURSOR,
nameCounter,
NE_RESIZE_CURSOR,
NORMAL,
NW_RESIZE_CURSOR,
ownedWindows,
resizable,
S_RESIZE_CURSOR,
SE_RESIZE_CURSOR,
serialVersionUID,
state,
SW_RESIZE_CURSOR,
TEXT_CURSOR,
title,
W_RESIZE_CURSOR,
WAIT_CURSOR,
weakThis |
Fields inherited from class java.awt.Window |
active,
base,
focusMgr,
inputContext,
nameCounter,
OPENED,
ownedWindowList,
serialVersionUID,
state,
warningString,
weakThis,
windowListener,
windowSerializedDataVersion |
Fields inherited from class java.awt.Container |
component,
containerListener,
containerSerializedDataVersion,
dispatcher,
layoutMgr,
maxSize,
ncomponents,
serialVersionUID |
Fields inherited from class java.awt.Component |
actionListenerK,
adjustmentListenerK,
appContext,
assert,
background,
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
changeSupport,
componentListener,
componentListenerK,
componentOrientation,
componentSerializedDataVersion,
containerListenerK,
cursor,
dropTarget,
enabled,
eventMask,
focusListener,
focusListenerK,
font,
foreground,
hasFocus,
height,
incRate,
inputMethodListener,
inputMethodListenerK,
isInc,
isPacked,
itemListenerK,
keyListener,
keyListenerK,
LEFT_ALIGNMENT,
locale,
LOCK,
minSize,
mouseListener,
mouseListenerK,
mouseMotionListener,
mouseMotionListenerK,
name,
nameExplicitlySet,
newEventsOnly,
ownedWindowK,
parent,
peer,
peerFont,
popups,
prefSize,
RIGHT_ALIGNMENT,
serialVersionUID,
textListenerK,
TOP_ALIGNMENT,
valid,
visible,
width,
windowListenerK,
x,
y |
Constructor Summary | |
InterUtil()
Constructeur de l'interface graphique |
Method Summary | |
private void |
dialog(java.lang.String text1,
java.lang.String text2,
java.lang.String text3,
java.lang.String titre)
Ouvre une boite de dialog avec les options passees en parametre |
static void |
main(java.lang.String[] arg)
Programme principal du jeu Awale |
void |
montre_plateau(int[] plateau,
int[] reserves)
Initialise le lancement de l'animation |
void |
partie_terminee(boolean gagne)
Affiche le gagnant dans une boite de dialogue |
void |
run()
Execution des differentes animations |
void |
setChargeEnabled(boolean etat)
Rends le MenuItem "Ouvrir" actif ou non |
void |
start()
Cree le thread d'animation |
Methods inherited from class java.awt.Frame |
|
Methods inherited from class java.awt.Window |
addOwnedWindow,
addWindowListener,
applyResourceBundle,
applyResourceBundle,
connectOwnedWindow,
dispatchEventImpl,
dispose,
eventEnabled,
getFocusOwner,
getInputContext,
getLocale,
getOwnedWindows,
getOwner,
getToolkit,
getWarningString,
isActive,
isShowing,
nextFocus,
ownedInit,
pack,
postEvent,
postWindowEvent,
preProcessKeyEvent,
processEvent,
processWindowEvent,
removeOwnedWindow,
removeWindowListener,
setFocusOwner,
setWarningString,
show,
toBack,
toFront,
transferFocus |
Methods inherited from class java.awt.Container |
add,
add,
add,
add,
add,
addContainerListener,
addImpl,
applyOrientation,
countComponents,
deliverEvent,
dispatchEventToSelf,
doLayout,
findComponentAt,
findComponentAt,
getAlignmentX,
getAlignmentY,
getComponent,
getComponentAt,
getComponentAt,
getComponentCount,
getComponents_NoClientCode,
getComponents,
getInsets,
getLayout,
getMaximumSize,
getMinimumSize,
getMouseEventTarget,
getPreferredSize,
getWindow,
insets,
invalidate,
invalidateTree,
isAncestorOf,
layout,
lightweightPrint,
list,
list,
locate,
minimumSize,
paint,
paintComponents,
postsOldMouseEvents,
preferredSize,
print,
printComponents,
printOneComponent,
processContainerEvent,
proxyEnableEvents,
proxyRequestFocus,
remove,
remove,
removeAll,
removeContainerListener,
setFont,
setLayout,
update,
validate,
validateTree |
Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
areInputMethodsEnabled,
bounds,
checkImage,
checkImage,
coalesceEvents,
contains,
contains,
createImage,
createImage,
disable,
disableEvents,
dispatchEvent,
enable,
enable,
enableEvents,
enableInputMethods,
firePropertyChange,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentOrientation,
getCursor,
getDropTarget,
getFont_NoClientCode,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputMethodRequests,
getLocation,
getLocation,
getLocationOnScreen,
getName,
getNativeContainer,
getParent_NoClientCode,
getParent,
getPeer,
getSize,
getSize,
getToolkitImpl,
getTreeLock,
getWidth,
getWindowForObject,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
isDisplayable,
isDoubleBuffered,
isEnabled,
isEnabledImpl,
isFocusTraversable,
isLightweight,
isOpaque,
isValid,
isVisible,
keyDown,
keyUp,
list,
list,
list,
location,
lostFocus,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
prepareImage,
prepareImage,
printAll,
processComponentEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
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 |
private int[] _plateau
private int[] _reserves
private int[] _plateau_tmp
private int[] _reserves_tmp
public ImagePlateau _imagePlateau
private java.awt.TextField _zoneTexte
private java.awt.TextField _res1
private java.awt.TextField _res2
private java.awt.Frame _frame
private InterUtil _interUtil
private Moteur _m
public java.lang.Thread _th
private java.awt.MenuItem _miNouveau
private java.awt.MenuItem _miOuvrir
private java.awt.MenuItem _miSauve
protected int _vitesse
protected int _attente
Constructor Detail |
public InterUtil()
Method Detail |
public void montre_plateau(int[] plateau, int[] reserves)
plateau
- le plateau qu'on doit obtenir a la fin de l'animationreserves
- les reserves qu'on doit obtenir a la fin de l'animationpublic void start()
public void run()
public void partie_terminee(boolean gagne)
public void setChargeEnabled(boolean etat)
private void dialog(java.lang.String text1, java.lang.String text2, java.lang.String text3, java.lang.String titre)
text1
- le texte a mettre sur le premiere lignetext2
- le texte a mettre sur la deuxieme lignetext3
- le texte a mettre sur la deuxieme lignetitre
- le titre a donner a la boite de dialogpublic static void main(java.lang.String[] arg)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |