SourceMod::IMenuStyle Class Reference

Describes a "MenuStyle" system which manages menu drawing and construction. More...

#include <public/IMenuManager.h>

List of all members.

Public Member Functions

virtual unsigned int GetStyleAPIVersion ()
 Returns the style API version.
virtual const char * GetStyleName ()=0
 Returns the name of the menu style.
virtual IMenuPanelCreatePanel ()=0
 Creates an IMenuPanel object.
virtual IBaseMenuCreateMenu (IMenuHandler *handler, IdentityToken_t *pOwner=NULL)=0
 Creates an IBaseMenu object of this style.
virtual unsigned int GetMaxPageItems ()=0
 Returns the maximum number of items per page.
virtual MenuSource GetClientMenu (int client, void **object)=0
 Returns whether or not a client is viewing a menu.
virtual bool CancelClientMenu (int client, bool autoIgnore=false)=0
 Cancels a client's menu.
virtual Handle_t GetHandle ()=0
 Returns a Handle the IMenuStyle object.
virtual unsigned int GetApproxMemUsage ()=0
 For the Handle system, returns approximate memory usage.


Detailed Description

Describes a "MenuStyle" system which manages menu drawing and construction.

Definition at line 339 of file IMenuManager.h.


Member Function Documentation

virtual unsigned int SourceMod::IMenuStyle::GetStyleAPIVersion (  )  [inline, virtual]

Returns the style API version.

Returns:
API version.

Definition at line 347 of file IMenuManager.h.

virtual const char* SourceMod::IMenuStyle::GetStyleName (  )  [pure virtual]

Returns the name of the menu style.

Returns:
String containing the style name.

virtual IMenuPanel* SourceMod::IMenuStyle::CreatePanel (  )  [pure virtual]

Creates an IMenuPanel object.

Note: the object should be freed using DeleteThis.

Returns:
IMenuPanel object.

virtual IBaseMenu* SourceMod::IMenuStyle::CreateMenu ( IMenuHandler handler,
IdentityToken_t *  pOwner = NULL 
) [pure virtual]

Creates an IBaseMenu object of this style.

Note: the object should be freed using IBaseMenu::Destroy.

Parameters:
handler IMenuHandler pointer.
pOwner Optional IdentityToken_t owner for handle creation.
Returns:
An IBaseMenu pointer.

virtual unsigned int SourceMod::IMenuStyle::GetMaxPageItems (  )  [pure virtual]

Returns the maximum number of items per page.

Menu implementations must return >= 2. Styles with only 1 or 0 items per page are not valid.

Returns:
Number of items per page.

virtual MenuSource SourceMod::IMenuStyle::GetClientMenu ( int  client,
void **  object 
) [pure virtual]

Returns whether or not a client is viewing a menu.

Parameters:
client Client index.
object Optional pointer to retrieve menu object, if any.
Returns:
MenuSource value.

virtual bool SourceMod::IMenuStyle::CancelClientMenu ( int  client,
bool  autoIgnore = false 
) [pure virtual]

Cancels a client's menu.

Parameters:
client Client index.
autoIgnore If true, no menus can be created during the cancellation process.
Returns:
True if a menu was cancelled, false otherwise.

virtual Handle_t SourceMod::IMenuStyle::GetHandle (  )  [pure virtual]

Returns a Handle the IMenuStyle object.

Returns:
Handle_t pointing to this object.

virtual unsigned int SourceMod::IMenuStyle::GetApproxMemUsage (  )  [pure virtual]

For the Handle system, returns approximate memory usage.

Returns:
Approximate number of bytes being used.


The documentation for this class was generated from the following file:
Generated on Fri Nov 21 04:10:06 2008 for SourceMod SDK by  doxygen 1.5.1