在播放器中加播放文件时,怎么使播放列表中新加入的文件获得焦点被选中。
case WM_SETFOCUS:
int i=listbox.GetCount();
this->listbox.SetFocus();
listbox.SetCurSel(i-1);
这些代码只能使新加入文件的上一个文件被选中
case WM_SETFOCUS:
int i=listbox.GetCount();
this->listbox.SetFocus();
listbox.SetCurSel(i-1);
这些代码只能使新加入文件的上一个文件被选中
CListBox::SetCurSel(nIndex);int nIndex = CListBox::InsertString();
CListBox::SetCurSel(nIndex);