Skip to content

Commit

Permalink
fix: Pattern data view rendering of bitfields within bitfields being …
Browse files Browse the repository at this point in the history
…broken
  • Loading branch information
WerWolv committed May 7, 2024
1 parent 10351c5 commit a5eb031
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions plugins/ui/source/ui/pattern_drawer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,11 +135,12 @@ namespace hex::ui {
}

void drawSizeColumn(const pl::ptrn::Pattern& pattern) {
ImGui::TableNextColumn();
if (auto *bitfieldMember = dynamic_cast<const pl::ptrn::PatternBitfieldMember*>(&pattern); bitfieldMember != nullptr && bitfieldMember->getParentBitfield() != nullptr)
drawSizeColumnForBitfieldMember(*bitfieldMember);
else
else {
ImGui::TableNextColumn();
ImGuiExt::TextFormatted("0x{0:04X}", pattern.getSize());
}
}

void drawCommentTooltip(const pl::ptrn::Pattern &pattern) {
Expand Down

0 comments on commit a5eb031

Please sign in to comment.