merged bugfix from 0.1.1

This commit is contained in:
Morgan McMillian 2012-03-11 23:25:55 -04:00
parent b80225dc27
commit 027ef2833e
2 changed files with 13 additions and 1 deletions

View file

@ -16,6 +16,10 @@
appInstance.renderInto(document.body);
</script>
<div id="history" style="display: none">
<div class="version">0.1.1</div>
<ul>
<li>Bugfix: race condition when deleting certain entries.</li>
</ul>
<div class="version">0.1.0</div>
<ul>
<li>Initial open source and beta release.</li>

View file

@ -188,7 +188,15 @@ enyo.kind({
todoTap: function(inSender, inEvent) {
this.selectedIndex = inEvent.rowIndex;
if (this.selectedIndex != undefined) {
this.selectedId = this.sortedList[this.selectedIndex].num-1;
//this.selectedId = this.sortedList[this.selectedIndex].num-1;
var num = this.sortedList[this.selectedIndex].num;
function getIdx(list, num) {
for (var i=0; i<list.length; i++) {
if (list[i].num == num)
return i;
}
}
this.selectedId = getIdx(this.owner.todoList,num);
}
var r = this.sortedList[inEvent.rowIndex];