diff options
-rw-r--r-- | engines/wintermute/Base/BFileManager.cpp | 4 | ||||
-rw-r--r-- | engines/wintermute/Base/BPackage.cpp | 8 | ||||
-rw-r--r-- | engines/wintermute/Base/BPackage.h | 6 | ||||
-rw-r--r-- | engines/wintermute/Base/file/BFile.cpp | 8 | ||||
-rw-r--r-- | engines/wintermute/Base/file/BFile.h | 10 | ||||
-rw-r--r-- | engines/wintermute/Base/file/BSaveThumbFile.cpp | 12 | ||||
-rw-r--r-- | engines/wintermute/Base/file/BSaveThumbFile.h | 8 | ||||
-rw-r--r-- | engines/wintermute/UI/UIWindow.cpp | 12 | ||||
-rw-r--r-- | engines/wintermute/UI/UIWindow.h | 2 |
9 files changed, 35 insertions, 35 deletions
diff --git a/engines/wintermute/Base/BFileManager.cpp b/engines/wintermute/Base/BFileManager.cpp index 397d314c3a..448c1d684f 100644 --- a/engines/wintermute/Base/BFileManager.cpp +++ b/engines/wintermute/Base/BFileManager.cpp @@ -231,7 +231,7 @@ HRESULT CBFileManager::SaveFile(const Common::String &Filename, byte *Buffer, ui HRESULT CBFileManager::RequestCD(int CD, char *PackageFile, char *Filename) {
// unmount all non-local packages
for (int i = 0; i < _packages.GetSize(); i++) {
- if (_packages[i]->_cD > 0) _packages[i]->Close();
+ if (_packages[i]->_cD > 0) _packages[i]->close();
}
@@ -805,7 +805,7 @@ Common::SeekableReadStream *CBFileManager::OpenFileRaw(const Common::String &Fil if (scumm_strnicmp(Filename.c_str(), "savegame:", 9) == 0) {
CBSaveThumbFile *SaveThumbFile = new CBSaveThumbFile(Game);
- if (SUCCEEDED(SaveThumbFile->Open(Filename))) return SaveThumbFile->getMemStream();
+ if (SUCCEEDED(SaveThumbFile->open(Filename))) return SaveThumbFile->getMemStream();
else {
delete SaveThumbFile;
return NULL;
diff --git a/engines/wintermute/Base/BPackage.cpp b/engines/wintermute/Base/BPackage.cpp index 976e9b3344..9f68bfa2d0 100644 --- a/engines/wintermute/Base/BPackage.cpp +++ b/engines/wintermute/Base/BPackage.cpp @@ -57,7 +57,7 @@ CBPackage::~CBPackage() { //////////////////////////////////////////////////////////////////////////
-HRESULT CBPackage::Open() {
+HRESULT CBPackage::open() {
if (_file) return S_OK;
else {
_file = GetFilePointer();
@@ -67,7 +67,7 @@ HRESULT CBPackage::Open() { //////////////////////////////////////////////////////////////////////////
-HRESULT CBPackage::Close() {
+HRESULT CBPackage::close() {
delete _file;
_file = NULL;
return S_OK;
@@ -75,9 +75,9 @@ HRESULT CBPackage::Close() { //////////////////////////////////////////////////////////////////////////
-HRESULT CBPackage::Read(Common::SeekableReadStream *file, uint32 offset, byte *buffer, uint32 size) {
+HRESULT CBPackage::read(Common::SeekableReadStream *file, uint32 offset, byte *buffer, uint32 size) {
HRESULT ret;
- if (FAILED(ret = Open())) return ret;
+ if (FAILED(ret = open())) return ret;
else {
if (file->seek(offset, SEEK_SET)) return E_FAIL;
if (file->read(buffer, size) != 1) return E_FAIL;
diff --git a/engines/wintermute/Base/BPackage.h b/engines/wintermute/Base/BPackage.h index 80d8e481f2..7b4e8a4d6c 100644 --- a/engines/wintermute/Base/BPackage.h +++ b/engines/wintermute/Base/BPackage.h @@ -45,9 +45,9 @@ public: bool _boundToExe;
byte _priority;
- HRESULT Read(Common::SeekableReadStream *file, uint32 offset, byte *buffer, uint32 size);
- HRESULT Close();
- HRESULT Open();
+ HRESULT read(Common::SeekableReadStream *file, uint32 offset, byte *buffer, uint32 size);
+ HRESULT close();
+ HRESULT open();
char *_name;
int _cD;
Common::SeekableReadStream *_file;
diff --git a/engines/wintermute/Base/file/BFile.cpp b/engines/wintermute/Base/file/BFile.cpp index 6fa7cb84d6..9da60a11ec 100644 --- a/engines/wintermute/Base/file/BFile.cpp +++ b/engines/wintermute/Base/file/BFile.cpp @@ -51,16 +51,16 @@ CBFile::~CBFile() { //////////////////////////////////////////////////////////////////////////
-bool CBFile::IsEOF() {
+bool CBFile::isEOF() {
return _pos == _size;
}
Common::SeekableReadStream *CBFile::getMemStream() {
uint32 oldPos = getPos();
- Seek(0);
+ seek(0);
byte *data = new byte[getSize()];
- Read(data, getSize());
- Seek(oldPos);
+ read(data, getSize());
+ seek(oldPos);
Common::MemoryReadStream *memStream = new Common::MemoryReadStream(data, getSize(), DisposeAfterUse::YES);
return memStream;
}
diff --git a/engines/wintermute/Base/file/BFile.h b/engines/wintermute/Base/file/BFile.h index caeac3e14b..16b51a50fc 100644 --- a/engines/wintermute/Base/file/BFile.h +++ b/engines/wintermute/Base/file/BFile.h @@ -51,11 +51,11 @@ public: virtual uint32 getPos() {
return _pos;
};
- virtual HRESULT Seek(uint32 pos, TSeek origin = SEEK_TO_BEGIN) = 0;
- virtual HRESULT Read(void *buffer, uint32 size) = 0;
- virtual HRESULT Close() = 0;
- virtual HRESULT Open(const Common::String &filename) = 0;
- virtual bool IsEOF();
+ virtual HRESULT seek(uint32 pos, TSeek origin = SEEK_TO_BEGIN) = 0;
+ virtual HRESULT read(void *buffer, uint32 size) = 0;
+ virtual HRESULT close() = 0;
+ virtual HRESULT open(const Common::String &filename) = 0;
+ virtual bool isEOF();
CBFile(CBGame *inGame);
virtual ~CBFile();
// Temporary solution to allow usage in ScummVM-code:
diff --git a/engines/wintermute/Base/file/BSaveThumbFile.cpp b/engines/wintermute/Base/file/BSaveThumbFile.cpp index 5f5278199b..5f70f7636f 100644 --- a/engines/wintermute/Base/file/BSaveThumbFile.cpp +++ b/engines/wintermute/Base/file/BSaveThumbFile.cpp @@ -46,13 +46,13 @@ CBSaveThumbFile::CBSaveThumbFile(CBGame *inGame): CBFile(inGame) { //////////////////////////////////////////////////////////////////////////
CBSaveThumbFile::~CBSaveThumbFile() {
- Close();
+ close();
}
//////////////////////////////////////////////////////////////////////////
-HRESULT CBSaveThumbFile::Open(const Common::String &filename) {
- Close();
+HRESULT CBSaveThumbFile::open(const Common::String &filename) {
+ close();
if (scumm_strnicmp(filename.c_str(), "savegame:", 9) != 0) return E_FAIL;
@@ -97,7 +97,7 @@ HRESULT CBSaveThumbFile::Open(const Common::String &filename) { //////////////////////////////////////////////////////////////////////////
-HRESULT CBSaveThumbFile::Close() {
+HRESULT CBSaveThumbFile::close() {
delete[] _data;
_data = NULL;
@@ -109,7 +109,7 @@ HRESULT CBSaveThumbFile::Close() { //////////////////////////////////////////////////////////////////////////
-HRESULT CBSaveThumbFile::Read(void *buffer, uint32 size) {
+HRESULT CBSaveThumbFile::read(void *buffer, uint32 size) {
if (!_data || _pos + size > _size) return E_FAIL;
memcpy(buffer, (byte *)_data + _pos, size);
@@ -120,7 +120,7 @@ HRESULT CBSaveThumbFile::Read(void *buffer, uint32 size) { //////////////////////////////////////////////////////////////////////////
-HRESULT CBSaveThumbFile::Seek(uint32 pos, TSeek origin) {
+HRESULT CBSaveThumbFile::seek(uint32 pos, TSeek origin) {
if (!_data) return E_FAIL;
uint32 newPos = 0;
diff --git a/engines/wintermute/Base/file/BSaveThumbFile.h b/engines/wintermute/Base/file/BSaveThumbFile.h index 78626eeff4..280a5a1447 100644 --- a/engines/wintermute/Base/file/BSaveThumbFile.h +++ b/engines/wintermute/Base/file/BSaveThumbFile.h @@ -39,10 +39,10 @@ class CBSaveThumbFile : public CBFile { public:
CBSaveThumbFile(CBGame *Game);
virtual ~CBSaveThumbFile();
- virtual HRESULT Seek(uint32 Pos, TSeek Origin = SEEK_TO_BEGIN);
- virtual HRESULT Read(void *Buffer, uint32 Size);
- virtual HRESULT Close();
- virtual HRESULT Open(const Common::String &Filename);
+ virtual HRESULT seek(uint32 Pos, TSeek Origin = SEEK_TO_BEGIN);
+ virtual HRESULT read(void *Buffer, uint32 Size);
+ virtual HRESULT close();
+ virtual HRESULT open(const Common::String &Filename);
private:
byte *_data;
};
diff --git a/engines/wintermute/UI/UIWindow.cpp b/engines/wintermute/UI/UIWindow.cpp index 8b6ed746af..1998b380cd 100644 --- a/engines/wintermute/UI/UIWindow.cpp +++ b/engines/wintermute/UI/UIWindow.cpp @@ -89,7 +89,7 @@ CUIWindow::CUIWindow(CBGame *inGame): CUIObject(inGame) { //////////////////////////////////////////////////////////////////////////
CUIWindow::~CUIWindow() {
- Close();
+ close();
cleanup();
}
@@ -773,7 +773,7 @@ HRESULT CUIWindow::scCallMethod(CScScript *Script, CScStack *Stack, CScStack *Th //////////////////////////////////////////////////////////////////////////
else if (strcmp(Name, "Close") == 0) {
Stack->CorrectParams(0);
- Stack->PushBool(SUCCEEDED(Close()));
+ Stack->PushBool(SUCCEEDED(close()));
return S_OK;
}
@@ -1070,7 +1070,7 @@ HRESULT CUIWindow::scSetProperty(const char *Name, CScValue *Value) { if (Value->GetBool())
GoExclusive();
else {
- Close();
+ close();
_visible = true;
}
return S_OK;
@@ -1083,7 +1083,7 @@ HRESULT CUIWindow::scSetProperty(const char *Name, CScValue *Value) { if (Value->GetBool())
GoSystemExclusive();
else {
- Close();
+ close();
_visible = true;
}
return S_OK;
@@ -1254,7 +1254,7 @@ HRESULT CUIWindow::GoSystemExclusive() { //////////////////////////////////////////////////////////////////////////
-HRESULT CUIWindow::Close() {
+HRESULT CUIWindow::close() {
if (_mode == WINDOW_SYSTEM_EXCLUSIVE) {
Game->Unfreeze();
}
@@ -1273,7 +1273,7 @@ HRESULT CUIWindow::listen(CBScriptHolder *param1, uint32 param2) { switch (obj->_type) {
case UI_BUTTON:
- if (scumm_stricmp(obj->_name, "close") == 0) Close();
+ if (scumm_stricmp(obj->_name, "close") == 0) close();
else return CBObject::listen(param1, param2);
break;
default:
diff --git a/engines/wintermute/UI/UIWindow.h b/engines/wintermute/UI/UIWindow.h index ed81ef9d06..adc2a89d21 100644 --- a/engines/wintermute/UI/UIWindow.h +++ b/engines/wintermute/UI/UIWindow.h @@ -53,7 +53,7 @@ public: virtual bool handleMouseWheel(int Delta);
CUIWindow *_shieldWindow;
CUIButton *_shieldButton;
- HRESULT Close();
+ HRESULT close();
HRESULT GoSystemExclusive();
HRESULT GoExclusive();
TWindowMode _mode;
|