using the scrollbar was throwing an exception when checking for a selections because the div does not have focus. Now tests for focus before checking for a selection.