Coverage Report - org.jtheque.core.managers.feature.CoreMenu
 
Classes in this File Line Coverage Branch Coverage Complexity
CoreMenu
0 %
0/5
N/A
1
 
 1  
 package org.jtheque.core.managers.feature;
 2  
 
 3  
 import org.jtheque.core.managers.core.Core;
 4  
 import org.jtheque.core.managers.view.impl.actions.about.DisplayAboutViewAction;
 5  
 import org.jtheque.core.managers.view.impl.actions.author.AcInformOfABug;
 6  
 import org.jtheque.core.managers.view.impl.actions.author.AcOpenHelp;
 7  
 import org.jtheque.core.managers.view.impl.actions.author.AcProposeImprovement;
 8  
 import org.jtheque.core.managers.view.impl.actions.backup.AcBackupToJTD;
 9  
 import org.jtheque.core.managers.view.impl.actions.backup.AcBackupToXML;
 10  
 import org.jtheque.core.managers.view.impl.actions.backup.AcRestoreFromJTD;
 11  
 import org.jtheque.core.managers.view.impl.actions.backup.AcRestoreFromXML;
 12  
 import org.jtheque.core.managers.view.impl.actions.core.ExitAction;
 13  
 import org.jtheque.core.managers.view.impl.actions.undo.RedoAction;
 14  
 import org.jtheque.core.managers.view.impl.actions.undo.UndoAction;
 15  
 
 16  
 import java.util.List;
 17  
 
 18  
 /*
 19  
  * This file is part of JTheque.
 20  
  *
 21  
  * JTheque is free software: you can redistribute it and/or modify
 22  
  * it under the terms of the GNU General Public License as published by
 23  
  * the Free Software Foundation, either version 3 of the License.
 24  
  *
 25  
  * JTheque is distributed in the hope that it will be useful,
 26  
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
 27  
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 28  
  * GNU General Public License for more details.
 29  
  *
 30  
  * You should have received a copy of the GNU General Public License
 31  
  * along with JTheque.  If not, see <http://www.gnu.org/licenses/>.
 32  
  */
 33  
 
 34  
 /**
 35  
  * The menu of the core.
 36  
  *
 37  
  * @author Baptiste Wicht
 38  
  */
 39  0
 public final class CoreMenu extends AbstractMenu {
 40  
     @Override
 41  
     protected List<Feature> getFileMenuSubFeatures(){
 42  0
         return features(
 43  
                 createSeparatedSubFeature(200, "menu.backup",
 44  
                         createSubFeature(1, new AcBackupToJTD()),
 45  
                         createSubFeature(2, new AcBackupToXML())),
 46  
                 createSubFeature(201, "menu.restore",
 47  
                         createSubFeature(1, new AcRestoreFromJTD()),
 48  
                         createSubFeature(2, new AcRestoreFromXML())),
 49  
                 createSeparatedSubFeature(1000, new ExitAction())
 50  
         );
 51  
     }
 52  
 
 53  
     @Override
 54  
     protected List<Feature> getEditMenuSubFeatures(){
 55  0
         return features(
 56  
                 createSubFeature(1, new UndoAction()),
 57  
                 createSubFeature(2, new RedoAction())
 58  
         );
 59  
     }
 60  
 
 61  
     @Override
 62  
     protected List<Feature> getAdvancedMenuSubFeatures(){
 63  0
         return features(
 64  
                 createSeparatedSubFeature(500, createDisplayViewAction("config.actions.display", "configView"), Core.IMAGES_BASE_NAME, "options"),
 65  
                 createSeparatedSubFeature(750, createDisplayViewAction("modules.actions.manage", "moduleView"), Core.IMAGES_BASE_NAME, "update")
 66  
         );
 67  
     }
 68  
 
 69  
     @Override
 70  
     protected List<Feature> getHelpMenuSubFeatures(){
 71  0
         return features(
 72  
                 createSeparatedSubFeature(1, new AcOpenHelp(), Core.IMAGES_BASE_NAME, "help"),
 73  
                 createSeparatedSubFeature(2, new AcInformOfABug(), Core.IMAGES_BASE_NAME, "mail"),
 74  
                 createSeparatedSubFeature(4, new AcProposeImprovement(), Core.IMAGES_BASE_NAME, "idea"),
 75  
                 createSeparatedSubFeature(6, createDisplayViewAction("messages.actions.display", "messageView")),
 76  
                 createSeparatedSubFeature(25, createDisplayViewAction("log.view.actions.display", "logView")),
 77  
                 createSeparatedSubFeature(150, new DisplayAboutViewAction(), Core.IMAGES_BASE_NAME, "about")
 78  
         );
 79  
     }
 80  
 }