Gallery: fix navigation in IE9