Fixes #251, UI refresh problem with page snapshot
Also fixes snapshot add breakage when another tab is selected caused by blur() fix from other day
This commit is contained in:
parent
ea72af8be8
commit
eba2974ce1
2 changed files with 5 additions and 1 deletions
|
@ -108,7 +108,7 @@ var ScholarItemPane = new function()
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (boxes.length==1)
|
if (boxes && boxes.length==1)
|
||||||
{
|
{
|
||||||
boxes[0].inputField.blur();
|
boxes[0].inputField.blur();
|
||||||
}
|
}
|
||||||
|
|
|
@ -176,6 +176,10 @@ Scholar.ItemTreeView.prototype.notify = function(action, type, ids)
|
||||||
if(action == 'add')
|
if(action == 'add')
|
||||||
{
|
{
|
||||||
if (ids.length===1){
|
if (ids.length===1){
|
||||||
|
// Reset to Info tab
|
||||||
|
this._treebox.treeBody.ownerDocument.
|
||||||
|
getElementById('scholar-view-tabs').selectedIndex = 0;
|
||||||
|
|
||||||
this.selectItem(ids[0]);
|
this.selectItem(ids[0]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue