Mercurial > hg > easyhg
diff src/historywidget.cpp @ 371:f051d210521e
Ensure current item is visible in graph after update
author | Chris Cannam |
---|---|
date | Thu, 24 Mar 2011 10:47:03 +0000 |
parents | b9c153e00e84 |
children | 61bde1f0ff0a |
line wrap: on
line diff
--- a/src/historywidget.cpp Thu Mar 24 10:27:51 2011 +0000 +++ b/src/historywidget.cpp Thu Mar 24 10:47:03 2011 +0000 @@ -184,7 +184,11 @@ } toFocus = g.getUncommittedItem(); if (!toFocus) { - toFocus = g.getItemFor(m_changesets[0]); + if (!m_currentIds.empty()) { + toFocus = g.getItemFor(m_currentIds[0]); + } else { + toFocus = g.getItemFor(m_changesets[0]); + } } }