{"issue":{"user":{"id":401593,"login":"patrickwong929","url":"https://api.github.com/users/patrickwong929","avatar_url":"https://secure.gravatar.com/avatar/ca266fa6266509768c292acc976b7abc?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"ca266fa6266509768c292acc976b7abc"},"title":"How to fire a css hover event","milestone":null,"created_at":"2011-01-05T08:00:27Z","updated_at":"2011-12-16T00:44:39Z","labels":[{"name":"blocked-by-webdriver","url":"https://api.github.com/repos/jarib/watir-webdriver/labels/blocked-by-webdriver","color":"a32d2d"}],"state":"open","id":507573,"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"html_url":"https://github.com/jarib/watir-webdriver/issues/46","closed_at":null,"body":"I tried to use fire a onmouseover event instead it but do not work.","number":46,"url":"https://api.github.com/repos/jarib/watir-webdriver/issues/46","comments":5,"assignee":null},"comment":{"user":{"id":974140,"login":"anonygoose","url":"https://api.github.com/users/anonygoose","avatar_url":"https://secure.gravatar.com/avatar/28e91aeeecefe6d9815d33631570c500?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"28e91aeeecefe6d9815d33631570c500"},"created_at":"2011-12-16T00:44:39Z","updated_at":"2011-12-16T00:44:39Z","id":3171698,"body":"A month or two back I requested help with this on the watir irc channel, and Jarib supplied the following as a temporary workaround:\r\n\r\nclass Watir::Element\r\n def hover\r\n   assert_exists\r\n   driver.action.move_to(@element).perform\r\n end\r\nend\r\n\r\nwhich allows me to call .hover on any element.  It's worked for me so far.  The \"mouse\" will take the most direct route though, so if you need to do a fiddly series of hovers (on say a menu) it'll mess up quite a bit.\r\n\r\nI'm not at work at the moment so I don't have access to the exact code, but I solved that by basically implementing the move_by from web-driver in the same way, and then just moving the \"mouse\" enough so that it didnt accidentally hover over another menu element on its way to the submenu.\r\n\r\nI'll post it tomorrow for anyone interested.","url":"https://api.github.com/repos/jarib/watir-webdriver/issues/comments/3171698"},"action":"created"}