fixing select issue for rtl

There is an issue that the window get "thrown" to the left side (because of a bad rtl check).
here is a fix for it.