- removed incorrect information about DrawOption, renamed to DisplayOption
- renamed DrawTitle to DisplayTitle --HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%401531
This commit is contained in:
parent
a130fede3a
commit
bd89b6d126
@ -113,7 +113,7 @@ public CategoryHandler(Handle:topmenu,
|
|||||||
String:buffer[],
|
String:buffer[],
|
||||||
maxlength)
|
maxlength)
|
||||||
{
|
{
|
||||||
if (action == TopMenuAction_DrawTitle)
|
if (action == TopMenuAction_DisplayTitle)
|
||||||
{
|
{
|
||||||
if (object_id == INVALID_TOPMENUOBJECT)
|
if (object_id == INVALID_TOPMENUOBJECT)
|
||||||
{
|
{
|
||||||
@ -132,7 +132,7 @@ public CategoryHandler(Handle:topmenu,
|
|||||||
Format(buffer, maxlength, "%T:", "Voting Commands", param);
|
Format(buffer, maxlength, "%T:", "Voting Commands", param);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (action == TopMenuAction_DrawOption)
|
else if (action == TopMenuAction_DisplayOption)
|
||||||
{
|
{
|
||||||
if (object_id == obj_playercmds)
|
if (object_id == obj_playercmds)
|
||||||
{
|
{
|
||||||
@ -146,7 +146,6 @@ public CategoryHandler(Handle:topmenu,
|
|||||||
{
|
{
|
||||||
Format(buffer, maxlength, "%T", "Voting Commands", param);
|
Format(buffer, maxlength, "%T", "Voting Commands", param);
|
||||||
}
|
}
|
||||||
return ITEMDRAW_DEFAULT;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -19,26 +19,15 @@ public AdminMenu_CancelVote(Handle:topmenu,
|
|||||||
String:buffer[],
|
String:buffer[],
|
||||||
maxlength)
|
maxlength)
|
||||||
{
|
{
|
||||||
if (action == TopMenuAction_DrawOption)
|
if (action == TopMenuAction_DisplayOption)
|
||||||
{
|
{
|
||||||
Format(buffer, maxlength, "%T", "Cancel vote", param);
|
Format(buffer, maxlength, "%T", "Cancel vote", param);
|
||||||
|
|
||||||
if (IsVoteInProgress())
|
|
||||||
{
|
|
||||||
return ITEMDRAW_DEFAULT;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return ITEMDRAW_IGNORE;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else if (action == TopMenuAction_SelectOption)
|
else if (action == TopMenuAction_SelectOption)
|
||||||
{
|
{
|
||||||
PerformCancelVote(param);
|
PerformCancelVote(param);
|
||||||
RedisplayAdminMenu(topmenu, param);
|
RedisplayAdminMenu(topmenu, param);
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public Action:Command_CancelVote(client, args)
|
public Action:Command_CancelVote(client, args)
|
||||||
|
@ -39,7 +39,7 @@ public AdminMenu_Kick(Handle:topmenu,
|
|||||||
String:buffer[],
|
String:buffer[],
|
||||||
maxlength)
|
maxlength)
|
||||||
{
|
{
|
||||||
if (action == TopMenuAction_DrawOption)
|
if (action == TopMenuAction_DisplayOption)
|
||||||
{
|
{
|
||||||
Format(buffer, maxlength, "%T", "Kick player", param);
|
Format(buffer, maxlength, "%T", "Kick player", param);
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ public AdminMenu_ReloadAdmins(Handle:topmenu,
|
|||||||
String:buffer[],
|
String:buffer[],
|
||||||
maxlength)
|
maxlength)
|
||||||
{
|
{
|
||||||
if (action == TopMenuAction_DrawOption)
|
if (action == TopMenuAction_DisplayOption)
|
||||||
{
|
{
|
||||||
Format(buffer, maxlength, "%T", "Reload admins", param);
|
Format(buffer, maxlength, "%T", "Reload admins", param);
|
||||||
}
|
}
|
||||||
|
@ -47,10 +47,8 @@ enum TopMenuAction
|
|||||||
*
|
*
|
||||||
* INPUT : TopMenu Handle, object ID, client index in extra parameter.
|
* INPUT : TopMenu Handle, object ID, client index in extra parameter.
|
||||||
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
||||||
* OUTPUT: Must return an ITEMDRAW constant. The return value may be ignored
|
|
||||||
* if the item is simply being sorted into the menu.
|
|
||||||
*/
|
*/
|
||||||
TopMenuAction_DrawOption = 0,
|
TopMenuAction_DisplayOption = 0,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The title of a menu is being drawn for a given object.
|
* The title of a menu is being drawn for a given object.
|
||||||
@ -61,7 +59,7 @@ enum TopMenuAction
|
|||||||
* INPUT : TopMenu Handle, object ID, client index in extra parameter.
|
* INPUT : TopMenu Handle, object ID, client index in extra parameter.
|
||||||
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
||||||
*/
|
*/
|
||||||
TopMenuAction_DrawTitle = 1,
|
TopMenuAction_DisplayTitle = 1,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A menu option has been selected.
|
* A menu option has been selected.
|
||||||
|
Loading…
Reference in New Issue
Block a user