Replace setTimeout with requestAnimationFrame

Safia Abdalla 10 years ago
parent 39e155e697
commit 57360754b4

@ -122,9 +122,9 @@ define(function(require){
*/
var onResult = function(node, query, result, resultCount) {
if (resultCount == 1) {
setTimeout(function() {
window.requestAnimationFrame(function() {
$('.typeahead-list > li:nth-child(2)').addClass('active');
}, 0);
});
}
};

Loading…
Cancel
Save