Play-/tools/ElfView/ElfViewEx.cpp

17 lines
535 B
C++
Raw Permalink Normal View History

2022-03-16 16:53:43 -04:00
#include "ElfViewEx.h"
#include "StdStreamUtils.h"
#include "ElfFile.h"
template <typename ElfType>
CElfViewEx<ElfType>::CElfViewEx(QMdiArea* mdiArea, const fs::path& elfPath)
2022-07-25 11:19:56 -04:00
: CELFView<ElfType>(mdiArea)
2022-03-16 16:53:43 -04:00
{
2022-07-25 11:19:56 -04:00
CELFView<ElfType>::setWindowTitle(QString::fromStdString(elfPath.filename().string()));
2022-03-16 16:53:43 -04:00
auto stream = Framework::CreateInputStdStream(elfPath.native());
m_elf = std::make_unique<CElfFile<ElfType>>(stream);
2022-07-25 11:19:56 -04:00
CELFView<ElfType>::SetELF(m_elf.get());
2022-03-16 16:53:43 -04:00
}
template class CElfViewEx<CELF32>;
template class CElfViewEx<CELF64>;