Work on a new panel widget. Still not complete yet, but it's started :)
authorChristopher Michael <cpmichael1@comcast.net>
Thu, 15 Oct 2009 20:34:11 +0000 (20:34 +0000)
committerChristopher Michael <cpmichael1@comcast.net>
Thu, 15 Oct 2009 20:34:11 +0000 (20:34 +0000)
SVN revision: 43100

data/themes/default.edc
src/bin/Makefile.am
src/bin/test.c
src/lib/Elementary.h.in
src/lib/Makefile.am
src/lib/elm_notify.c

index ee52db6bb1b26359c84df5ce6fed3eef53707c67..5321cea30b0e43e62538d5c15fa13554cfa58f52 100644 (file)
@@ -16748,4 +16748,103 @@ collections {
          }
       }
    }
+
+/////////////////////////////////////////////////////////////////////////////
+// PANEL
+////////////////////////////////////////////////////////////////////////////
+group 
+{
+   name: "elm/panel/base/default";
+   images 
+     {
+        image: "bt_dis_base.png" COMP;
+     }
+   parts 
+     {
+        part 
+          {
+             name: "base";
+             type: IMAGE;
+             mouse_events: 0;
+             description 
+               {
+                  state: "default" 0.0;
+                  color: 255 255 255 0;
+                  image 
+                    {
+                       normal: "bt_dis_base.png";
+                       border: 4 4 4 4;
+                    }
+               }
+             description 
+               {
+                  state: "visible" 0.0;
+                  inherit: "default" 0.0;
+                  color: 255 255 255 255;
+               }
+          }
+        part 
+          {
+             name: "elm.swallow.content";
+             type: SWALLOW;
+             description 
+               {
+                  state: "default" 0.0;
+                  rel2.offset: -48 -1;
+               }
+          }
+        part 
+          {
+             name: "elm.swallow.arrow";
+             type: SWALLOW;
+             description 
+               {
+                  state: "default" 0.0;
+                  aspect: 1.0 1.0;
+                  aspect_preference: HORIZONTAL;
+                  rel1 
+                    {
+                       relative: 1.0 0.0;
+                       to_x: "elm.swallow.content";
+                    }
+                  rel2.offset: -2 -1;
+               }
+          }
+     }
+   programs 
+     {
+        program 
+          {
+             name: "show";
+             signal: "elm,action,show";
+             source: "elm";
+             action: STATE_SET "visible" 0.0;
+             target: "base";
+          }
+        program 
+          {
+             name: "show2";
+             signal: "show";
+             action: STATE_SET "default" 0.0;
+             target: "base";
+             after: "show3";
+          }
+        program 
+          {
+             name: "show3";
+             action: STATE_SET "visible" 0.0;
+             target: "base";
+             transition: LINEAR 0.5;
+          }
+        program 
+          {
+             name: "hide";
+             signal: "elm,action,hide";
+             source: "elm";
+             action: STATE_SET "default" 0.0;
+             target: "base";
+          }
+     }
+}
+
 }
index aa610e007f7c2bccfd09d3577cfe8c7180d97915..833ca7b29639ec147070a6e12ebf561e3318f0a0 100644 (file)
@@ -63,7 +63,8 @@ test_photo.c \
 test_icon_desktops.c \
 test_notify.c \
 test_slideshow.c \
-test_menu.c
+test_menu.c \
+test_panel.c
 
 elementary_test_LDADD = $(top_builddir)/src/lib/libelementary.la
 elementary_test_LDFLAGS =
index 502758b6240c251547e8cbe39aba54c070cef1d9..9a493b7273d77a7422e8598748442ebedc999d11 100644 (file)
@@ -52,6 +52,7 @@ void test_icon_desktops(void *data, Evas_Object *obj, void *event_info);
 void test_notify(void *data, Evas_Object *obj, void *event_info);
 void test_slideshow(void *data, Evas_Object *obj, void *event_info);
 void test_menu(void *data, Evas_Object *obj, void *event_info);
+void test_panel(void *data, Evas_Object *obj, void *event_info);
 
 
 static void
@@ -187,8 +188,7 @@ my_win_main(void)
    elm_list_item_append(li, "Notify", NULL, NULL, test_notify, NULL);
    elm_list_item_append(li, "Slideshow", NULL, NULL, test_slideshow, NULL);
    elm_list_item_append(li, "Menu", NULL, NULL, test_menu, NULL);
-
-
+   elm_list_item_append(li, "Panel", NULL, NULL, test_panel, NULL);
 
    elm_list_go(li);
 
index dc1aac03fed5f0070dfe3ba6b351ca40ef8c9341..2da139286aa1e8f4d6cb3f6fca469b77a8de0ddb 100644 (file)
@@ -973,6 +973,18 @@ extern "C" {
     * "scroll,drag,stop" - dragging the contents around has stopped
     */
 
+   typedef enum _Elm_Panel_Orient
+     {
+        ELM_PANEL_ORIENT_TOP,
+        ELM_PANEL_ORIENT_BOTTOM,
+        ELM_PANEL_ORIENT_LEFT,
+        ELM_PANEL_ORIENT_RIGHT,
+     } Elm_Panel_Orient;
+     EAPI Evas_Object *elm_panel_add(Evas_Object *parent);
+     EAPI void         elm_panel_orient_set(Evas_Object *obj, Elm_Panel_Orient orient);
+     EAPI void         elm_panel_timeout_set(Evas_Object *obj, int timeout);
+     EAPI void         elm_panel_content_set(Evas_Object *obj, Evas_Object *content);
+
 #ifdef __cplusplus
 }
 #endif
index a424fbed5f09cb9812adcd3dd2b80d5ce9a4f041..2886ecab7b318f002763c9ba68b5691acfcbd62a 100644 (file)
@@ -65,6 +65,7 @@ elm_photocam.c \
 elm_notify.c \
 elm_slideshow.c \
 elm_menu.c \
+elm_panel.c \
 \
 elc_notepad.c \
 elc_anchorview.c \
index 66e0f70a3b8c5254f85cb02e991c25af008d8098..d19d8db3532ac60a68eddf4701ab026a8694e187 100644 (file)
@@ -65,7 +65,8 @@ _sizing_eval(Evas_Object *obj)
 static void
 _changed_size_hints(void *data, Evas *e, Evas_Object *obj, void *event_info)
 {
-   Widget_Data *wd = elm_widget_data_get(data);
+//   Widget_Data *wd = elm_widget_data_get(data);
+
    _sizing_eval(data);
 }
 
@@ -165,7 +166,7 @@ _show(void *data, Evas *e, Evas_Object *obj, void *event_info)
        ecore_timer_del(wd->timer);
        wd->timer = NULL;
      }
-   if (wd->timeout>0)
+   if (wd->timeout > 0)
      wd->timer = ecore_timer_add(wd->timeout, _timer_cb, obj);
 }
 
@@ -322,7 +323,7 @@ elm_notify_timer_init(Evas_Object *obj)
 
    if (wd->timer) ecore_timer_del(wd->timer);
    wd->timer = NULL;
-   if (wd->timeout>0)
+   if (wd->timeout > 0)
      wd->timer = ecore_timer_add(wd->timeout, _timer_cb, obj);
 }