Changeset 107637 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Jan 10, 2025 12:32:20 PM (4 weeks ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.cpp
r106467 r107637 1068 1068 void UIVisoContentBrowser::updateStartItemName() 1069 1069 { 1070 if (!rootItem() || !rootItem()->child(0)) 1070 UIFileSystemItem *pRoot = rootItem(); 1071 if (!pRoot) 1072 return; 1073 UIFileSystemItem *pChild = pRoot->child(0); 1074 if (!pChild) 1071 1075 return; 1072 1076 const QString strName(QDir::toNativeSeparators("/")); 1073 1077 1074 rootItem()->child(0)->setData(strName, UIFileSystemModelData_Name);1078 pChild->setData(strName, UIFileSystemModelData_Name); 1075 1079 /* If the table root index is the start item then we have to update the location selector text here: */ 1076 // if (m_pProxyModel->mapToSource(m_pTableView->rootIndex()).internalPointer() == rootItem()->child(0))1080 // if (m_pProxyModel->mapToSource(m_pTableView->rootIndex()).internalPointer() == pChild) 1077 1081 // updateLocationSelectorText(strName); 1078 1082 m_pProxyModel->invalidate(); … … 1138 1142 void UIVisoContentBrowser::sltResetAction() 1139 1143 { 1140 if (!rootItem() || !rootItem()->child(0)) 1144 UIFileSystemItem *pRoot = rootItem(); 1145 if (!pRoot) 1146 return; 1147 UIFileSystemItem *pChild = pRoot->child(0); 1148 if (!pChild) 1141 1149 return; 1142 1150 goToStart(); 1143 rootItem()->child(0)->removeChildren();1151 pChild->removeChildren(); 1144 1152 m_entryMap.clear(); 1145 1153 if (m_pProxyModel)
Note:
See TracChangeset
for help on using the changeset viewer.