/**
* Checks if the cursor property on the input element is set to auto
*/
public static boolean isAutoCursor(Element e) {
Value cursorValue =
CSSUtilities.getComputedStyle(e,
SVGCSSEngine.CURSOR_INDEX);
boolean isAuto = false;
if (cursorValue != null){
if(
cursorValue.getCssValueType() == CSSValue.CSS_PRIMITIVE_VALUE
&&
cursorValue.getPrimitiveType() == CSSPrimitiveValue.CSS_IDENT
&&
cursorValue.getStringValue().charAt(0) == 'a'
) {
isAuto = true;
} else if (
cursorValue.getCssValueType() == CSSValue.CSS_VALUE_LIST
&&
cursorValue.getLength() == 1) {
Value lValue = cursorValue.item(0);
if (lValue != null
&&
lValue.getCssValueType() == CSSValue.CSS_PRIMITIVE_VALUE
&&
lValue.getPrimitiveType() == CSSPrimitiveValue.CSS_IDENT
&&
lValue.getStringValue().charAt(0) == 'a') {
isAuto = true;
}
}
}