Fix tool tip in document switcher showing the old name issue (after being renamed).

Fix #4910, close #4936
This commit is contained in:
Rajendra Singh 2018-10-19 01:58:06 +05:30 committed by Don HO
parent b9b3faf307
commit 94cf9d53ca

View File

@ -234,14 +234,15 @@ void VerticalFileSwitcherListView::setItemIconStatus(BufferID bufferID)
TaskLstFnStatus *tlfs = (TaskLstFnStatus *)(item.lParam);
if (tlfs->_bufID == bufferID)
{
tlfs->_fn = buf->getFullPathName();
item.mask = LVIF_TEXT | LVIF_IMAGE;
ListView_SetItem(_hSelf, &item);
if (isExtColumn)
{
ListView_SetItemText(_hSelf, i, 1, (LPTSTR)::PathFindExtension(buf->getFileName()));
}
break;
}
}
}
@ -286,7 +287,7 @@ int VerticalFileSwitcherListView::add(BufferID bufferID, int iView)
Buffer *buf = static_cast<Buffer *>(bufferID);
const TCHAR *fileName = buf->getFileName();
TaskLstFnStatus *tl = new TaskLstFnStatus(iView, 0, fileName, 0, (void *)bufferID);
TaskLstFnStatus *tl = new TaskLstFnStatus(iView, 0, buf->getFullPathName(), 0, (void *)bufferID);
TCHAR fn[MAX_PATH];
lstrcpy(fn, ::PathFindFileName(fileName));