Dropdown List Still a Problem - Pre-Patch Shadowlands #235


Closed
  • MarkParish created this issue Oct 17, 2020

    The previous patch mention work to get it back working all EXCEPT the dropdown list were you can select from the ALTS and Guild members to send mail To:

     

    Please help, cause I really want to get Postal back up and working. 

  • Forge_User_92759659 posted a comment Oct 18, 2020

     

    I just learned that if you have any of your own toons set as friends, then they block the drop down list. 

    By removing those of your own account toons, then it should work again.

    But friends are not listed in the dropdown - only recent, guildies and alts.

     

     

  • stavmar posted a comment Oct 18, 2020

    I don't have any of my own toons as friends listed in my "O" tab, so Io am not too sure what could be causing this error after updating the code in the previous message:

     

    Message: attempt to compare two table values
    Time: Sun Oct 18 10:37:11 2020
    Count: 1
    Stack: attempt to compare two table values
    [string "=[C]"]: ?
    [string "=[C]"]: in function `sort'
    [string "@Interface\AddOns\Postal\Modules\BlackBook.lua"]:377: in function `SortAndCountNumFriends'
    [string "@Interface\AddOns\Postal\Modules\BlackBook.lua"]:446: in function `initFunction'
    [string "@Interface\SharedXML\UIDropDownMenu.lua"]:78: in function `UIDropDownMenu_Initialize'
    [string "@Interface\SharedXML\UIDropDownMenu.lua"]:1055: in function <Interface\SharedXML\UIDropDownMenu.lua:920>
    [string "=[C]"]: ?
    [string "=[C]"]: in function `ToggleDropDownMenu'
    [string "@Interface\AddOns\Postal\Modules\BlackBook.lua"]:41: in function <Interface\AddOns\Postal\Modules\BlackBook.lua:36>

    Locals:

     

    Each time i click on the down arrow i get the above message.

  • MarkParish posted a comment Oct 18, 2020

    ok I'm not even showing errors when I try to use it. Where stavmar for example and other have seen errors pop up. Can we now turn back to be all these pre-patch changes now?

     

    Anyway, I don't have any of my own toons list in the friends list.

  • Fr1edbones posted a comment Oct 19, 2020

    Am experiencing a lua error whenever I try to choose any contact on my mailing list.  Here is the error message I keep getting:

     

    Message: Interface\AddOns\Postal\Modules\BlackBook.lua:360: attempt to call global 'GetNumFriends' (a nil value)
    Time: Mon Oct 19 23:08:55 2020
    Count: 1
    Stack: Interface\AddOns\Postal\Modules\BlackBook.lua:360: attempt to call global 'GetNumFriends' (a nil value)
    [string "@Interface\AddOns\Postal\Modules\BlackBook.lua"]:360: in function `SortAndCountNumFriends'
    [string "@Interface\AddOns\Postal\Modules\BlackBook.lua"]:437: in function `initFunction'
    [string "@Interface\SharedXML\UIDropDownMenu.lua"]:78: in function `UIDropDownMenu_Initialize'
    [string "@Interface\SharedXML\UIDropDownMenu.lua"]:1055: in function `ToggleDropDownMenu'
    [string "@Interface\AddOns\Postal\Modules\BlackBook.lua"]:41: in function <Interface\AddOns\Postal\Modules\BlackBook.lua:36>

    Locals: self = <table> {
    SetDefaultModuleLibraries = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:367
    description = "Adds a contact list next to the To: field."
    Enable = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:294
    NewModule = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:235
    baseName = "Postal"
    EnableModule = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:332
    modules = <table> {
    }
    GetModule = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:210
    IterateEmbeds = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:442
    ModuleMenu = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:695
    SecureHook = <function> defined @Interface\AddOns\AzeriteTooltip\libs\AceHook-3.0\AceHook-3.0.lua:336
    defaultModuleLibraries = <table> {
    }
    OnChar = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:223
    AddContact = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:338
    SaveFriendGuildOption = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:672
    RawHookScript = <function> defined @Interface\AddOns\AzeriteTooltip\libs\AceHook-3.0\AceHook-3.0.lua:395
    BlackBookMenu = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:375
    SortAndCountNumFriends = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:358
    RemoveContact = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:349
    SetDefaultModulePrototype = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:409
    SetAutoComplete = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:681
    SetSendMailName = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:332
    UnregisterAllEvents = <function> defined @Interface\AddOns\AzeritePowerWeights\CallbackHandler-1.0\CallbackHandler-1.0.lua:174
    name = "Postal_BlackBook"
    OnEditFocusGained = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:209
    IsEnabled = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:451
    orderedModules = <table> {
    }
    MailFrameTab_OnClick = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:188
    DisableModule = <function> defined @Interface\AddOns\Identity-2\Libs\AceAddon-3.0\AceAddon-3.0.lua:350
    ClearRecent = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:183
    SendMessage = <function> defined @Interface\AddOns\AzeritePowerWeights\CallbackHandler-1.0\CallbackHandler-1.0.lua:59
    HookScript = <function> defined @Interface\AddOns\AzeriteTooltip\libs\AceHook-3.0\AceHook-3.0.lua:366
    Reset = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:96
    RegisterMessage = <function> defined @Interface\AddOns\AzeritePowerWeights\CallbackHandler-1.0\CallbackHandler-1.0.lua:90
    UnregisterMessage = <function> defined @Interface\AddOns\AzeritePowerWeights\CallbackHandler-1.0\CallbackHandler-1.0.lua:153
    SendMailFrame_Reset = <function> defined @Interface\AddOns\Postal\Modules\BlackBook.lua:157
    OnDisable = <function> defi

     

     

  • Fr1edbones posted a comment Oct 19, 2020

    This addon does not look like its being maintained.  The last time it was updated was way back in January.  Is anyone taking care of this thing now?

  • BossInvader posted a comment Oct 20, 2020

    @Fr1edbones

    I sure hope so, this is the best mail addon that doesn't completely change the default UI look/feel by adding so many useful features. It shows 5 people who maintain it, hope at least one of them are still active.

  • MarkParish posted a comment Oct 20, 2020

    Yes... this is the best Mail AddOn out there. I wish that somebody would help with it

     

  • elrontur posted a comment Oct 21, 2020

    I have digged a bit deeper into the core problem of the Friends dropdown and actually got it to work again. It shows the WoW Friends (from Contacts list) by Name or Name-Realm respectively, and they're clickable to automatically add to the "To:" field.

    Also, no need to remove any WoW ingame friends. The issue with anything > 1 friend most definitely must have been because of the wrong addon code.

     

    A direct download to the modified BlackBook.lua file (Archive > /Modules/BlackBook.lua) is here:

    https://drive.google.com/file/d/1v7aerq7jGVEEpMvJEavf3NuVMAtySClP/view?usp=sharing

    Extract it directly into where your WoW + Postal is installed, here: <Drive:>.../World of Warcraft/_retail_/Interface/AddOns/Postal/

     

    Or edit it yourself. The changes are as follows:

     

    Line 358 - 373 edited to:

    function Postal_BlackBook:SortAndCountNumFriends()
    	wipe(sorttable)
    
    	local numFriends = C_FriendList.GetNumFriends();
    	for i = 1, numFriends do
    		sorttable[i] = C_FriendList.GetFriendInfoByIndex(i)
    	end
    
    	-- removed lines causing issues
    
    	-- Sort the list
    	--if numFriends > 0 and not ignoresortlocale[GetLocale()] then table.sort(sorttable) end
    
    	-- Store upvalue
    	numFriendsOnList = numFriends
    	return numFriends
    end

     

    Line 565 - 577 edited to:

    elseif UIDROPDOWNMENU_MENU_VALUE == "friend" then
    	-- Friends list
    	local numFriends = Postal_BlackBook:SortAndCountNumFriends()
    	-- 25 or less, don't need multi level menus
    	if numFriends > 0 and numFriends <= 25 then
    		for i = 1, numFriends do
    			local f = sorttable[i]
    			info.text = tostring(f.name)
    			info.func = Postal_BlackBook.SetSendMailName
    			info.arg1 = tostring(f.name)
    			UIDropDownMenu_AddButton(info, level)
    		end
    [...]

     

    Line 646 - 655 edited to:

    elseif strfind(UIDROPDOWNMENU_MENU_VALUE, "fpart") then
    	local startIndex = tonumber(strmatch(UIDROPDOWNMENU_MENU_VALUE, "fpart(%d+)")) * 25 - 24
    	local endIndex = math.min(startIndex+24, numFriendsOnList)
    	for i = startIndex, endIndex do
    		local f = sorttable[i]
    		info.text = tostring(f.name)
    		info.func = Postal_BlackBook.SetSendMailName
    		info.arg1 = tostring(f.name)
    		UIDropDownMenu_AddButton(info, level)
    	end
    [...]

     


    Edited Oct 21, 2020
  • Zimzarina closed issue Oct 22, 2020
  • Zimzarina posted a comment Oct 22, 2020

    Fixed in release v3.6.3.


To post a comment, please login or register a new account.