예제 #1
0
  private void jButton_fullscreenActionPerformed(
      java.awt.event.ActionEvent evt) { // GEN-FIRST:event_jButton_fullscreenActionPerformed
    File file = new File(Instance_data.getPlaypath());
    System.out.println(Instance_data.getPlaypath());
    Instance_hold.getFsnt().setVisible(false);
    Instance_hold.getFsf().setVisible(false);
    Instance_data.setMedia_time(Instance_hold.getFsf().getEmpc().getMediaPlayer().getTime());
    // Instance_hold.getVplay_mon().setStopped(true);
    Instance_hold.getFsf().getEmpc().getMediaPlayer().stop();
    Instance_hold.getPlayframe().setVisible(true);
    Instance_hold.getPlayframe().getEmpc().getMediaPlayer().playMedia(Instance_data.getPlaypath());
    Instance_hold.getPlayframe().getEmpc().getMediaPlayer().setTime(Instance_data.getMedia_time());
    while (!Instance_hold.getPlayframe().getEmpc().getMediaPlayer().isPlaying() && file.exists()) {
      System.out.println("FSF:   WAITING TO START PLAYING:::::");
      try {
        Thread.sleep(100);
      } catch (InterruptedException ex) {

      }
    }
    ;
    // if (Instance_hold.getPlayframe().getEmpc().getMediaPlayer().isPlaying())
    // Instance_hold.getVplay_mon().setStopped(false);
    Instance_hold.getPlayframe()
        .getjLabel_play()
        .setIcon(new ImageIcon(getClass().getResource("/gui/design/mcb_grey_pause_small.png")));
    Instance_hold.getMframe().getClistener().setFullscreen(false);
  } // GEN-LAST:event_jButton_fullscreenActionPerformed
예제 #2
0
 private void jSlider_MediaMouseClicked(
     java.awt.event.MouseEvent evt) { // GEN-FIRST:event_jSlider_MediaMouseClicked
   if (!dragged)
     Instance_hold.getFsf()
         .getEmpc()
         .getMediaPlayer()
         .setTime(
             (int)
                 (Instance_data.getMedia_length()
                     * (this.jSlider_Media.getMousePosition().getX()
                         / this.jSlider_Media.getSize().getWidth())));
 } // GEN-LAST:event_jSlider_MediaMouseClicked
예제 #3
0
 private void jSlider_MediaMouseReleased(
     java.awt.event.MouseEvent evt) { // GEN-FIRST:event_jSlider_MediaMouseReleased
   // System.out.println("SETTIME_VALUE: " +
   // (int)(Instance_data.getMedia_length()*(sl_value/1000.0)));
   if (dragged) {
     Instance_hold.getFsf()
         .getEmpc()
         .getMediaPlayer()
         .setTime((int) (Instance_data.getMedia_length() * (sl_value / 1000.0)));
     dragged = false;
   }
 } // GEN-LAST:event_jSlider_MediaMouseReleased