Improve slideshow gadget theme

master
Stephen Houston 5 years ago
parent f56395a2ba
commit ced5750c9b
  1. 32
      data/themes/ephoto.edc
  2. 2
      src/bin/ephoto_main.c
  3. 4
      src/bin/ephoto_slideshow.c

@ -40,6 +40,10 @@ collections {
state: "default" 0.0;
color: 0 0 0 255;
}
description {
state: "gadget" 0.0;
color: 115 115 115 45;
}
}
rect { "slide_clip";
scale: 1;
@ -119,6 +123,18 @@ collections {
}
}
programs {
program {
signal: "gadget";
source: "ephoto";
action: STATE_SET "gadget" 0.0;
target: "background";
}
program {
signal: "default";
source: "ephoto";
action: STATE_SET "default" 0.0;
target: "background";
}
program {
signal: "ephoto,fade";
source: "ephoto";
@ -330,6 +346,10 @@ collections {
state: "default" 0.0;
color: 0 0 0 255;
}
description {
state: "gadget" 0.0;
color: 0 0 0 0;
}
}
rect { "slide_clip";
scale: 1;
@ -668,6 +688,18 @@ collections {
}
}
programs {
program {
signal: "gadget";
source: "ephoto";
action: STATE_SET "gadget" 0.0;
target: "background";
}
program {
signal: "default";
source: "ephoto";
action: STATE_SET "default" 0.0;
target: "background";
}
program {
signal: "ephoto,slideshow,move,left,to,right";
source: "ephoto";

@ -400,7 +400,7 @@ ephoto_window_add(const char *path, int gadget)
ephoto->win = elm_win_add(NULL, "ephoto", ELM_WIN_BASIC);
elm_win_title_set(ephoto->win, "Ephoto");
elm_win_alpha_set(ephoto->win, 1);
evas_object_size_hint_aspect_set(ephoto->win, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
evas_object_size_hint_aspect_set(ephoto->win, EVAS_ASPECT_CONTROL_BOTH, 1,1);
}
if (!ephoto->win)
{

@ -418,6 +418,8 @@ _slideshow_item_get(Ephoto_Slideshow *ss, Ephoto_Entry *entry, Evas_Object *pare
layout = elm_layout_add(parent);
elm_layout_file_set(layout, PACKAGE_DATA_DIR "/themes/ephoto.edj",
"ephoto,slideshow,item");
if (ss->ephoto->gadget)
elm_layout_signal_emit(layout, "gadget", "ephoto");
EPHOTO_EXPAND(layout);
EPHOTO_FILL(layout);
evas_object_data_set(layout, "entry", entry);
@ -1076,6 +1078,8 @@ ephoto_slideshow_add(Ephoto *ephoto, Evas_Object *parent)
elm_layout_file_set(slideshow, PACKAGE_DATA_DIR "/themes/ephoto.edj",
"ephoto,slideshow,base");
if (ephoto->gadget)
elm_layout_signal_emit(slideshow, "gadget", "ephoto");
evas_object_event_callback_add(slideshow, EVAS_CALLBACK_DEL, _slideshow_del,
ss);
if (!ephoto->gadget)

Loading…
Cancel
Save