cider.client.gui
Class IdleTimer

java.lang.Object
  extended by cider.client.gui.IdleTimer

public class IdleTimer
extends java.lang.Object

Idle timer for MainWindow GUI. If user doesn't move the mouse in the window for 5 minutes it sends an idle presence.

Author:
Andrew

Field Summary
 boolean isIdle
          Wheter the user is idle
 
Constructor Summary
IdleTimer(Client client, boolean enabled)
           
 
Method Summary
 void activityDetected()
          At the end of an idle session, update the idle time and change the flag
 void resetTotal()
          Sets the idle time back to 0
 void stop()
          Stops the idle timer
 boolean userIsIdle()
          Checks if the user is idle
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

isIdle

public boolean isIdle
Wheter the user is idle

Constructor Detail

IdleTimer

public IdleTimer(Client client,
                 boolean enabled)
Method Detail

activityDetected

public void activityDetected()
At the end of an idle session, update the idle time and change the flag


resetTotal

public void resetTotal()
Sets the idle time back to 0


stop

public void stop()
Stops the idle timer


userIsIdle

public boolean userIsIdle()
Checks if the user is idle

Returns:
either true or false