aboutsummaryrefslogtreecommitdiffstats
path: root/demos/real-world/layout/demo.js
diff options
context:
space:
mode:
authorJörn Zaefferer <joern.zaefferer@gmail.com>2008-09-03 14:29:16 +0000
committerJörn Zaefferer <joern.zaefferer@gmail.com>2008-09-03 14:29:16 +0000
commit7084fa079da7315ee9e3eabfa1abd6009837bb76 (patch)
treedbbe6291fe3510b2ad371d4afd30de5ebef92a0a /demos/real-world/layout/demo.js
parent6174fef86fa61c86381283361364d2242b94e739 (diff)
downloadjquery-ui-7084fa079da7315ee9e3eabfa1abd6009837bb76.tar.gz
jquery-ui-7084fa079da7315ee9e3eabfa1abd6009837bb76.zip
layout demo: add new components via cloned draggables, connected to sortables
Diffstat (limited to 'demos/real-world/layout/demo.js')
-rw-r--r--demos/real-world/layout/demo.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/demos/real-world/layout/demo.js b/demos/real-world/layout/demo.js
index d93c76d4c..039f1463d 100644
--- a/demos/real-world/layout/demo.js
+++ b/demos/real-world/layout/demo.js
@@ -81,11 +81,15 @@
//placeholder: 'placeholder',
connectWith: els,
start: function(e,ui) {
- ui.helper.css("width", ui.item.width());
+ ui.helper.css("width", ui.item.parent().width());
},
change: sortableChange,
update: sortableUpdate
});
+ $('#components > dl').draggable({
+ connectToSortable: $els,
+ helper: 'clone'
+ })
});
$(window).bind('load',function(){