fix: UI issues in the data information view

This commit is contained in:
WerWolv
2023-11-07 00:46:17 +01:00
parent 8581ab9eb3
commit f49b5efac4
2 changed files with 12 additions and 5 deletions

View File

@@ -44,7 +44,12 @@ namespace hex {
}
[[nodiscard]] constexpr u64 getStartAddress() const { return this->address; }
[[nodiscard]] constexpr u64 getEndAddress() const { return this->address + this->size - 1;}
[[nodiscard]] constexpr u64 getEndAddress() const {
if (this->size == 0)
return this->address;
else
return this->address + this->size - 1;
}
[[nodiscard]] constexpr size_t getSize() const { return this->size; }
[[nodiscard]] constexpr bool operator==(const Region &other) const {