mirror of
https://github.com/edubart/otclient.git
synced 2025-10-17 21:13:26 +02:00
Fix #576, PopupMenus close when leaving the game
This commit is contained in:
@@ -345,6 +345,7 @@ function onVipListMousePress(widget, mousePos, mouseButton)
|
||||
local vipList = vipWindow:getChildById('contentsPanel')
|
||||
|
||||
local menu = g_ui.createWidget('PopupMenu')
|
||||
menu:setGameMenu(true)
|
||||
menu:addOption(tr('Add new VIP'), function() createAddWindow() end)
|
||||
|
||||
menu:addSeparator()
|
||||
@@ -377,6 +378,7 @@ function onVipListLabelMousePress(widget, mousePos, mouseButton)
|
||||
local vipList = vipWindow:getChildById('contentsPanel')
|
||||
|
||||
local menu = g_ui.createWidget('PopupMenu')
|
||||
menu:setGameMenu(true)
|
||||
menu:addOption(tr('Send Message'), function() g_game.openPrivateChannel(widget:getText()) end)
|
||||
menu:addOption(tr('Add new VIP'), function() createAddWindow() end)
|
||||
menu:addOption(tr('Edit %s', widget:getText()), function() if widget then createEditWindow(widget) end end)
|
||||
|
Reference in New Issue
Block a user