Package org.jampa.model

Examples of org.jampa.model.IAudioItem


        (!_podcastName.isEmpty())) {
     
      try {
       
        Podcast podcastItem = Controller.getInstance().getPlaylistController().getPodcastByName(_podcastName);
        IAudioItem firstAudioItem = podcastItem.getAudioItemByIndex(0);
       
        new OpenPodcastAction(podcastItem.getName()).run();
        Controller.getInstance().getPlaylistController().playFile(podcastItem, firstAudioItem);
       
      } catch (Exception e) {
View Full Code Here


  public void run() {
    if ((_podcastName != null) &&
        (!_podcastName.isEmpty())) {
      try {
      Podcast podcast = Controller.getInstance().getPlaylistController().getPodcastByName(_podcastName);
      IAudioItem firstAudioItem = podcast.getAudioItemByIndex(0);
      Controller.getInstance().getPlaylistController().playFile(podcast, firstAudioItem);
      } catch (Exception e) {
        Log.getInstance(PlayPodcastAction.class).error("Error while playing podcast: " + e.getMessage());   //$NON-NLS-1$
      }
    }
View Full Code Here

    if ((_playlistName != null) &&
        (!_playlistName.isEmpty())) {
     
      try {
        Playlist playlistItem = Controller.getInstance().getPlaylistController().getPlaylistByName(_playlistName);
        IAudioItem firstAudioItem = playlistItem.getAudioItemByIndex(0);
        Controller.getInstance().getPlaylistController().playFile(playlistItem, firstAudioItem);
      } catch (Exception e) {
        Log.getInstance(PlayPlaylistAction.class).error("Error while playing playlist: " + e.getMessage());   //$NON-NLS-1$
      }
    }
View Full Code Here

    IWorkbenchWindow window = HandlerUtil.getActiveWorkbenchWindow(event);
    ISelection selection = window.getActivePage().getSelection();
   
    Object obj = ((IStructuredSelection) selection).getFirstElement();
    if (obj != null) {
      IAudioItem firstAudioItem = ((Playlist) obj).getAudioItemByIndex(0);
      Controller.getInstance().getPlaylistController().playFile((Playlist) obj, firstAudioItem);
    }

    return null;
  }
View Full Code Here

      Log.getInstance(MenuOpenPlaylistHandler.class).debug("Openning playlist: " + item.getName()); //$NON-NLS-1$
      new OpenPlaylistAction(item.getName()).run();
    }
   
    if (firstItem != null) {
      IAudioItem firstAudioItem = firstItem.getAudioItemByIndex(0);
      Controller.getInstance().getPlaylistController().playFile(firstItem, firstAudioItem);
    }
    return null;
  }
View Full Code Here

    if ((_playlistName != null) &&
        (!_playlistName.isEmpty())) {
     
      try {
        Playlist playlistItem = Controller.getInstance().getPlaylistController().getPlaylistByName(_playlistName);
        IAudioItem firstAudioItem = playlistItem.getAudioItemByIndex(0);
       
        new OpenPlaylistAction(playlistItem.getName()).run();
        Controller.getInstance().getPlaylistController().playFile(playlistItem, firstAudioItem);
       
      } catch (Exception e) {
View Full Code Here

 
 
  public void playPlaylist(String playlistName) {
    if (_items.containsKey(playlistName)) {
      Playlist playlist = _items.get(playlistName);
      IAudioItem item = playlist.getAudioItemByIndex(0);
      if (item != null) {
        playFile(playlist, item);
      }
    } else
      Log.getInstance(PlaylistController.class).info("Playlist not found : " + playlistName);   //$NON-NLS-1$
View Full Code Here

       
        return;
      }
    }
   
    IAudioItem oldItem = _currentAudioItem;
       
    if (oldItem != null)
      oldItem.setBoPlaying(false);
   
    _currentPlaylist = playlist;
    _currentAudioItem = item;
   
    _currentAudioItem.setBoPlaying(true);
View Full Code Here

TOP

Related Classes of org.jampa.model.IAudioItem

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.