diff options
author | tetsuo55 <tetsuo55@users.sourceforge.net> | 2010-04-09 01:14:58 +0400 |
---|---|---|
committer | tetsuo55 <tetsuo55@users.sourceforge.net> | 2010-04-09 01:14:58 +0400 |
commit | a9b7bf3fb3e1334d8defd05ca4cfae870b4912e5 (patch) | |
tree | 2dab453d94d5e003379a6cc895eceb84c80e23ec /src/filters/BaseClasses/pstream.h | |
parent | aafd49a91f7c2fa9c7103971c16fa6e1b29e8bfd (diff) |
astyle formatting cleanup to make the sourcecode more accessible
switch used: astyle --style=ansi --min-conditional-indent=0 --pad=oper --unpad=paren
http://astyle.sourceforge.net/
git-svn-id: https://mpc-hc.svn.sourceforge.net/svnroot/mpc-hc/trunk@1783 10f7b99b-c216-0410-bff0-8a66a9350fd8
Diffstat (limited to 'src/filters/BaseClasses/pstream.h')
-rw-r--r-- | src/filters/BaseClasses/pstream.h | 89 |
1 files changed, 52 insertions, 37 deletions
diff --git a/src/filters/BaseClasses/pstream.h b/src/filters/BaseClasses/pstream.h index 04b6af624..5fca1b88d 100644 --- a/src/filters/BaseClasses/pstream.h +++ b/src/filters/BaseClasses/pstream.h @@ -44,60 +44,75 @@ // Implements IPersistStream.
// See 'OLE Programmers Reference (Vol 1):Structured Storage Overview' for
// more implementation information.
-class CPersistStream : public IPersistStream {
- private:
+class CPersistStream : public IPersistStream
+{
+private:
- // Internal state:
+ // Internal state:
- protected:
- DWORD mPS_dwFileVersion; // version number of file (being read)
- BOOL mPS_fDirty;
+protected:
+ DWORD mPS_dwFileVersion; // version number of file (being read)
+ BOOL mPS_fDirty;
- public:
+public:
- // IPersistStream methods
+ // IPersistStream methods
- STDMETHODIMP IsDirty()
- {return (mPS_fDirty ? S_OK : S_FALSE);} // note FALSE means clean
- STDMETHODIMP Load(LPSTREAM pStm);
- STDMETHODIMP Save(LPSTREAM pStm, BOOL fClearDirty);
- STDMETHODIMP GetSizeMax(__out ULARGE_INTEGER * pcbSize)
- // Allow 24 bytes for version.
- { pcbSize->QuadPart = 12*sizeof(WCHAR)+SizeMax(); return NOERROR; }
+ STDMETHODIMP IsDirty()
+ {
+ return (mPS_fDirty ? S_OK : S_FALSE); // note FALSE means clean
+ }
+ STDMETHODIMP Load(LPSTREAM pStm);
+ STDMETHODIMP Save(LPSTREAM pStm, BOOL fClearDirty);
+ STDMETHODIMP GetSizeMax(__out ULARGE_INTEGER * pcbSize)
+ // Allow 24 bytes for version.
+ {
+ pcbSize->QuadPart = 12 * sizeof(WCHAR) + SizeMax();
+ return NOERROR;
+ }
- // implementation
+ // implementation
- CPersistStream(IUnknown *punk, __inout HRESULT *phr);
- ~CPersistStream();
+ CPersistStream(IUnknown *punk, __inout HRESULT *phr);
+ ~CPersistStream();
- HRESULT SetDirty(BOOL fDirty)
- { mPS_fDirty = fDirty; return NOERROR;}
+ HRESULT SetDirty(BOOL fDirty)
+ {
+ mPS_fDirty = fDirty;
+ return NOERROR;
+ }
- // override to reveal IPersist & IPersistStream
- // STDMETHODIMP NonDelegatingQueryInterface(REFIID riid, void **ppv);
+ // override to reveal IPersist & IPersistStream
+ // STDMETHODIMP NonDelegatingQueryInterface(REFIID riid, void **ppv);
- // --- IPersist ---
+ // --- IPersist ---
- // You must override this to provide your own class id
- STDMETHODIMP GetClassID(__out CLSID *pClsid) PURE;
+ // You must override this to provide your own class id
+ STDMETHODIMP GetClassID(__out CLSID *pClsid) PURE;
- // overrideable if you want
- // file version number. Override it if you ever change format
- virtual DWORD GetSoftwareVersion(void) { return 0; }
+ // overrideable if you want
+ // file version number. Override it if you ever change format
+ virtual DWORD GetSoftwareVersion(void)
+ {
+ return 0;
+ }
- //=========================================================================
- // OVERRIDE THESE to read and write your data
- // OVERRIDE THESE to read and write your data
- // OVERRIDE THESE to read and write your data
+ //=========================================================================
+ // OVERRIDE THESE to read and write your data
+ // OVERRIDE THESE to read and write your data
+ // OVERRIDE THESE to read and write your data
- virtual int SizeMax() {return 0;}
- virtual HRESULT WriteToStream(IStream *pStream);
- virtual HRESULT ReadFromStream(IStream *pStream);
- //=========================================================================
+ virtual int SizeMax()
+ {
+ return 0;
+ }
+ virtual HRESULT WriteToStream(IStream *pStream);
+ virtual HRESULT ReadFromStream(IStream *pStream);
+ //=========================================================================
- private:
+private:
};
|