Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2013-02-08 21:09:36 +04:00
parent 04e97dbefb
commit a2c77e8e82

View File

@ -12,13 +12,13 @@
// move element to target and atach it at position
// position can be 'before', 'after' (default), 'prepend' or 'append'
function moveElementTo(elem, target, position){
position = position != null ? position : 'after'
elem
.detach()
[position == 'after'? 'insertAfter'
: position == 'before'? 'insertBefore'
[position == 'before'? 'insertBefore'
: position == 'append'? 'appendTo'
: position == 'prepend'? 'prependTo'](target)
: position == 'prepend'? 'prependTo'
// the default...
: 'insertAfter'](target)
return elem
}
@ -206,9 +206,6 @@ function removePage(page){
return page
}
/******************************************************* page sets ***/
function
/*********************************************************************/