raster pushed a commit to branch master.
commit 1f9dfc0d626013aa5fa676ae5c5941a75a8080af
Author: Thiep Ha <[email protected]>
Date: Tue May 21 09:16:15 2013 +0900
Add selection handlers to entry
---
ChangeLog | 4 ++
NEWS | 1 +
data/themes/Makefile.am | 2 +
data/themes/images/handler_end.png | Bin 0 -> 3843 bytes
data/themes/images/handler_start.png | Bin 0 -> 3775 bytes
data/themes/widgets/entry.edc | 128 ++++++++++++++++++++++++++++++++++-
6 files changed, 134 insertions(+), 1 deletion(-)
diff --git a/ChangeLog b/ChangeLog
index 3fb06bc..7175dae 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1352,3 +1352,7 @@
2013-05-16 Ryuan Choi (ryuan)
* Fix single line enty got multiple line when pasted multiple line.
+
+2013-05-17 Thiep Ha
+
+ * Add selection handlers to entry.
diff --git a/NEWS b/NEWS
index fd67773..7b115c0 100644
--- a/NEWS
+++ b/NEWS
@@ -68,6 +68,7 @@ Additions:
* Add elm_layout smart callback - "language,changed".
* The momentum animation time is changed as the amount of flick.
* Add elm_entry smart callback - "text,set,done".
+ * Add selection handlers to entry.
Improvements:
diff --git a/data/themes/Makefile.am b/data/themes/Makefile.am
index 47af396..5575508 100644
--- a/data/themes/Makefile.am
+++ b/data/themes/Makefile.am
@@ -172,6 +172,8 @@ images/cur_hi.png \
images/cur_shad.png \
images/cur_shine.png \
images/cur_glow.png \
+images/handler_start.png \
+images/handler_end.png \
images/bubble.png \
images/bubble_3.png \
images/bubble_shine3.png \
diff --git a/data/themes/images/handler_end.png
b/data/themes/images/handler_end.png
new file mode 100644
index 0000000..07778a0
Binary files /dev/null and b/data/themes/images/handler_end.png differ
diff --git a/data/themes/images/handler_start.png
b/data/themes/images/handler_start.png
new file mode 100644
index 0000000..eb26daf
Binary files /dev/null and b/data/themes/images/handler_start.png differ
diff --git a/data/themes/widgets/entry.edc b/data/themes/widgets/entry.edc
index bc51121..238978e 100644
--- a/data/themes/widgets/entry.edc
+++ b/data/themes/widgets/entry.edc
@@ -751,7 +751,7 @@ group { name: "elm/entry/base/default";
mouse_events: 1;
scale: 1;
entry_mode: EDITABLE;
- select_mode: EXPLICIT;
+ select_mode: BLOCK_HANDLE;
multiline: 1;
source: "elm/entry/selection/default"; // selection under
// source2: "X"; // selection over
@@ -759,6 +759,8 @@ group { name: "elm/entry/base/default";
source4: "elm/entry/cursor/default"; // cursorover
source5: "elm/entry/anchor/default"; // anchor under
// source6: "X"; // anchor over
+ source7: "elm/entry/handler/start/default";
+ source8: "elm/entry/handler/end/default";
description { state: "default" 0.0;
/* we gotta use 0 0 here, because of scrolled entries */
fixed: 0 0;
@@ -1414,4 +1416,128 @@ group { name: "elm/entry/anchor/default";
}
}
}
+group { name: "elm/entry/handler/start/default";
+ images {
+ image: "handler_start.png" COMP;
+ }
+ parts {
+ part { name: "bg";
+ type: RECT;
+ mouse_events: 0;
+ scale: 1;
+ description { state: "default" 0.0;
+ visible: 0;
+ color: 0 0 0 0;
+ }
+ description { state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ part { name: "handler";
+ mouse_events: 1;
+ repeat_events: 0;
+ scale: 1;
+ description { state: "default" 0.0;
+ visible: 0;
+ align: 1 0;
+ fixed: 1 1;
+ min: 36 50;
+ image {
+ normal: "handler_start.png";
+ }
+ rel1 {
+ to: "bg";
+ relative: 0 1;
+ }
+ rel2 {
+ to: "bg";
+ relative: 0 1;
+ }
+ }
+ description { state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ }
+ programs {
+ program { name: "show";
+ signal: "edje,handler,show";
+ source: "edje";
+ action: STATE_SET "show" 0.0;
+ target: "bg";
+ target: "handler";
+ }
+ program { name: "hide";
+ signal: "edje,handler,hide";
+ source: "edje";
+ action: STATE_SET "default" 0.0;
+ target: "bg";
+ target: "handler";
+ }
+ }
+}
+group { name: "elm/entry/handler/end/default";
+ images {
+ image: "handler_end.png" COMP;
+ }
+ parts {
+ part { name: "bg";
+ type: RECT;
+ mouse_events: 0;
+ scale: 1;
+ description { state: "default" 0.0;
+ visible: 0;
+ color: 0 0 0 0;
+ }
+ description { state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ part { name: "handler";
+ mouse_events: 1;
+ repeat_events: 0;
+ scale: 1;
+ description { state: "default" 0.0;
+ visible: 0;
+ align: 0 0;
+ fixed: 1 1;
+ min: 36 50;
+ image {
+ normal: "handler_end.png";
+ }
+ rel1 {
+ to: "bg";
+ relative: 1 1;
+ }
+ rel2 {
+ to: "bg";
+ relative: 1 1;
+ }
+ }
+ description { state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ }
+ programs {
+ program { name: "show";
+ signal: "edje,handler,show";
+ source: "edje";
+ action: STATE_SET "show" 0.0;
+ target: "bg";
+ target: "handler";
+ }
+ program { name: "hide";
+ signal: "edje,handler,hide";
+ source: "edje";
+ action: STATE_SET "default" 0.0;
+ target: "bg";
+ target: "handler";
+ }
+ }
+}
--
------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may