var contents = $('#sample');
contents
.on('keyup', 'input', function(e){ // input での keyup 時の例
var my = $(this),
c = e.which ? e.which : e.keyCode;
switch(c){
case 13: // [Enter]
var obj = contents.find("input"), // ... 移動対象のオブジェクト全体
no = obj.index(my), // ............. 現在の順番
nxt;
do {
no++; // ........................... 次のオブジェクトの順番
if( no > obj.length ) no = 0; // ... 次のオブジェクトが無い場合、先頭
nxt = obj.eq(no); // ............... 次の移動対象
} while( nxt.is(':visible')===false || nxt.attr('tabindex')==='-1' );
nxt.focus();
break;
}
}
)