Skip to content
Permalink
Browse files

Position: set "at" option while align to cursor, fixes collision:flip…

… not work with default value
  • Loading branch information
chicheng committed Aug 2, 2009
1 parent abeb13a commit a962d52902bdccbd9d91ecc419750c0d5d3abcac
Showing with 2 additions and 1 deletion.
  1. +2 −1 ui/ui.position.js
@@ -38,7 +38,8 @@ $.fn.position = function(options) {
targetHeight = target.height();
basePosition = { top: target.scrollTop(), left: target.scrollLeft() };
} else if (options.of.preventDefault) {
options.at = "left top"; // while align to cursor, "at" default value "center" causes "collision:flip" not work.
// while align to cursor, "at" default value "center" causes "collision:flip" not work
options.at = "left top";
targetWidth = targetHeight = 0;
basePosition = { top: options.of.pageY, left: options.of.pageX };
} else {

0 comments on commit a962d52

Please sign in to comment.
You can’t perform that action at this time.