mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-04 10:03:36 +00:00
GLideNUI-wtl: Make sure clearing of selected font on load
This commit is contained in:
parent
1934062d65
commit
bea0403d2c
Binary file not shown.
|
@ -106,14 +106,16 @@ void COsdTab::SelCurrentFont(void)
|
|||
tv.item.cchTextMax = sizeof(Item) / sizeof(Item[0]);
|
||||
tv.item.hItem = m_Fonts.GetChildItem(TVI_ROOT);
|
||||
HTREEITEM hCurrentItem = NULL;
|
||||
while (hCurrentItem == NULL && tv.item.hItem) {
|
||||
while (tv.item.hItem) {
|
||||
m_Fonts.GetItem(&tv.item);
|
||||
HTREEITEM hChild = m_Fonts.GetChildItem(tv.item.hItem);
|
||||
m_Fonts.SetItemState(tv.item.hItem, 0, TVIF_STATE | TVIS_SELECTED);
|
||||
HTREEITEM hChild = m_Fonts.GetChildItem(tv.item.hItem);
|
||||
HTREEITEM NextItem = m_Fonts.GetNextSiblingItem(tv.item.hItem);
|
||||
if (hCurrentItem == NULL && hChild != NULL) {
|
||||
if (hChild != NULL) {
|
||||
tv.item.hItem = hChild;
|
||||
while (hCurrentItem == NULL && tv.item.hItem) {
|
||||
while (tv.item.hItem) {
|
||||
m_Fonts.GetItem(&tv.item);
|
||||
m_Fonts.SetItemState(tv.item.hItem, 0, TVIF_STATE | TVIS_SELECTED);
|
||||
if (Item == CurrentFile)
|
||||
hCurrentItem = tv.item.hItem;
|
||||
tv.item.hItem = m_Fonts.GetNextSiblingItem(tv.item.hItem);
|
||||
|
|
Loading…
Reference in New Issue
Block a user