PIE icon indicating copy to clipboard operation
PIE copied to clipboard

-pie-watch-ancestors does not appear to work on suckerfish nor jquery ui tabs

Open glodigital-michael opened this issue 14 years ago • 3 comments

With beta3 of CSS3PIE I am experiencing an issue with the style not updating on class change or hover of the parent. For example consider the stylesheet below.

ul.sf-menu > li > a { behavior: url(/PIE.htc); -pie-watch-ancestors: true; }

ul.sf-menu > li.over > a, ul.sf-menu > li:hover > a { border-radius: 16px; -webkit-border-radius: 16px; -moz-border-radius: 16px; background: #000 }

When I hover over the list item in a suckerfish menu the black rounded background appears just fine. But when I move my mouse off the menu item the black background remains, until I mouse over the item again. It is not consistent, but it appears that moving the mouse quickly makes it work fine, but if you stay hovered for more than say 200ms then it stops working.

Am I doing something wrong or is this a bug?

This part makes it appear to me like it should work

            while( a && ( watch === 'NaN' || i++ < watch ) ) {
                ancestors.push( a );
                addListener( a, 'onpropertychange', ancestorPropChanged );
                addListener( a, 'onmouseenter', mouseEntered );
                addListener( a, 'onmouseleave', mouseLeft );
                a = a.parentNode;
            }

glodigital-michael avatar Dec 22 '10 06:12 glodigital-michael

I believe the correct syntax is -pie-watch-ancestors: 1;. I was having a similar problem and adding this to my css seems to have helped.

jstoller avatar May 31 '11 00:05 jstoller

@jstoller @glodigital-michael Using -pie-watch-ancestors: 1; in my CSS for Jquery UI tabs, worked for me. I was having the issue of jQuery UI tabs to continue to be highlighted after hover/click, when using PIE.js on them.

program247365 avatar May 08 '12 20:05 program247365

And its important to understand that the 1 in -pie-watch-ancestors: 1; must not be interpreted as a boolean who activate the ancestors watch function but interpret it as the depth number of ancestor to watch. Ex: -pie-watch-ancestors: 5; means: listen the modification of 5 ancestor of the element.

leblangi avatar Jun 03 '12 14:06 leblangi