group { name: "elm/menu/item/default";
   images.image: "vgrad_med_dark.png" COMP;
   images.image: "bevel_horiz_out.png" COMP;
   images.image: "shadow_rounded_horiz.png" COMP;
   images.image: "shine.png" COMP;
   script {
      public menu_text_visible; //0:hide (default), 1:visible
      public menu_disable; //0:enable, 1:disable
   }
   parts {
      part { name: "shadow"; mouse_events: 0;
         description { state: "default" 0.0;
            image.normal: "shadow_rounded_horiz.png";
            image.border: 0 0 9 9;
            rel1.offset: 0 -4;
            rel2.offset: -1 5;
            fill.smooth: 0;
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "base"; mouse_events: 0;
         description { state: "default" 0.0;
            image.normal: "vgrad_med_dark.png";
            fill.smooth: 0;
            TILED_HORIZ(120)
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "elm.swallow.content"; type: SWALLOW; mouse_events:  0;
         clip_to: "disabler";
         scale: 1;
         description { state: "default" 0.0;
            min: 16 16;
            fixed: 1 0;
            align: 0.0 0.5;
            rel1.offset: 3 3;
            rel2.offset: 3 -5;
            rel2.relative: 0.0 1.0;
         }
         description { state: "noicon" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      // XXX: check/radio goes next (right of) content, no radio/check handle
      // XXX: need to handle no text?
      // XXX: need arrowspace on/off based on submenus in menu
      part { name: "arrowspace"; type: SPACER;
         scale: 1;
         description { state: "default" 0.0;
            fixed: 1 1;
            min: 15 15;
            max: 15 15;
            rel1.offset: -2 0;
            rel1.relative: 1.0 0.0;
            rel2.offset: -2 -1;
            align: 1.0 0.5;
         }
      }
      part { name: "elm.text"; type: TEXT; mouse_events:  0;
         effect: SHADOW BOTTOM;
         scale: 1;
         description { state: "default" 0.0;
            rel1.to_x: "elm.swallow.content";
            rel1.relative: 1.0 0.0;
            rel1.offset: 5 -1;
            rel2.to_x: "arrowspace";
            rel2.offset: -6 -1;
            rel2.relative: 0.0 1.0;
            color: FN_COL_DEFAULT;
            text { font: FN; size: 10;
               min: 1 1;
               ellipsis: -1;
               align: 0.0 0.5;
               text_class: "menu_item";
            }
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
            visible: 0;
         }
      }
      part { name: "label2"; type: TEXT; mouse_events: 0;
         effect: SHADOW BOTTOM;
         scale: 1;
         description { state: "default" 0.0;
            rel1.to: "elm.text";
            rel2.to: "elm.text";
            color: FN_COL_DISABLE;
            color_class: "menu_item_disabled";
            text { font: FN; size: 10;
               text_source: "elm.text";
               align: 0.0 0.5;
               text_class: "menu_item";
            }
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
      }
      part { name: "label3"; type: TEXT; mouse_events: 0;
         effect: GLOW;
         scale: 1;
         description { state: "default" 0.0;
            rel1.offset: -2 -3;
            rel1.to: "elm.text";
            rel2.offset: 2 1;
            rel2.to: "elm.text";
            color: FN_COL_HIGHLIGHT;
            color_class: "menu_item_active";
            text { font: FN; size: 10;
               text_source: "elm.text";
               align: 0.0 0.5;
               text_class: "menu_item";
            }
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      part { name: "bevel"; mouse_events: 0;
         description { state: "default" 0.0;
            image.normal: "bevel_horiz_out.png";
            image.border: 0 0 2 2;
            image.middle: 0;
            fill.smooth: 0;
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "shine";
         repeat_events: 1;
         description { state: "default" 0.0;
            rel1.to: "base";
            rel1.offset: 0 -2;
            rel2.to: "base";
            rel2.relative: 1.0 0.0;
            rel2.offset: -1 2;
            image.normal: "shine.png";
            visible: 0;
            FIXED_SIZE(69, 5)
         }
         description { state: "active" 0.0;
            inherit:  "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "event"; type: RECT;
         ignore_flags: ON_HOLD;
         description { state: "default" 0.0;
            color: 255 255 255 0;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      part { name: "disabler"; type: RECT;
         description { state: "default" 0.0;
            color: 255 255 255 255;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 128;
         }
      }
   }
   programs {
      program {
         signal: "mouse,in"; source: "event";
         action: SIGNAL_EMIT "elm,action,activate" "elm";
         after: "selected";
      }
      program {
         signal: "mouse,out"; source: "event";
//         action: SIGNAL_EMIT "elm,action,inactivate" "elm";
         after: "unselected";
      }
      program { signal: "mouse,down,1"; source: "event";
         after: "selected";
      }
      program {
         signal: "mouse,up,1"; source: "event";
         action: SIGNAL_EMIT "elm,action,click" "elm";
      }
      program { name: "text_show";
         signal: "elm,state,text,visible"; source: "elm";
         script {
            set_int(menu_text_visible, 1);
//            set_state(PART:"elm.text", "active", 0.0);
//            set_state(PART:"elm.text2", "active", 0.0);
         }
      }
      program { name: "text_hide";
         signal: "elm,state,text,hidden"; source: "elm";
         script {
            set_int(menu_text_visible, 0);
//            set_state(PART:"elm.text", "default", 0.0);
//            set_state(PART:"elm.text2", "default", 0.0);
         }
      }
      program { name: "icon_show";
         signal: "elm,state,icon,visible"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "elm.swallow.content";
      }
      program { name: "icon_hide";
         signal: "elm,state,icon,hidden"; source: "elm";
         action: STATE_SET "noicon" 0.0;
         target: "elm.swallow.content";
      }
      program { name: "selected";
         signal: "elm,state,selected"; source: "elm";
         action: STATE_SET "active" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel";
         target: "shine";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
      program { name: "unselected";
         signal: "elm,state,unselected"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel";
         target: "shine";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
      program {
         signal: "elm,state,enabled"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel";
         target: "shine";
         target: "event";
         target: "disabler";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
      program {
         signal: "elm,state,disabled"; source: "elm";
         action: STATE_SET "disabled" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel";
         target: "shine";
         target: "event";
         target: "disabler";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
   }
}

group { name: "elm/menu/item_with_submenu/default";
   inherit: "elm/menu/item/default";
//   alias: "elm/menu/main_menu_submenu/default";
   images {
      image: "sym_right_light_normal.png" COMP;
      image: "sym_right_glow_normal.png" COMP;
      image: "vertical_separated_bar_glow.png" COMP;
   }
   parts {
      part { name: "arrow";
         description { state: "default" 0.0;
            rel1.to: "arrowspace";
            rel2.to: "arrowspace";
            image.normal: "sym_right_light_normal.png";
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            image.normal: "sym_right_glow_normal.png";
         }
      }
      part { name: "select_line";
         repeat_events: 1;
         description { state: "default" 0.0;
            visible: 0;
            rel1.relative: 1.0 0.0;
            rel1.offset: -10 -5;
            rel2.offset: 4 4;
            image {
               normal: "vertical_separated_bar_glow.png";
               border: 7 7 7 7;
            }
            fill.smooth : 0;
         }
         description { state: "active" 0.0;
            inherit:  "default" 0.0;
            visible: 1;
         }
      }
   }
   programs {
      program { name: "selected";
         target: "arrow";
         target: "select_line";
      }
      program { name: "unselected";
         target: "arrow";
         target: "select_line";
      }
      program {
         signal: "mouse,in"; source: "event";
         action: SIGNAL_EMIT "elm,action,open" "elm";
      }
//      program {
//         signal: "mouse,up,1"; source: "event";
//         action: SIGNAL_EMIT "elm,action,open" "elm";
//      }
   }
}

group { name: "elm/menu/separator/default";
   images {
      image: "separator_horiz.png" COMP;
   }
   parts {
      part { name: "separator";
         description { state: "default" 0.0;
            min: 2 2;
            rel1.offset: 0 2;
            rel2.offset: -1 -3;
            image.normal: "separator_horiz.png";
            fill.smooth: 0;
         }
      }
   }
}

group { name: "elm/menu/main_menu_submenu/default";
   images.image: "vgrad_med_dark.png" COMP;
   images.image: "bevel_out.png" COMP;
   images.image: "bevel_in.png" COMP;
   images.image: "shadow_rounded_horiz.png" COMP;
   images.image: "shine.png" COMP;
   script {
      public menu_text_visible; //0:hide (default), 1:visible
      public menu_disable; //0:enable, 1:disable
   }
   parts {
      part { name: "shadow"; mouse_events: 0;
         description { state: "default" 0.0;
            image.normal: "shadow_rounded_horiz.png";
            image.border: 0 0 9 9;
            rel1.offset: 0 -4;
            rel2.offset: -1 5;
            fill.smooth: 0;
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "base"; mouse_events: 0;
         description { state: "default" 0.0;
            image.normal: "vgrad_med_dark.png";
            fill.smooth: 0;
            TILED_HORIZ(120)
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "elm.swallow.content"; type: SWALLOW; mouse_events:  0;
         clip_to: "disabler";
         scale: 1;
         description { state: "default" 0.0;
            min: 16 16;
            fixed: 1 0;
            align: 0.0 0.5;
            rel1.offset: 3 3;
            rel2.offset: 3 -5;
            rel2.relative: 0.0 1.0;
         }
         description { state: "noicon" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      // XXX: check/radio goes next (right of) content, no radio/check handle
      // XXX: need to handle no text?
      // XXX: need arrowspace on/off based on submenus in menu
      part { name: "arrowspace"; type: SPACER;
         scale: 1;
         description { state: "default" 0.0;
            fixed: 1 1;
            min: 15 15;
            max: 15 15;
            rel1.offset: -2 0;
            rel1.relative: 1.0 0.0;
            rel2.offset: -2 -1;
            align: 1.0 0.5;
         }
      }
      part { name: "elm.text"; type: TEXT; mouse_events:  0;
         effect: SHADOW BOTTOM;
         scale: 1;
         description { state: "default" 0.0;
            rel1.to_x: "elm.swallow.content";
            rel1.relative: 1.0 0.0;
            rel1.offset: 5 -1;
            rel2.to_x: "arrowspace";
            rel2.offset: -6 -1;
            rel2.relative: 0.0 1.0;
            color: FN_COL_DEFAULT;
            text { font: FN; size: 10;
               min: 1 1;
               ellipsis: -1;
               align: 0.0 0.5;
               text_class: "menu_item";
            }
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
            visible: 0;
         }
      }
      part { name: "label2"; type: TEXT; mouse_events: 0;
         effect: SHADOW BOTTOM;
         scale: 1;
         description { state: "default" 0.0;
            rel1.to: "elm.text";
            rel2.to: "elm.text";
            color: FN_COL_DISABLE;
            color_class: "menu_item_disabled";
            text { font: FN; size: 10;
               text_source: "elm.text";
               align: 0.0 0.5;
               text_class: "menu_item";
            }
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
      }
      part { name: "label3"; type: TEXT; mouse_events: 0;
         effect: GLOW;
         scale: 1;
         description { state: "default" 0.0;
            rel1.offset: -2 -3;
            rel1.to: "elm.text";
            rel2.offset: 2 1;
            rel2.to: "elm.text";
            color: FN_COL_HIGHLIGHT;
            color_class: "menu_item_active";
            text { font: FN; size: 10;
               text_source: "elm.text";
               align: 0.0 0.5;
               text_class: "menu_item";
            }
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      part { name: "bevel0"; mouse_events: 0;
         clip_to: "bevelc";
         description { state: "default" 0.0;
            rel1.to: "bevel";
            rel1.offset: -1 -1;
            rel2.to: "bevel";
            rel2.offset: 0 0;
            image.normal: "bevel_in.png";
            image.border: 2 2 2 2;
            image.middle: 0;
            fill.smooth: 0;
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "bevelc"; type: RECT;
         description { state: "default" 0.0;
            rel1.to: "bevel";
            rel1.offset: -1 0;
            rel2.to: "bevel";
            rel2.offset: 0 -1;
         }
      }
      part { name: "bevel"; mouse_events: 0;
         description { state: "default" 0.0;
            image.normal: "bevel_out.png";
            image.border: 2 2 2 2;
            image.middle: 0;
            fill.smooth: 0;
            visible: 0;
         }
         description { state: "active" 0.0;
            inherit: "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "shine";
         repeat_events: 1;
         description { state: "default" 0.0;
            rel1.to: "base";
            rel1.offset: 0 -2;
            rel2.to: "base";
            rel2.relative: 1.0 0.0;
            rel2.offset: -1 2;
            image.normal: "shine.png";
            visible: 0;
            FIXED_SIZE(69, 5)
         }
         description { state: "active" 0.0;
            inherit:  "default" 0.0;
            visible: 1;
         }
         description { state: "disabled" 0.0;
            inherit:  "default" 0.0;
         }
      }
      part { name: "event"; type: RECT;
         ignore_flags: ON_HOLD;
         description { state: "default" 0.0;
            color: 255 255 255 0;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      part { name: "disabler"; type: RECT;
         description { state: "default" 0.0;
            color: 255 255 255 255;
         }
         description { state: "disabled" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 128;
         }
      }
   }
   programs {
      program {
         signal: "mouse,in"; source: "event";
         action: SIGNAL_EMIT "elm,action,activate" "elm";
         after: "selected";
      }
      program {
         signal: "mouse,out"; source: "event";
//         action: SIGNAL_EMIT "elm,action,inactivate" "elm";
         after: "unselected";
      }
      program { signal: "mouse,down,1"; source: "event";
         after: "selected";
      }
      program {
         signal: "mouse,down,1"; source: "event";
         action: SIGNAL_EMIT "elm,action,click" "elm";
      }
      program { name: "text_show";
         signal: "elm,state,text,visible"; source: "elm";
         script {
            set_int(menu_text_visible, 1);
//            set_state(PART:"elm.text", "active", 0.0);
//            set_state(PART:"elm.text2", "active", 0.0);
         }
      }
      program { name: "text_hide";
         signal: "elm,state,text,hidden"; source: "elm";
         script {
            set_int(menu_text_visible, 0);
//            set_state(PART:"elm.text", "default", 0.0);
//            set_state(PART:"elm.text2", "default", 0.0);
         }
      }
      program { name: "icon_show";
         signal: "elm,state,icon,visible"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "elm.swallow.content";
      }
      program { name: "icon_hide";
         signal: "elm,state,icon,hidden"; source: "elm";
         action: STATE_SET "noicon" 0.0;
         target: "elm.swallow.content";
      }
      program { name: "selected";
         signal: "elm,state,selected"; source: "elm";
         action: STATE_SET "active" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel0";
         target: "bevel";
         target: "shine";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
      program { name: "unselected";
         signal: "elm,state,unselected"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel0";
         target: "bevel";
         target: "shine";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
      program {
         signal: "elm,state,enabled"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel0";
         target: "bevel";
         target: "shine";
         target: "event";
         target: "disabler";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
      program {
         signal: "elm,state,disabled"; source: "elm";
         action: STATE_SET "disabled" 0.0;
         target: "shadow";
         target: "base";
         target: "bevel0";
         target: "bevel";
         target: "shine";
         target: "event";
         target: "disabler";
         target: "elm.text";
         target: "label2";
         target: "label3";
      }
   }
}

//In the hover used by the menu only the bottom part is used.
group { name: "elm/hover/base/menu/default";
   images {
      image: "vgrad_med_lighter.png" COMP;
      image: "bevel_out.png" COMP;
      image: "shine.png" COMP;
      image: "win_shadow.png" COMP;
   }
   parts {
      part { name: "elm.swallow.offset"; type: SWALLOW;
         description { state: "default" 0.0;
            align: 0.0 0.0;
            rel1.relative: 0.0 0.0;
            rel2.relative: 0.0 0.0;
         }
      }
      part { name: "elm.swallow.size"; type: SWALLOW;
         description { state: "default" 0.0;
            align: 0.0 0.0;
            rel1.to: "elm.swallow.offset";
            rel1.relative: 1.0 1.0;
            rel2.to: "elm.swallow.offset";
            rel2.relative: 1.0 1.0;
         }
      }
      part { name: "base"; type: RECT; repeat_events: 1;
         description { state: "default" 0.0;
            color: 0 0 0 0;
         }
      }
      part { name: "elm.swallow.slot.left"; type: SWALLOW;
         description { state: "default" 0.0;
         }
      }
      part { name: "elm.swallow.slot.right"; type: SWALLOW;
         description { state: "default" 0.0;
         }
      }
      part { name: "elm.swallow.slot.top"; type: SWALLOW;
         description { state: "default" 0.0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
      part { name: "bottomclip"; type: RECT;
         description { state: "default" 0.0;
            color: 255 255 255 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 255;
         }
      }
      part { name: "shadow";
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            image.normal: "win_shadow.png";
            image.border: 14 14 14 14;
            image.middle: 0;
            rel1.to: "bottom";
            rel1.offset: -7  -3;
            rel2.to: "bottom";
            rel2.offset: 6 11;
            fill.smooth: 0;
         }
      }
      part { name: "top";
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            image.normal: "vgrad_med_lighter.png";
            rel1.to: "bottom";
            rel2.to_x: "bottom";
            rel2.to_y: "shine";
            rel2.offset: -1 0;
            min: 0 23;
            align: 0.0 0.0;
            fill.smooth: 0;
            TILED_HORIZ(120)
            fixed: 0 1;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
      part { name: "bg"; type: RECT; mouse_events: 0;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            rel1.to_x: "bottom";
            rel1.to_y: "top";
            rel1.relative: 0.0 1.0;
            rel2.to: "bottom";
            color: 64 64 64 255;
         }
      }

      part { name: "bottom";
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            rel1.to: "elm.swallow.slot.bottom";
            rel1.offset: 0 -5;
            rel2.to: "elm.swallow.slot.bottom";
            rel2.offset: -1 4;
            image.normal: "bevel_out.png";
            image.border: 1 1 1 1;
            image.middle: 0;
            fill.smooth: 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
      part { name: "elm.swallow.slot.bottom"; type: SWALLOW;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            align: 0.5 0.0;
            rel1.to: "elm.swallow.slot.middle";
            rel1.relative: 0.0 1.0;
            rel1.offset: 0 0;
            rel2.to: "elm.swallow.slot.middle";
            rel2.relative: 1.0 1.0;
            rel2.offset: -1 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
      part { name: "bevel"; mouse_events: 0;
         description { state: "default" 0.0;
            rel1.to: "bottom";
            rel2.to: "bottom";
            image.normal: "bevel_out.png";
            image.border: 1 1 1 1;
            image.middle: 0;
            fill.smooth: 0;
         }
      }
      part { name: "shine"; mouse_events: 1;
         repeat_events:1;
         description { state: "default" 0.0;
            rel1.to: "bottom";
            rel1.offset: 0 -2;
            rel2.to: "bottom";
            rel2.relative: 1.0 0.0;
            rel2.offset: -1 2;
            image.normal: "shine.png";
            FIXED_SIZE(69, 5)
         }
      }
      part { name: "elm.swallow.slot.middle"; type: SWALLOW;
         repeat_events:1;
         description { state: "default" 0.0;
            rel1.to: "elm.swallow.size";
            rel2.to: "elm.swallow.size";
         }
      }
   }
   programs {
      program { name: "end";
         signal: "mouse,up,*"; source: "base";
         action: SIGNAL_EMIT "elm,action,dismiss" "elm";
      }
      program { name: "bottomshow";
         signal: "elm,action,slot,bottom,show"; source: "elm";
         action: STATE_SET "visible" 0.0;
         transition: DECELERATE 0.5;
         target: "bottomclip";
         target: "bottom";
         target: "elm.swallow.slot.bottom";
      }
      program { name: "bottomhide";
         signal: "elm,action,slot,bottom,hide"; source: "elm";
         action: STATE_SET "default" 0.0;
         transition: DECELERATE 0.5;
         target: "bottomclip";
         target: "bottom";
         target: "elm.swallow.slot.bottom";
      }
   }
}

//In the hover used by the submenu only the bottom part is used
//and no part should interact except the bottom area
group { name: "elm/hover/base/submenu/default";
   inherit: "elm/hover/base/menu/default";
   images {
      image: "vgrad_med.png" COMP;
   }
   parts {
      part { name: "elm.swallow.offset";
         repeat_events: 1;
      }
      //here we don't catch events like the hover does
      part { name: "base"; type: RECT; repeat_events: 1;
         description { state: "visible" 0.0;
            color: 0 0 0 0;
            visible: 0;
         }
      }
   }
}

group { name: "elm/hover/base/main_menu/default";
   images.image: "vgrad_med_lighter.png" COMP;
   images.image: "bevel_dark_out.png" COMP;
   parts {
      part { name: "elm.swallow.offset"; type: SWALLOW;
         description { state: "default" 0.0;
            visible: 0;
            fixed: 1 1;
         }
      }
      part { name: "elm.swallow.size"; type: SWALLOW;
         description { state: "default" 0.0;
            align: 0.0 0.0;
            rel2.relative: 0.0 0.0;
            rel1.offset: 0 0;
            fixed: 1 1;
         }
      }
      part { name: "bottomclip"; type: RECT;
         description { state: "default" 0.0;
            rel1.offset: -1 -2;
         }
      }
      part { name: "base";
         description { state: "default" 0.0;
            image.normal: "vgrad_med_lighter.png";
            rel1.to_y: "bottom";
            rel2.to_y: "bottom";
            fill.smooth: 0;
            TILED_HORIZ(120)
         }
      }
      part { name: "bevel"; mouse_events: 0;
         description { state: "default" 0.0;
            rel1.to: "base";
            rel2.to: "base";
            image.normal: "bevel_dark_out.png";
            image.border: 1 1 1 1;
            image.middle: 0;
            fill.smooth: 0;
         }
      }
      part { name: "bottom"; type: RECT;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            visible: 0;
            rel1.to: "elm.swallow.slot.bottom";
            rel1.offset: 0 0;
            rel2.to: "elm.swallow.slot.bottom";
            rel2.offset: -1 -1;
         }
      }
      part { name: "elm.swallow.slot.bottom"; type: SWALLOW;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            align: 0.5 0.0;
            rel1.to: "elm.swallow.size";
            rel1.relative: 0.0 1.0;
            rel2.to: "elm.swallow.size";
            fixed: 1 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
   }
   programs {
      program { name: "bottomshow";
         signal: "elm,action,slot,bottom,show"; source: "elm";
         action: STATE_SET "visible" 0.0;
         transition: DECELERATE 0.3;
         target: "elm.swallow.slot.bottom";
      }
   }
}

group { name: "elm/hover/base/main_menu_submenu/default";
   images.image: "vgrad_med_lighter.png" COMP;
   images.image: "bevel_out.png" COMP;
   images.image: "shine.png" COMP;
   images.image: "win_shadow.png" COMP;
   parts {
      part { name: "elm.swallow.offset"; type: SWALLOW;
         repeat_events:1;
         description { state: "default" 0.0;
            align: 0.0 0.0;
            rel2.relative: 0.0 0.0;
         }
      }
      part { name: "elm.swallow.size"; type: SWALLOW;
         description { state: "default" 0.0;
            align: 0.0 0.0;
            rel1.to: "elm.swallow.offset";
            rel1.relative: 1.0 1.0;
            rel2.to: "elm.swallow.offset";
         }
      }
      part { name: "base"; type: RECT; repeat_events: 1;
         description { state: "default" 0.0;
            color: 0 0 0 0;
         }
      }
      part { name: "bottomclip"; type: RECT;
         description { state: "default" 0.0;
            rel1.to_y: "pop";
            rel1.relative: 0.0 1.0;
            rel1.offset: -1 -2;
         }
      }
      part { name: "shadow";
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            image.normal: "win_shadow.png";
            image.border: 14 14 14 14;
            image.middle: 0;
            rel1.to: "bottom";
            rel1.offset: -7  -3;
            rel2.to: "bottom";
            rel2.offset: 6 11;
            fill.smooth: 0;
         }
      }
      part { name: "top";
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            image.normal: "vgrad_med_lighter.png";
            rel1.to: "bottom";
            rel2.to_x: "bottom";
            rel2.to_y: "shine";
            rel2.offset: -1 0;
            min: 0 23;
            align: 0.0 0.0;
            fill.smooth: 0;
            TILED_HORIZ(120)
            fixed: 0 1;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
      part { name: "bg"; type: RECT; mouse_events: 0;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            rel1.to_x: "bottom";
            rel1.to_y: "top";
            rel1.relative: 0.0 1.0;
            rel2.to: "bottom";
            color: 64 64 64 255;
         }
      }
      part { name: "bottom";
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            rel1.to: "elm.swallow.slot.bottom";
            rel1.offset: 0 -6;
            rel2.to: "elm.swallow.slot.bottom";
            rel2.offset: -1 4;
            image.normal: "bevel_out.png";
            image.border: 1 1 1 1;
            image.middle: 0;
            fill.smooth: 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
         }
      }
      part { name: "elm.swallow.slot.bottom"; type: SWALLOW;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            align: 0.5 1.0;
            rel1.to: "elm.swallow.slot.middle";
            rel1.relative: 0.0 1.0;
            rel1.offset: 0 0;
            rel2.to: "elm.swallow.slot.middle";
            rel2.relative: 1.0 1.0;
            rel2.offset: -1 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
            rel1.offset: 0 6;
            rel2.offset: -1 6;
            align: 0.5 0.0;
         }
      }
      part { name: "pop"; type: RECT; mouse_events: 1;
         repeat_events:1;
         description { state: "default" 0.0;
            rel1.to: "elm.swallow.slot.middle";
            rel1.offset: 0 0;
            rel2.to: "elm.swallow.slot.middle";
            rel1.relative: 0.0 1.0;
            rel2.offset: -1 0;
            visible: 0;
         }
      }
      part { name: "shine"; mouse_events: 0;
         clip_to: "bottomclip";
         description { state: "default" 0.0;
            rel1.to: "bottom";
            rel1.offset: 0 -2;
            rel2.to: "bottom";
            rel2.relative: 1.0 0.0;
            rel2.offset: -1 2;
            image.normal: "shine.png";
            FIXED_SIZE(69, 5)
         }
      }
      part { name: "elm.swallow.slot.middle"; type: SWALLOW;
         repeat_events:1;
         description { state: "default" 0.0;
            rel1.to: "elm.swallow.size";
            rel2.to: "elm.swallow.size";
         }
      }
   }
   programs {
      program { name: "end";
         signal: "mouse,up,*"; source: "base";
         action: SIGNAL_EMIT "elm,action,dismiss" "elm";
      }
      program { name: "show";
         signal: "elm,action,show"; source: "elm";
         action: STATE_SET "visible" 0.0;
         target: "base";
      }
      program { name: "hide";
         signal: "elm,action,hide"; source: "elm";
         action: STATE_SET "default" 0.0;
         target: "base";
      }
      program { name: "bottomshow";
         signal: "elm,action,slot,bottom,show"; source: "elm";
         action: STATE_SET "visible" 0.0;
         transition: DECELERATE 0.3;
         target: "bottom";
         target: "elm.swallow.slot.bottom";
      }
      program { name: "bottomhide";
         signal: "elm,action,slot,bottom,hide"; source: "elm";
         action: STATE_SET "default" 0.0;
         transition: DECELERATE 0.5;
         target: "bottom";
         target: "elm.swallow.slot.bottom";
      }
   }
}

