mirror of
https://github.com/zoriya/ComSquare.git
synced 2025-12-21 14:45:10 +00:00
Adding const qualifiers to the IMemory and adding error messages in the memory viewer
This commit is contained in:
@@ -18,13 +18,13 @@ namespace ComSquare::Memory
|
||||
this->setMemoryRegion(startBank, endBank, startPage, endPage);
|
||||
}
|
||||
|
||||
uint24_t RectangleShadow::getRelativeAddress(uint24_t addr)
|
||||
uint24_t RectangleShadow::getRelativeAddress(uint24_t addr) const
|
||||
{
|
||||
uint24_t base = ARectangleMemory::getRelativeAddress(addr);
|
||||
return base + this->_bankOffset * (this->_endPage - this->_startPage);
|
||||
}
|
||||
|
||||
uint8_t RectangleShadow::read(uint24_t addr)
|
||||
uint8_t RectangleShadow::read(uint24_t addr) const
|
||||
{
|
||||
return this->_initial->read(addr);
|
||||
}
|
||||
@@ -40,22 +40,27 @@ namespace ComSquare::Memory
|
||||
return this;
|
||||
}
|
||||
|
||||
bool RectangleShadow::isMirror()
|
||||
uint24_t RectangleShadow::getSize() const
|
||||
{
|
||||
return this->_initial->getSize();
|
||||
}
|
||||
|
||||
bool RectangleShadow::isMirror() const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
std::shared_ptr<IMemory> RectangleShadow::getMirrored()
|
||||
std::shared_ptr<IMemory> RectangleShadow::getMirrored() const
|
||||
{
|
||||
return this->_initial;
|
||||
}
|
||||
|
||||
std::string RectangleShadow::getName()
|
||||
std::string RectangleShadow::getName() const
|
||||
{
|
||||
return this->_initial->getName();
|
||||
}
|
||||
|
||||
Component RectangleShadow::getComponent()
|
||||
Component RectangleShadow::getComponent() const
|
||||
{
|
||||
return this->_initial->getComponent();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user