View Single Post
11-13-16, 10:39 AM   #11
Phanx
Cat.
 
Phanx's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 5,617
Originally Posted by SDPhantom View Post
Lua Code:
  1. MainFrame:SetShown(itemid and true or false);-- Typecast to boolean
Not specifically related to anything, but another, less verbose way to do that would be:

Lua Code:
  1. MainFrame:SetShown(not not itemid); -- Typecast to boolean
__________________
Retired author of too many addons.
Message me if you're interested in taking over one of my addons.
Don’t message me about addon bugs or programming questions.
  Reply With Quote