#NEWLINE# def isContainedIn( self , container , et ) : #NEWLINE# #INDENT# if ( container is None ) : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# return DOM . isOrHasChild ( et , container ) #NEWLINE# part = et #NEWLINE# '\n        * In Chrome and FF2, the next line makes dropdown lists inside\n        * hover widgets work more correctly when they click on the\n        * dropdown part of the list. Otherwise, hover widget can close\n        * inappropriately. As tested in GChartExample20a.java\n        *\n        ' #NEWLINE# if ( None == part ) : #NEWLINE# #INDENT# return True #NEWLINE# #UNINDENT# try : #NEWLINE# #INDENT# ancestor = part #NEWLINE# while ( ( ancestor is not None ) and ( container is not None ) ) : #NEWLINE# #INDENT# if DOM . isSameNode ( container , ancestor ) : #NEWLINE# #INDENT# return True #NEWLINE# #UNINDENT# ancestor = ancestor . getParentElement ( ) #NEWLINE# #UNINDENT# #UNINDENT# except : #NEWLINE# #INDENT# '\n            * In FF2, we get the error "Error: uncaught exception: Permission\n            * denied to get property HTMLDivElement.parentNode" if a TextBox is\n            * placed into the chart x axis label and you mouse over that textbox\n            * (as reported by secnoc in issue #24, which has additional useful info\n            * about the likely cause of this problem; TestGChart44.java reproduces\n            * this behavior if this try/catch is removed).\n            *\n            * Returning True, which will act as if the element is contained in the\n            * GChart, has "cruft possibilities" as in some cases a hoverwidget may\n            * not get closed when user mouses completely out of the GChart, onto a\n            * TextBox, but should otherwise be a lesser evil than False or an\n            * uncaught exception.\n            *\n            ' #NEWLINE# return True #NEWLINE# #UNINDENT# return False