COMMON: Remove hasDataFork and getDataFork
This commit is contained in:
parent
ae9de1acbc
commit
382913b51d
2 changed files with 0 additions and 34 deletions
|
@ -135,10 +135,6 @@ void MacResManager::close() {
|
||||||
_resMap.numTypes = 0;
|
_resMap.numTypes = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool MacResManager::hasDataFork() const {
|
|
||||||
return !_baseFileName.empty();
|
|
||||||
}
|
|
||||||
|
|
||||||
bool MacResManager::hasResFork() const {
|
bool MacResManager::hasResFork() const {
|
||||||
return !_baseFileName.empty() && _mode != kResForkNone && _resForkSize != 0;
|
return !_baseFileName.empty() && _mode != kResForkNone && _resForkSize != 0;
|
||||||
}
|
}
|
||||||
|
@ -685,24 +681,6 @@ bool MacResManager::load(SeekableReadStream *stream) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
SeekableReadStream *MacResManager::getDataFork() {
|
|
||||||
if (!_stream)
|
|
||||||
return nullptr;
|
|
||||||
|
|
||||||
if (_mode == kResForkMacBinary) {
|
|
||||||
_stream->seek(MBI_DFLEN);
|
|
||||||
uint32 dataSize = _stream->readUint32BE();
|
|
||||||
return new SafeSeekableSubReadStream(_stream, MBI_INFOHDR, MBI_INFOHDR + dataSize);
|
|
||||||
}
|
|
||||||
|
|
||||||
File *file = new File();
|
|
||||||
if (file->open(_baseFileName))
|
|
||||||
return file;
|
|
||||||
delete file;
|
|
||||||
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
|
|
||||||
MacResIDArray MacResManager::getResIDArray(uint32 typeID) {
|
MacResIDArray MacResManager::getResIDArray(uint32 typeID) {
|
||||||
int typeNum = -1;
|
int typeNum = -1;
|
||||||
MacResIDArray res;
|
MacResIDArray res;
|
||||||
|
|
|
@ -194,12 +194,6 @@ public:
|
||||||
*/
|
*/
|
||||||
void close();
|
void close();
|
||||||
|
|
||||||
/**
|
|
||||||
* Query whether or not we have a data fork present.
|
|
||||||
* @return True if the data fork is present
|
|
||||||
*/
|
|
||||||
bool hasDataFork() const;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Query whether or not we have a data fork present.
|
* Query whether or not we have a data fork present.
|
||||||
* @return True if the resource fork is present
|
* @return True if the resource fork is present
|
||||||
|
@ -230,12 +224,6 @@ public:
|
||||||
*/
|
*/
|
||||||
SeekableReadStream *getResource(uint32 typeID, const String &filename);
|
SeekableReadStream *getResource(uint32 typeID, const String &filename);
|
||||||
|
|
||||||
/**
|
|
||||||
* Retrieve the data fork
|
|
||||||
* @return The stream if present, 0 otherwise
|
|
||||||
*/
|
|
||||||
SeekableReadStream *getDataFork();
|
|
||||||
|
|
||||||
static int getDataForkOffset() { return MBI_INFOHDR; }
|
static int getDataForkOffset() { return MBI_INFOHDR; }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue