I\'m using Selenium Java 2.0b3. I have this code:
...
WebDriver driver = new InternetExplorerDriver();
Selenium seleniumDriver = new WebDriv
I use this code to get a mouseover event for a specific webelement. It does not need native events.
protected void mouseOver(WebElement element) {
String code = "var fireOnThis = arguments[0];"
+ "var evObj = document.createEvent('MouseEvents');"
+ "evObj.initEvent( 'mouseover', true, true );"
+ "fireOnThis.dispatchEvent(evObj);";
((JavascriptExecutor) driver).executeScript(code, element);
}
I would suggest trying the Advanced User Actions API that was added in the 2.0rc1 release yesterday, as it looks like you're using the Selenium 1 API still (going through WebDriverBackedSelenium), and I'm not sure how much Firefox 4 support that provides. I'm not using Java for my Selenium tests, but it looks to me like what you would want to do is something like this:
Actions builder = new Actions(driver); // Or maybe seleniumDriver? Not sure which one to use
Actions hoverOverRegistrar = builder.moveToElement(menuRegistrar);
hoverOverRegistrar.perform();
Actions action = new Actions(driver);
action.moveToElement(element).build().perform();
action.moveByOffset(1, 1).build().perform();