Package org.jampa.gui.wizard.playlistsgenerator

Examples of org.jampa.gui.wizard.playlistsgenerator.PlaylistGeneratorWizard


    handlerService.activateHandler("Jampa.newPlaylist", new ActionHandler(newPlaylistAction));
   
    playlistGeneratorAction = new Action(Messages.getString("Menu.Playlists.PlaylistGenerator"), SWT.NONE) {
      public void run() {
        System.out.println("test2");
        PlaylistGeneratorWizard wizard = new PlaylistGeneratorWizard();
       
        WizardDialog wizardDialog = new WizardDialog(Display.getCurrent().getActiveShell(), wizard);
        wizardDialog.setPageSize(500, 200);
       
        if (wizardDialog.open() == Dialog.OK) {     
          Controller.getInstance().getPlaylistController().addEmptyPlaylist(wizard.getPlaylistName());
          Controller.getInstance().getPlaylistController().addItemToPlaylist(wizard.getPlaylistName(), wizard.getGenerator().getResults(), wizard.getPlay());
          new OpenPlaylistAction(wizard.getPlaylistName()).run();
        }
      }
    };
    playlistGeneratorAction.setActionDefinitionId("Jampa.playlistGeneratorWizard");
    handlerService.activateHandler("Jampa.playlistGeneratorWizard", new ActionHandler(playlistGeneratorAction));
   
    importPlaylistAction = new Action(Messages.getString("Menu.Playlists.ImportPlaylist"), SWT.NONE) {
      public void run() {
        PlaylistImportWizard wizard = new PlaylistImportWizard();
       
        WizardDialog wizardDialog = new WizardDialog(Display.getCurrent().getActiveShell(), wizard);
        wizardDialog.setPageSize(500, 100);
       
        if (wizardDialog.open() == Dialog.OK) {
          Log.getInstance(MenuController.class).debug("Importing file " + wizard.getFileName() + " to playlist: " + wizard.getPlaylistName()); //$NON-NLS-1$ //$NON-NLS-2$
          Controller.getInstance().getPlaylistController().importPlaylist(wizard.getPlaylistName(), wizard.getFileName());
        }
      }
    };
    importPlaylistAction.setActionDefinitionId("Jampa.playlistImportWizard");
    handlerService.activateHandler("Jampa.playlistImportWizard", new ActionHandler(importPlaylistAction));
View Full Code Here

TOP

Related Classes of org.jampa.gui.wizard.playlistsgenerator.PlaylistGeneratorWizard

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.