Skip to content

Commit

Permalink
cal.gen[row][col][0] return undefined sometimes and makes IE stop
Browse files Browse the repository at this point in the history
  • Loading branch information
tcha-tcho committed Mar 25, 2012
1 parent 32d6dc5 commit 46074b1
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions js/jqm-datebox.mode.calbox.js
Expand Up @@ -204,16 +204,18 @@
$('<div>', {'class':uid+'griddate '+uid+'griddate-empty'}).appendTo(hRow);
} else {
checked = w._cal_check(cal, cal.theDateArr[0], cal.gen[row][col][1], cal.gen[row][col][0]);
$("<div>"+String(cal.gen[row][col][0])+"</div>")
.addClass( cal.thisMonth === cal.gen[row][col][1] ?
(uid+'griddate ui-corner-all ui-btn-up-'+checked.theme + (checked.ok?'':' '+uid+'griddate-disable')):
(uid+'griddate '+uid+'griddate-empty')
)
.jqmData('date', ((o.calWeekMode)?cal.weekMode:cal.gen[row][col][0]))
.jqmData('theme', cal.thisMonth === cal.gen[row][col][1] ? checked.theme : '-')
.jqmData('enabled', checked.ok)
.jqmData('month', cal.gen[row][col][1])
.appendTo(hRow);
if (cal.gen[row][col][0]) {
$("<div>"+String(cal.gen[row][col][0])+"</div>")
.addClass( cal.thisMonth === cal.gen[row][col][1] ?
(uid+'griddate ui-corner-all ui-btn-up-'+checked.theme + (checked.ok?'':' '+uid+'griddate-disable')):
(uid+'griddate '+uid+'griddate-empty')
)
.jqmData('date', ((o.calWeekMode)?cal.weekMode:cal.gen[row][col][0]))
.jqmData('theme', cal.thisMonth === cal.gen[row][col][1] ? checked.theme : '-')
.jqmData('enabled', checked.ok)
.jqmData('month', cal.gen[row][col][1])
.appendTo(hRow);
}
}
}
if ( o.calControlGroup === true ) {
Expand Down

0 comments on commit 46074b1

Please sign in to comment.