brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From henev...@apache.org
Subject [07/36] brooklyn-ui git commit: Uses text() rather than html() when copying to clipboard
Date Mon, 01 Feb 2016 17:52:13 GMT
Uses text() rather than html() when copying to clipboard


Project: http://git-wip-us.apache.org/repos/asf/brooklyn-ui/repo
Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-ui/commit/4ff97a22
Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-ui/tree/4ff97a22
Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-ui/diff/4ff97a22

Branch: refs/heads/0.8.0-incubating
Commit: 4ff97a22558fbeaee781f1d0fa216812e4e67732
Parents: 6a3fbfd
Author: Martin Harris <github@nakomis.com>
Authored: Mon Jul 27 09:18:27 2015 +0100
Committer: Martin Harris <github@nakomis.com>
Committed: Mon Jul 27 09:18:27 2015 +0100

----------------------------------------------------------------------
 usage/jsgui/src/main/webapp/assets/js/view/entity-config.js  | 4 ++--
 usage/jsgui/src/main/webapp/assets/js/view/entity-sensors.js | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/brooklyn-ui/blob/4ff97a22/usage/jsgui/src/main/webapp/assets/js/view/entity-config.js
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/js/view/entity-config.js b/usage/jsgui/src/main/webapp/assets/js/view/entity-config.js
index befd9f2..f517bcb 100644
--- a/usage/jsgui/src/main/webapp/assets/js/view/entity-config.js
+++ b/usage/jsgui/src/main/webapp/assets/js/view/entity-config.js
@@ -180,11 +180,11 @@ define([
                     // the zeroClipboard instance is a singleton so check our scope first
                     if (!$(this).closest("#config-table").length) return;
                     var text = $(this).attr('copy-value');
-                    if (!text) text = $(this).closest('.floatGroup').find('.value').html();
+                    if (!text) text = $(this).closest('.floatGroup').find('.value').text();
                     
 //                    log("Copying config text '"+text+"' to clipboard");
                     client.setText(text);
-                    
+
                     // show the word "copied" for feedback;
                     // NB this occurs on mousedown, due to how flash plugin works
                     // (same style of feedback and interaction as github)

http://git-wip-us.apache.org/repos/asf/brooklyn-ui/blob/4ff97a22/usage/jsgui/src/main/webapp/assets/js/view/entity-sensors.js
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/js/view/entity-sensors.js b/usage/jsgui/src/main/webapp/assets/js/view/entity-sensors.js
index 7fbf90e..282c622 100644
--- a/usage/jsgui/src/main/webapp/assets/js/view/entity-sensors.js
+++ b/usage/jsgui/src/main/webapp/assets/js/view/entity-sensors.js
@@ -188,8 +188,8 @@ define([
                     // the zeroClipboard instance is a singleton so check our scope first
                     if (!$(this).closest("#sensors-table").length) return;
                     var text = $(this).attr('copy-value');
-                    if (!text) text = $(this).closest('.floatGroup').find('.value').html();
-                    
+                    if (!text) text = $(this).closest('.floatGroup').find('.value').text();
+
 //                    log("Copying sensors text '"+text+"' to clipboard");
                     client.setText(text);
                     


Mime
View raw message