Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Fix bug: 'ghost' translation and saveAsFuzzy focus issues: https://bu…
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Eng committed Oct 24, 2011
1 parent 76d8193 commit daa2bfa
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 30 deletions.
Expand Up @@ -580,32 +580,6 @@ public void cancelEdit()
clearSelection();
}

public void cancelEdit(boolean closeEditor)
{
// Fire the event
if (!onCancel())
{
return;
}

if (closeEditor)
{
restoreView();
textArea.setFocus(false);
}
isOpened = false;
isFocused = false;

// Call the callback
if (curCallback != null)
{
// curCallback.onCancel(curCellEditInfo);
cancelCallback.onCancel(cellValue);
}

clearSelection();
}

public void clearSelection()
{
curCallback = null;
Expand Down
Expand Up @@ -335,10 +335,8 @@ public void onTransUnitUpdated(TransUnitUpdatedEvent event)
// TODO this test never succeeds
if (selectedTransUnit != null && selectedTransUnit.getId().equals(event.getTransUnit().getId()))
{
// Log.info("selected TU updated; cancelling edit");
// display.getTargetCellEditor().cancelEdit(false);

// TODO reload page and return
Log.info("selected TU updated; clear selection");
display.getTargetCellEditor().cancelEdit();
}

final Integer rowOffset = getRowOffset(event.getTransUnit().getId());
Expand Down Expand Up @@ -386,6 +384,11 @@ public void onTransUnitUpdated(TransUnitUpdatedEvent event)
reloadPage();
}
}

if (selectedTransUnit != null && selectedTransUnit.getId().equals(event.getTransUnit().getId()))
{
tableModelHandler.gotoRow(curRowIndex);
}
}
}
}));
Expand Down

0 comments on commit daa2bfa

Please sign in to comment.