void FileIO::Close() { if (mOutputStream) { delete mOutputStream; mOutputStream = NULL; } if (mInputStream) { delete mInputStream; mInputStream = NULL; } SetCatalogInfo(); mOpen = false; }
void FileIO::SetCatalogInfo() { #ifdef __WXMAC__ if (!mOpen || mFtp != NULL) { return; } wxUint32 type; wxFileName fn(mName); wxString ext = fn.GetExt().MakeUpper() + wxT(" "); type = (ext[0] & 0xff) << 24 | (ext[1] & 0xff) << 16 | (ext[2] & 0xff) << 8 | (ext[3] & 0xff); SetCatalogInfo(type); #endif return; }
void FileIO::SetCatalogInfo() { #ifdef __WXMAC__ #if !wxCHECK_VERSION(3, 0, 0) if (!mOpen ) { return; } wxUint32 type; wxFileName fn(mName); wxString ext = fn.GetExt().MakeUpper() + wxT(" "); type = (ext[0] & 0xff) << 24 | (ext[1] & 0xff) << 16 | (ext[2] & 0xff) << 8 | (ext[3] & 0xff); SetCatalogInfo(type); #endif #endif return; }