MCPcopy Create free account
hub / github.com/NtQuery/Scylla / loadTreeActionHandler

Method loadTreeActionHandler

Scylla/MainGui.cpp:763–796  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

761}
762
763void MainGui::loadTreeActionHandler()
764{
765 if(!selectedProcess)
766 return;
767
768 WCHAR selectedFilePath[MAX_PATH];
769 getCurrentModulePath(stringBuffer, _countof(stringBuffer));
770 if(showFileDialog(selectedFilePath, false, NULL, filterXml, NULL, stringBuffer))
771 {
772 TreeImportExport treeIO(selectedFilePath);
773 DWORD_PTR addrOEP = 0;
774 DWORD_PTR addrIAT = 0;
775 DWORD sizeIAT = 0;
776
777 if(!treeIO.importTreeList(importsHandling.moduleList, &addrOEP, &addrIAT, &sizeIAT))
778 {
779 Scylla::windowLog.log(L"Loading tree file failed %s", selectedFilePath);
780 MessageBox(L"Loading tree file failed.", L"Failure", MB_ICONERROR);
781 }
782 else
783 {
784 EditOEPAddress.SetValue(addrOEP);
785 EditIATAddress.SetValue(addrIAT);
786 EditIATSize.SetValue(sizeIAT);
787
788 importsHandling.displayAllImports();
789 updateStatusBar();
790
791 Scylla::windowLog.log(L"Loaded tree file %s", selectedFilePath);
792 Scylla::windowLog.log(L"-> OEP: " PRINTF_DWORD_PTR_FULL, addrOEP);
793 Scylla::windowLog.log(L"-> IAT: " PRINTF_DWORD_PTR_FULL L" Size: " PRINTF_DWORD_PTR, addrIAT, sizeIAT);
794 }
795 }
796}
797
798void MainGui::saveTreeActionHandler()
799{

Callers

nothing calls this directly

Calls 3

importTreeListMethod · 0.80
logMethod · 0.80
displayAllImportsMethod · 0.80

Tested by

no test coverage detected