From: Juyeon Lee Date: Fri, 30 Jun 2017 07:25:42 +0000 (+0900) Subject: add effect style zoom-easeout-mask using circle_mask X-Git-Tag: submit/tizen_3.0/20170704.032921~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F55%2F136555%2F2;p=platform%2Fcore%2Fuifw%2Fe-mod-tizen-effect.git add effect style zoom-easeout-mask using circle_mask swallow contents are clip to 'clipper' which is using circle_mask to support wearable profile Change-Id: I9ba0a8ef05eb5588566eb35fd5f1544bdf5e2ab1 --- diff --git a/data/Makefile.am b/data/Makefile.am index d3f4d74..ff80e91 100644 --- a/data/Makefile.am +++ b/data/Makefile.am @@ -1,16 +1,17 @@ MAINTAINERCLEANFILES = Makefile.in EDJE_CC = @EDJE_CC@ -EDJE_CC_FLAGS = -v +EDJE_CC_FLAGS = -v -id $(top_srcdir)/data/img filesdir = /usr/share/enlightenment/data/themes files_DATA = effect.edj EXTRA_DIST = \ -effect.edc + effect.edc \ + img/circle_mask.png effect.edj: Makefile $(EXTRA_DIST) - $(EDJE_CC) $(EDJE_FLAGS) \ + $(EDJE_CC) $(EDJE_CC_FLAGS) \ $(top_srcdir)/data/effect.edc \ $(top_builddir)/data/effect.edj diff --git a/data/effect.edc b/data/effect.edc index b13b221..c050f9b 100644 --- a/data/effect.edc +++ b/data/effect.edc @@ -19,10 +19,15 @@ collections { #include "group/zoom.edc" /*-----------------------------------------------------*/ - /* group "e/comp/effects/zoom-easeout" */ + /* group "e/comp/effects/zoom-easeout" */ /*-----------------------------------------------------*/ #include "group/zoom-easeout.edc" + /*-----------------------------------------------------*/ + /* group "e/comp/effects/zoom-easeout-mask" */ + /*-----------------------------------------------------*/ + #include "group/zoom-easeout-mask.edc" + /*-----------------------------------------------------*/ /* group "e/comp/effects/keyboard" */ /*-----------------------------------------------------*/ diff --git a/data/group/zoom-easeout-mask.edc b/data/group/zoom-easeout-mask.edc new file mode 100644 index 0000000..cd9ec3a --- /dev/null +++ b/data/group/zoom-easeout-mask.edc @@ -0,0 +1,319 @@ +group { name: "e/comp/effects/zoom-easeout-mask"; + script { + public message(Msg_Type:type, id, ...) { + if ((type == MSG_INT_SET) && (id == 0)) { + /*set state */ + new st; + st = getarg(2); + if (st == 0) + { + set_state(PART:"clipper", "default", 0.0); + set_state(PART:"shower", "default", 0.0); + set_state(PART:"e.swallow.content", "default", 0.0); + set_state(PART:"under", "default", 0.0); + } + else if (st == 1) + { + set_state(PART:"clipper", "visible", 0.0); + set_state(PART:"shower", "visible", 0.0); + set_state(PART:"e.swallow.content", "visible", 0.0); + set_state(PART:"under", "visible", 0.0); + } + else if (st == 2) + { + set_state(PART:"clipper", "restack_hidden", 0.0); + set_state(PART:"shower", "restack_hidden", 0.0); + set_state(PART:"e.swallow.content", "restack_hidden", 0.0); + set_state(PART:"under", "restack_hidden", 0.0); + } + else if (st == 3) + { + set_state(PART:"clipper", "restack_visible", 0.0); + set_state(PART:"shower", "restack_visible", 0.0); + set_state(PART:"e.swallow.content", "restack_visible", 0.0); + set_state(PART:"under", "restack_visible", 0.0); + } + else if (st == 4) + { + set_state(PART:"clipper", "restack_done", 0.0); + set_state(PART:"shower", "restack_done", 0.0); + set_state(PART:"e.swallow.content", "restack_done", 0.0); + set_state(PART:"under", "restack_done", 0.0); + } + } else if ((type == MSG_INT_SET) && (id == 1)) + { + } + } + } + images.image: "circle_mask.png" COMP; + parts { + part { name: "shower"; + type: SPACER; + description { state: "default" 0.0; + rel1.relative: 0 0; + rel2.relative: 1 1; + } + description { state: "visible" 0.0; + inherit: "default" 0.0; + rel1.relative: 0 0; + rel1.offset: 0 0; + rel2.relative: 1 1; + } + description { state: "hide" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_visible" 0.0; + inherit: "visible" 0.0; + } + description { state: "restack_hidden" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_done" 0.0; + inherit: "visible" 0.0; + } + } + part { name: "e.swallow.content"; type: SWALLOW; + type: SWALLOW; + clip_to: "clipper"; + description { state: "default" 0.0; + rel1.to: "shower"; + rel2.to: "shower"; + map { + on: 1; + smooth: 1; + zoom.x: 0.6; + zoom.y: 0.6; + } + } + description { state: "visible" 0.0; + rel1.to: "shower"; + rel2.to: "shower"; + map { + on: 1; + smooth: 1; + zoom.x: 1; + zoom.y: 1; + } + } + description { state: "visible_default" 0.0; + rel1.to: "shower"; + rel2.to: "shower"; + rel1.relative: 0 0; + rel2.relative: 1 1; + map.on : 0; + } + description { state: "hide" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_visible" 0.0; + inherit: "visible" 0.0; + } + description { state: "restack_hidden" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_done" 0.0; + inherit: "visible" 0.0; + } + } + part { name: "under"; + type: SWALLOW; + clip_to: "clipper"; + description { state: "default" 0.0; + rel1.to: "shower"; + rel2.to: "shower"; + map { + on: 1; + smooth: 1; + zoom.x: 0.6; + zoom.y: 0.6; + } + } + description { state: "visible" 0.0; + rel1.to: "shower"; + rel2.to: "shower"; + map { + on: 1; + smooth: 1; + zoom.x: 1; + zoom.y: 1; + } + } + description { state: "visible_default" 0.0; + rel1.to: "shower"; + rel2.to: "shower"; + rel1.relative: 0 0; + rel2.relative: 1 1; + map.on : 0; + } + description { state: "hide" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_visible" 0.0; + inherit: "visible" 0.0; + } + description { state: "restack_hidden" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_done" 0.0; + inherit: "visible" 0.0; + } + } + part { name: "clipper"; + type: IMAGE; + mouse_events: 0; + description { state: "default" 0.0; + color: 255 255 255 0; + image.normal: "circle_mask.png"; + visible: 1; + map { + on: 1; + smooth: 1; + zoom.x: 0.6; + zoom.y: 0.6; + } + } + description { state: "visible" 0.0; + inherit: "default" 0.0; + color: 255 255 255 255; + map { + on: 1; + smooth: 1; + zoom.x: 1; + zoom.y: 1; + } + } + description { state: "visible_default" 0.0; + inherit: "visible" 0.0; + map.on : 0; + } + description { state: "hide" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_visible" 0.0; + inherit: "visible" 0.0; + } + description { state: "restack_hidden" 0.0; + inherit: "default" 0.0; + } + description { state: "restack_done" 0.0; + inherit: "visible" 0.0; + } + } + } + programs { + program { name: "show1"; + signal: "e,action,go"; + source: "e"; + filter: "shower" "default"; + action: STATE_SET "default" 0.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "show2"; + } + program { name: "show2"; + action: STATE_SET "visible" 0.0; + transition: CUBIC_BEZIER 0.4 0.25 0.46 0.45 1.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "show3"; + } + program { name: "show3"; + action: STATE_SET "visible_default" 0.0; + target: "under"; + target: "e.swallow.content"; + after: "done"; + } + program { name: "hide1"; + signal: "e,action,go"; + source: "e"; + filter: "shower" "visible"; + action: STATE_SET "visible" 0.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "hide2"; + } + program { name: "hide2"; + action: STATE_SET "hide" 0.0; + transition: CUBIC_BEZIER 0.4 0.25 0.46 0.45 1.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "hide3"; + } + program { name: "hide3"; + action: STATE_SET "default" 0.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "done"; + } + program { name: "restack,show1"; + signal: "e,action,go"; + source: "e"; + filter: "shower" "restack_hidden"; + action: STATE_SET "restack_hidden" 0.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "restack,show2"; + } + program { name: "restack,show2"; + action: STATE_SET "visible" 0.0; + transition: CUBIC_BEZIER 0.4 0.25 0.46 0.45 1.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "restack,show3"; + } + program { name: "restack,show3"; + action: STATE_SET "visible_default" 0.0; + target: "e.swallow.content"; + target: "under"; + after: "done"; + } + program { name: "restack,hide1"; + signal: "e,action,go"; + source: "e"; + filter: "shower" "restack_visible"; + action: STATE_SET "restack_visible" 0.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "restack,hide2"; + } + program { name: "restack,hide2"; + action: STATE_SET "hide" 0.0; + transition: CUBIC_BEZIER 0.4 0.25 0.46 0.45 1.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "done"; + } + program { name: "restack,finish"; + signal: "e,action,go"; + source: "e"; + filter: "shower" "restack_done"; + action: STATE_SET "visible" 0.0; + target: "shower"; + target: "clipper"; + target: "e.swallow.content"; + target: "under"; + after: "done"; + } + program { name: "done"; + action: SIGNAL_EMIT "e,action,done" "e"; + } + } +} diff --git a/data/img/circle_mask.png b/data/img/circle_mask.png new file mode 100644 index 0000000..9c42a18 Binary files /dev/null and b/data/img/circle_mask.png differ