added usage of the Handle System to begin experimenting
--HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40257
This commit is contained in:
@@ -302,10 +302,10 @@ Handle_t HandleSystem::CreateHandle(HandleType_t type, void *object, IdentityTok
|
||||
|
||||
Handle_t HandleSystem::CreateScriptHandle(HandleType_t type,
|
||||
void *object,
|
||||
sp_context_t *ctx,
|
||||
IPluginContext *pContext,
|
||||
IdentityToken_t *ident)
|
||||
{
|
||||
IPlugin *pPlugin = g_PluginSys.FindPluginByContext(ctx);
|
||||
IPlugin *pPlugin = g_PluginSys.FindPluginByContext(pContext->GetContext());
|
||||
|
||||
return CreateHandle(type, object, pPlugin->GetIdentity(), ident);
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ public: //IHandleSystem
|
||||
void *object,
|
||||
IdentityToken_t *source,
|
||||
IdentityToken_t *ident);
|
||||
Handle_t CreateScriptHandle(HandleType_t type, void *object, sp_context_t *ctx, IdentityToken_t *ident);
|
||||
Handle_t CreateScriptHandle(HandleType_t type, void *object, IPluginContext *pContext, IdentityToken_t *ident);
|
||||
HandleError FreeHandle(Handle_t handle, IdentityToken_t *ident);
|
||||
HandleError CloneHandle(Handle_t handle, Handle_t *newhandle, IdentityToken_t *source, IdentityToken_t *ident);
|
||||
HandleError ReadHandle(Handle_t handle, HandleType_t type, IdentityToken_t *ident, void **object);
|
||||
|
||||
@@ -93,6 +93,11 @@ void CDirectory::NextEntry()
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CDirectory::IsEntryValid()
|
||||
{
|
||||
return IsValid();
|
||||
}
|
||||
|
||||
bool CDirectory::IsEntryDirectory()
|
||||
{
|
||||
#if defined PLATFORM_WINDOWS
|
||||
|
||||
@@ -23,6 +23,7 @@ public:
|
||||
virtual const char *GetEntryName();
|
||||
virtual bool IsEntryDirectory();
|
||||
virtual bool IsEntryFile();
|
||||
virtual bool IsEntryValid();
|
||||
public:
|
||||
bool IsValid();
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user