--- /dev/null
+/*
+ * Copyright 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+// Copied from default theme in order to inherit
+group{ "elm/button/base/transparent";
+ script {
+ public mouse_down = 0;
+ public multi_down = 0;
+ }
+ parts {
+ spacer { "bg";
+ scale;
+ desc { "default";
+ }
+ desc { "disabled";
+ inherit: "default";
+ }
+ }
+ swallow { "elm.swallow.content";
+ scale;
+ desc { "default";
+ }
+ }
+ rect { "event";
+ scale;
+ repeat;
+ desc { "default";
+ color: 0 0 0 0;
+ }
+ }
+ }
+ programs {
+ program { "pressed";
+ signal: "mouse,down,1*";
+ source: "event";
+ script {
+ if ((get_int(multi_down) == 0) && (get_int(mouse_down) == 0)) {
+ set_int(mouse_down, 1);
+ run_program(PROGRAM:"button_press1");
+ }
+ }
+ }
+ program { "button_press1";
+ script {
+ new st[31];
+ new Float:vl;
+ get_state(PART:"bg", st, 30, vl);
+ if (strcmp(st, "disabled")) {
+ emit("elm,action,press", "");
+ }
+ }
+ }
+ program { "unpressed";
+ signal: "mouse,up,1";
+ source: "event";
+ script {
+ if (get_int(mouse_down) == 1) {
+ set_int(mouse_down, 0);
+ run_program(PROGRAM:"button_unpress1");
+ }
+ }
+ }
+ program { "button_unpress1";
+ script {
+ new st[31];
+ new Float:vl;
+ get_state(PART:"bg", st, 30, vl);
+ if (strcmp(st, "disabled")) {
+ emit("elm,action,unpress", "");
+ }
+ }
+ }
+ program { "touch_snd";
+ signal: "mouse,clicked,1";
+ source: "event";
+ script {
+ new st[31];
+ new Float:vl;
+ if (get_int(multi_down) == 0) {
+ get_state(PART:"bg", st, 30, vl);
+ if (strcmp(st, "disabled")) {
+ run_program(PROGRAM:"touch_sound");
+ emit("elm,action,click", "");
+ }
+ }
+ }
+ }
+ program { "touch_sound";
+ action: RUN_PLUGIN "touch_sound";
+ }
+ program { "disable";
+ signal: "elm,state,disabled";
+ source: "elm";
+ action: STATE_SET "disabled";
+ target: "bg";
+ }
+ program { "enable";
+ signal: "elm,state,enabled";
+ source: "elm";
+ action: STATE_SET "default";
+ target: "bg";
+ }
+ program { "multi_down";
+ signal: "elm,action,multi,down";
+ source: "elm";
+ script {
+ set_int(multi_down, 1);
+ }
+ }
+ program { "multi_up";
+ signal: "elm,action,multi,up";
+ source: "elm";
+ script {
+ set_int(multi_down, 0);
+ }
+ }
+ }
+}
+
+group{ "elm/button/base/gallery_image";
+ inherit: "elm/button/base/transparent";
+ parts {
+ rect { "event";
+ desc { "default";
+ color: GALLERY_COLOR_IMG_EF_NORMAL;
+ }
+ desc { "pressed";
+ inherit: "default";
+ color: GALLERY_COLOR_IMG_EF_PRESSED;
+ }
+ desc { "disabled";
+ inherit: "default";
+ color: GALLERY_COLOR_IMG_EF_DISABLED;
+ }
+ }
+ }
+ programs {
+ program { "on_disabled";
+ signal: "elm,state,disabled";
+ source: "elm";
+ action: STATE_SET "disabled";
+ target: "event";
+ }
+ program { "on_enabled";
+ signal: "elm,state,enabled";
+ source: "elm";
+ action: STATE_SET "default";
+ target: "event";
+ }
+ program { "on_press";
+ signal: "elm,action,press";
+ source: "";
+ action: STATE_SET "pressed";
+ target: "event";
+ }
+ program { "on_unpress";
+ signal: "elm,action,unpress";
+ source: "";
+ action: STATE_SET "default";
+ target: "event";
+ }
+ }
+}
--- /dev/null
+/*
+ * Copyright 2017 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.1 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://floralicense.org/license/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __GALLERY_EDC_COLORS_H__
+#define __GALLERY_EDC_COLORS_H__
+
+#define GALLERY_COLOR_AO0112 0 0 0 0
+#define GALLERY_COLOR_AO0112P 0 0 0 102
+#define GALLERY_COLOR_AO0112D 0 0 0 77
+
+#define GALLERY_COLOR_IMG_EF_NORMAL GALLERY_COLOR_AO0112
+#define GALLERY_COLOR_IMG_EF_PRESSED GALLERY_COLOR_AO0112P
+#define GALLERY_COLOR_IMG_EF_DISABLED GALLERY_COLOR_AO0112D
+
+#endif // __GALLERY_EDC_COLORS_H__