Kaydet (Commit) 52a949e5 authored tarafından Noel Grandin's avatar Noel Grandin

convert Link<> to typed

Change-Id: Ia8dd531759ab4d609d1c3eeb31283612c0d70219
üst 240d1f28
...@@ -895,7 +895,7 @@ OUString Storage::GetUserName() ...@@ -895,7 +895,7 @@ OUString Storage::GetUserName()
bool Storage::ValidateFAT() bool Storage::ValidateFAT()
{ {
Link<> aLink = StgIo::GetErrorLink(); Link<StgLinkArg&,void> aLink = StgIo::GetErrorLink();
ErrCode nErr = pIo->ValidateFATs(); ErrCode nErr = pIo->ValidateFATs();
StgIo::SetErrorLink( aLink ); StgIo::SetErrorLink( aLink );
return nErr == ERRCODE_NONE; return nErr == ERRCODE_NONE;
......
...@@ -336,14 +336,14 @@ sal_uLong Validator::FindUnrefedChains() ...@@ -336,14 +336,14 @@ sal_uLong Validator::FindUnrefedChains()
return FAT_OK; return FAT_OK;
} }
namespace { struct ErrorLink : public rtl::Static<Link<>, ErrorLink > {}; } namespace { struct ErrorLink : public rtl::Static<Link<StgLinkArg&,void>, ErrorLink > {}; }
void StgIo::SetErrorLink( const Link<>& rLink ) void StgIo::SetErrorLink( const Link<StgLinkArg&,void>& rLink )
{ {
ErrorLink::get() = rLink; ErrorLink::get() = rLink;
} }
const Link<>& StgIo::GetErrorLink() const Link<StgLinkArg&,void>& StgIo::GetErrorLink()
{ {
return ErrorLink::get(); return ErrorLink::get();
} }
...@@ -379,7 +379,7 @@ sal_uLong StgIo::ValidateFATs() ...@@ -379,7 +379,7 @@ sal_uLong StgIo::ValidateFATs()
StgLinkArg aArg; StgLinkArg aArg;
aArg.aFile = pFileStrm->GetFileName(); aArg.aFile = pFileStrm->GetFileName();
aArg.nErr = nErr; aArg.nErr = nErr;
ErrorLink::get().Call( &aArg ); ErrorLink::get().Call( aArg );
bCopied = true; bCopied = true;
} }
// DBG_ASSERT( nErr == FAT_OK ,"Storage kaputt"); // DBG_ASSERT( nErr == FAT_OK ,"Storage kaputt");
......
...@@ -64,8 +64,8 @@ public: ...@@ -64,8 +64,8 @@ public:
bool Init(); // set up an empty file bool Init(); // set up an empty file
bool CommitAll(); // commit everything (root commit) bool CommitAll(); // commit everything (root commit)
static void SetErrorLink( const Link<>& ); static void SetErrorLink( const Link<StgLinkArg&,void>& );
static const Link<>& GetErrorLink(); static const Link<StgLinkArg&,void>& GetErrorLink();
sal_uLong ValidateFATs( ); sal_uLong ValidateFATs( );
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment