Corrected an API design flaw with pausing. Contexts can now be flagged as paused, and IsRunnable() is moved from IBaseContext to IPluginFunction. While this allows for per-function pausing, it is not intended that way.
--HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40531
This commit is contained in:
@@ -184,6 +184,13 @@ namespace SourcePawn
|
||||
* @return Address, or NULL if invalid parameter specified.
|
||||
*/
|
||||
virtual cell_t *GetAddressOfPushedParam(unsigned int param) =0;
|
||||
|
||||
/**
|
||||
* @brief Returns whether the parent plugin is paused.
|
||||
*
|
||||
* @return True if runnable, false otherwise.
|
||||
*/
|
||||
virtual bool IsRunnable() =0;
|
||||
};
|
||||
|
||||
|
||||
@@ -534,13 +541,6 @@ namespace SourcePawn
|
||||
* @return Identity token.
|
||||
*/
|
||||
virtual SourceMod::IdentityToken_t *GetIdentity() =0;
|
||||
|
||||
/**
|
||||
* @brief Returns whether the identity is runnable.
|
||||
*
|
||||
* @return True if runnable, false otherwise.
|
||||
*/
|
||||
virtual bool IsRunnable() =0;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
@@ -229,6 +229,7 @@ typedef struct sp_debug_symbol_s
|
||||
typedef int (*SPVM_DEBUGBREAK)(struct sp_context_s *, uint32_t, uint32_t);
|
||||
|
||||
#define SPFLAG_PLUGIN_DEBUG (1<<0) /**< plugin is in debug mode */
|
||||
#define SPFLAG_PLUGIN_PAUSED (1<<1) /**< plugin is "paused" (blocked from executing) */
|
||||
|
||||
/**
|
||||
* @brief This is the heart of the VM. It contains all of the runtime
|
||||
|
||||
Reference in New Issue
Block a user