001 /*
002 * This file is part of the Echo Point Project. This project is a
003 * collection of Components that have extended the Echo Web Application
004 * Framework Version 3.
005 *
006 * Version: MPL 1.1
007 *
008 * The contents of this file are subject to the Mozilla Public License Version
009 * 1.1 (the "License"); you may not use this file except in compliance with
010 * the License. You may obtain a copy of the License at
011 * http://www.mozilla.org/MPL/
012 *
013 * Software distributed under the License is distributed on an "AS IS" basis,
014 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
015 * for the specific language governing rights and limitations under the
016 * License.
017 */
018
019 package echopoint.style.echo.extras;
020
021 import nextapp.echo.extras.app.AccordionPane;
022 import nextapp.echo.extras.app.CalendarSelect;
023 import nextapp.echo.extras.app.ContextMenu;
024 import nextapp.echo.extras.app.MenuBarPane;
025 import nextapp.echo.extras.app.TabPane;
026
027 import echopoint.style.echo.EchoStyleSheet;
028
029 /**
030 * A style sheet that includes default styles for Echo Extras components.
031 *
032 * @author Rakesh Vidyadharan 2009-05-26
033 * @version $Id: ExtrasStyleSheet.java 255 2009-11-29 12:16:16Z sptrakesh $
034 */
035 @SuppressWarnings( { "ClassNamePrefixedWithPackageName" } )
036 public class ExtrasStyleSheet extends EchoStyleSheet
037 {
038 private static final long serialVersionUID = 1L;
039
040 /** {@inheritDoc} */
041 @Override
042 protected void init()
043 {
044 super.init();
045
046 addAccordionPaneStyles();
047 addCalendarSelectStyles();
048 addMenuBarPaneStyles();
049 addContextMenuStyles();
050 addTabPaneStyles();
051 }
052
053 /** Add default styles for {@link nextapp.echo.extras.app.AccordionPane}. */
054 protected void addAccordionPaneStyles()
055 {
056 final AccordionPaneStyle style = new AccordionPaneStyle();
057 addStyle( AccordionPane.class, "", style );
058 addStyle( AccordionPane.class, "Default", style );
059 }
060
061 /** Add default styles for {@link nextapp.echo.extras.app.CalendarSelect}. */
062 protected void addCalendarSelectStyles()
063 {
064 final CalendarSelectStyle style = new CalendarSelectStyle();
065 addStyle( CalendarSelect.class, "", style );
066 addStyle( CalendarSelect.class, "Default", style );
067 }
068
069 /** Add default styles for {@link nextapp.echo.extras.app.MenuBarPane}. */
070 protected void addMenuBarPaneStyles()
071 {
072 final MenuBarPaneStyle style = new MenuBarPaneStyle();
073 addStyle( MenuBarPane.class, "", style );
074 addStyle( MenuBarPane.class, "Default", style );
075 }
076
077 /** Add default styles for {@link nextapp.echo.extras.app.ContextMenu}. */
078 protected void addContextMenuStyles()
079 {
080 final ContextMenuStyle style = new ContextMenuStyle();
081 addStyle( ContextMenu.class, "", style );
082 addStyle( ContextMenu.class, "Default", style );
083 }
084
085 /** Add default styles for {@link nextapp.echo.extras.app.TabPane}. */
086 protected void addTabPaneStyles()
087 {
088 final TabPaneStyle style = new TabPaneStyle();
089 addStyle( TabPane.class, "", style );
090 addStyle( TabPane.class, "Default", style );
091 }
092 }