1.1 --- a/extensions/topmenus/TopMenu.cpp Tue Oct 02 14:48:44 2007 +0000
1.2 +++ b/extensions/topmenus/TopMenu.cpp Tue Oct 02 15:13:13 2007 +0000
1.3 @@ -462,6 +462,12 @@
1.4
1.5 obj = *pObject;
1.6
1.7 + style = obj->callbacks->OnTopMenuDrawOption(this, client, obj->object_id);
1.8 + if (style != ITEMDRAW_DEFAULT)
1.9 + {
1.10 + return;
1.11 + }
1.12 +
1.13 if (obj->cmdname[0] == '\0')
1.14 {
1.15 return;
1.16 @@ -496,7 +502,7 @@
1.17
1.18 /* Ask the object to render the text for this client */
1.19 char renderbuf[64];
1.20 - obj->callbacks->OnTopMenuDrawOption(this, client, obj->object_id, renderbuf, sizeof(renderbuf));
1.21 + obj->callbacks->OnTopMenuDisplayOption(this, client, obj->object_id, renderbuf, sizeof(renderbuf));
1.22
1.23 /* Build the new draw info */
1.24 ItemDrawInfo new_dr = dr;
1.25 @@ -584,7 +590,7 @@
1.26 {
1.27 obj_by_name_t *temp_obj = &item_list[i];
1.28 topmenu_object_t *obj = m_Categories[m_UnsortedCats[i]]->obj;
1.29 - obj->callbacks->OnTopMenuDrawOption(this,
1.30 + obj->callbacks->OnTopMenuDisplayOption(this,
1.31 client,
1.32 obj->object_id,
1.33 temp_obj->name,
1.34 @@ -610,7 +616,7 @@
1.35
1.36 /* Set the menu's title */
1.37 char renderbuf[128];
1.38 - m_pTitle->OnTopMenuDrawTitle(this, client, 0, renderbuf, sizeof(renderbuf));
1.39 + m_pTitle->OnTopMenuDisplayTitle(this, client, 0, renderbuf, sizeof(renderbuf));
1.40 root_menu->SetDefaultTitle(renderbuf);
1.41
1.42 /* The client is now fully updated */
1.43 @@ -676,7 +682,7 @@
1.44 {
1.45 obj_by_name_t *item = &item_list[i];
1.46 topmenu_object_t *obj = cat->unsorted[i];
1.47 - obj->callbacks->OnTopMenuDrawOption(this,
1.48 + obj->callbacks->OnTopMenuDisplayOption(this,
1.49 client,
1.50 obj->object_id,
1.51 item->name,
1.52 @@ -698,7 +704,7 @@
1.53
1.54 /* Set the menu's title */
1.55 char renderbuf[128];
1.56 - cat->obj->callbacks->OnTopMenuDrawTitle(this,
1.57 + cat->obj->callbacks->OnTopMenuDisplayTitle(this,
1.58 client,
1.59 cat->obj->object_id,
1.60 renderbuf,