コード例 #1
0
 private CustomProgressBar createProgressBar() {
   final CustomProgressBar progress = new CustomProgressBar();
   progress.setName("PROGRESSBAR");
   color = UNKNOWN_COLOR;
   Timer timer =
       new Timer(
           animator.getAnimationRate(),
           new ActionListener() {
             @Override
             public void actionPerformed(ActionEvent e) {
               progress.setForeground(animator.shiftColorOnAnimationTick(color));
               progress.repaint();
               animator.tick();
             }
           });
   timer.start();
   return progress;
 }
コード例 #2
0
 public int getAngerLevel() {
   return animator.getAngerLevel();
 }
コード例 #3
0
 public void setAngerLevel(int anger) {
   animator.setAngerLevel(anger);
 }
コード例 #4
0
 public void setAngerBasedOnTime(long timeSinceGreen) {
   animator.setAngerBasedOnTime(timeSinceGreen);
 }