MCPcopy Index your code
hub / github.com/BombusMod/BombusMod / start

Method start

src/main/java/Client/AutoStatus.java:54–77  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

52 private AutoStatus() {}
53
54 public void start() {
55 if (timer == null) {
56 reset();
57 TimerTask task = new TimerTask() {
58 public void run() {
59 if (!sd.roster.isLoggedIn() || (Config.autoAwayType==Config.AWAY_OFF)) {
60 return;
61 }
62
63 long timeAwayRemained = System.currentTimeMillis() - timeAwayEvent;
64 if (!isAwaySet && timeAwayRemained > 0) {
65 setAutoAway(SR.MS_AUTO_AWAY);
66 }
67
68 long timeXaRemained = System.currentTimeMillis() - timeXaEvent;
69 if (!isXaSet && timeXaRemained > 0) {
70 setAutoXa(SR.MS_AUTO_XA);
71 }
72 }
73 };
74 timer = new Timer();
75 timer.schedule(task, 0, TIMER_INTERVAL);
76 }
77 }
78
79 public void reset() {
80 if (isAwaySet) {

Callers 15

platformRequestMethod · 0.45
contextDestroyedMethod · 0.45
MIDletTimerMethod · 0.45
createEventDispatcherMethod · 0.45
InputMethodImplMethod · 0.45
createEventDispatcherMethod · 0.45
onServiceConnectedMethod · 0.45
startConnectionMethod · 0.45
startNotifyMethod · 0.45
ThreadDispatcherClass · 0.45
createEventDispatcherMethod · 0.45
viewDidLoadMethod · 0.45

Calls 2

resetMethod · 0.95
scheduleMethod · 0.45

Tested by

no test coverage detected