mirror of
https://github.com/CommunityOx/ox_lib.git
synced 2026-08-17 06:56:03 +01:00
feat(interface/radial): allow clearing all global radial menu items (#272)
* Add clearAllRadialItems * Refresh rather then close, rename
This commit is contained in:
@@ -182,6 +182,16 @@ function lib.removeRadialItem(id)
|
||||
refreshRadial(id)
|
||||
end
|
||||
|
||||
---Removes all items from the global radial menu.
|
||||
function lib.clearRadialItems()
|
||||
table.wipe(menuItems)
|
||||
|
||||
if isOpen then
|
||||
refreshRadial()
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
RegisterNUICallback('radialClick', function(index, cb)
|
||||
cb(1)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user