function AtlasLootRepMenu()
    for i = 1, 30, 1 do
        getglobal("AtlasLootItem_"..i):Hide();
    end
    for i = 1, 30, 1 do
        getglobal("AtlasLootMenuItem_"..i):Hide();
    end
    getglobal("AtlasLootItemsFrame_NEXT"):Hide();
    getglobal("AtlasLootItemsFrame_PREV"):Hide();
    --The Aldor
    AtlasLootMenuItem_1_Name:SetText(ATLASLOOT_FACTION_ALDOR);
    AtlasLootMenuItem_1_Extra:SetText("");
    AtlasLootMenuItem_1_Icon:SetTexture("Interface\\Icons\\Spell_Holy_SealOfSalvation");
    AtlasLootMenuItem_1.type="Factions";
    AtlasLootMenuItem_1.lootpage="Aldor1";
    AtlasLootMenuItem_1.text=ATLASLOOT_FACTION_ALDOR;
    AtlasLootMenuItem_1:Show();
    --Argent Dawn
    AtlasLootMenuItem_16_Name:SetText(ATLASLOOT_FACTION_ARGENT);
    AtlasLootMenuItem_16_Extra:SetText("");
    AtlasLootMenuItem_16_Icon:SetTexture("Interface\\Icons\\INV_Jewelry_Talisman_08");
    AtlasLootMenuItem_16.type="Factions";
    AtlasLootMenuItem_16.lootpage="Argent1";
    AtlasLootMenuItem_16.text=ATLASLOOT_FACTION_ARGENT;
    AtlasLootMenuItem_16:Show();
    --Bloodsail Pirates
    AtlasLootMenuItem_2_Name:SetText(ATLASLOOT_FACTION_PIRATES);
    AtlasLootMenuItem_2_Extra:SetText("");
    AtlasLootMenuItem_2_Icon:SetTexture("Interface\\Icons\\INV_Helmet_66");
    AtlasLootMenuItem_2.type="Factions";
    AtlasLootMenuItem_2.lootpage="Bloodsail1";
    AtlasLootMenuItem_2.text=ATLASLOOT_FACTION_PIRATES;
    AtlasLootMenuItem_2:Show();
    --Brood of Nozdormu
    AtlasLootMenuItem_17_Name:SetText(ATLASLOOT_FACTION_BROOD);
    AtlasLootMenuItem_17_Extra:SetText("");
    AtlasLootMenuItem_17_Icon:SetTexture("Interface\\Icons\\INV_Jewelry_Ring_40");
    AtlasLootMenuItem_17.type="Factions";
    AtlasLootMenuItem_17.lootpage="AQBroodRings";
    AtlasLootMenuItem_17.text=ATLASLOOT_FACTION_BROOD;
    AtlasLootMenuItem_17:Show();
    --Cenarion Hold
    AtlasLootMenuItem_3_Name:SetText(ATLASLOOT_FACTION_CENARION);
    AtlasLootMenuItem_3_Extra:SetText("");
    AtlasLootMenuItem_3_Icon:SetTexture("Interface\\Icons\\INV_Chest_Plate07");
    AtlasLootMenuItem_3.type="Factions";
    AtlasLootMenuItem_3.lootpage="Cenarion1";
    AtlasLootMenuItem_3.text=ATLASLOOT_FACTION_CENARION;
    AtlasLootMenuItem_3:Show();
    --Cenarion Expedition
    AtlasLootMenuItem_18_Name:SetText(ATLASLOOT_FACTION_CENARION_EXPEDITION);
    AtlasLootMenuItem_18_Extra:SetText("");
    AtlasLootMenuItem_18_Icon:SetTexture("Interface\\Icons\\INV_Misc_Ammo_Arrow_02");
    AtlasLootMenuItem_18.type="Factions";
    AtlasLootMenuItem_18.lootpage="CExpedition1";
    AtlasLootMenuItem_18.text=ATLASLOOT_FACTION_CENARION_EXPEDITION;
    AtlasLootMenuItem_18:Show();
    --The Consortium
    AtlasLootMenuItem_4_Name:SetText(ATLASLOOT_FACTION_CONSORTIUM);
    AtlasLootMenuItem_4_Extra:SetText("");
    AtlasLootMenuItem_4_Icon:SetTexture("Interface\\Icons\\INV_Weapon_Shortblade_31");
    AtlasLootMenuItem_4.type="Factions";
    AtlasLootMenuItem_4.lootpage="Consortium1";
    AtlasLootMenuItem_4.text=ATLASLOOT_FACTION_CONSORTIUM;
    AtlasLootMenuItem_4:Show();
    --Darkmoon Faire
    AtlasLootMenuItem_19_Name:SetText(ATLASLOOT_FACTION_DARKMOON);
    AtlasLootMenuItem_19_Extra:SetText("");
    AtlasLootMenuItem_19_Icon:SetTexture("Interface\\Icons\\INV_Misc_Ticket_Tarot_Maelstrom_01");
    AtlasLootMenuItem_19.type="Factions";
    AtlasLootMenuItem_19.lootpage="Darkmoon";
    AtlasLootMenuItem_19.text=ATLASLOOT_FACTION_DARKMOON;
    AtlasLootMenuItem_19:Show();
    --Frostwolf Clan
    AtlasLootMenuItem_5_Name:SetText(ATLASLOOT_FACTION_FROSTWOLF);
    AtlasLootMenuItem_5_Extra:SetText("|cffFF8400"..ATLASLOOT_HORDE);
    AtlasLootMenuItem_5_Icon:SetTexture("Interface\\Icons\\INV_Jewelry_FrostwolfTrinket_01");
    AtlasLootMenuItem_5.type="Factions";
    AtlasLootMenuItem_5.lootpage="Frostwolf1";
    AtlasLootMenuItem_5.text=ATLASLOOT_FACTION_FROSTWOLF;
    AtlasLootMenuItem_5:Show();
    --Honor Hold
    AtlasLootMenuItem_20_Name:SetText(ATLASLOOT_FACTION_HONOR_HOLD);
    AtlasLootMenuItem_20_Extra:SetText("|cffFF8400"..ATLASLOOT_ALLIANCE);
    AtlasLootMenuItem_20_Icon:SetTexture("Interface\\Icons\\INV_BannerPVP_02");
    AtlasLootMenuItem_20.type="Factions";
    AtlasLootMenuItem_20.lootpage="HonorHold1";
    AtlasLootMenuItem_20.text=ATLASLOOT_FACTION_HONOR_HOLD;
    AtlasLootMenuItem_20:Show();
    --Hydraxian Waterlords
    AtlasLootMenuItem_6_Name:SetText(ATLASLOOT_FACTION_WATERLORDS);
    AtlasLootMenuItem_6_Extra:SetText("");
    AtlasLootMenuItem_6_Icon:SetTexture("Interface\\Icons\\Spell_Frost_SummonWaterElemental_2");
    AtlasLootMenuItem_6.type="Factions";
    AtlasLootMenuItem_6.lootpage="WaterLords1";
    AtlasLootMenuItem_6.text=ATLASLOOT_FACTION_WATERLORDS;
    AtlasLootMenuItem_6:Show();
    --Keepers of Time
    AtlasLootMenuItem_21_Name:SetText(ATLASLOOT_FACTION_KEEPERS);
    AtlasLootMenuItem_21_Extra:SetText("");
    AtlasLootMenuItem_21_Icon:SetTexture("Interface\\Icons\\Ability_Warrior_VictoryRush");
    AtlasLootMenuItem_21.type="Factions";
    AtlasLootMenuItem_21.lootpage="KeepersofTime1";
    AtlasLootMenuItem_21.text=ATLASLOOT_FACTION_KEEPERS;
    AtlasLootMenuItem_21:Show();
    --Kurenai
    AtlasLootMenuItem_7_Name:SetText(ATLASLOOT_FACTION_KURENAI);
    AtlasLootMenuItem_7_Extra:SetText("|cffFF8400"..ATLASLOOT_ALLIANCE);
    AtlasLootMenuItem_7_Icon:SetTexture("Interface\\Icons\\INV_Misc_Foot_Centaur");
    AtlasLootMenuItem_7.type="Factions";
    AtlasLootMenuItem_7.lootpage="Kurenai1";
    AtlasLootMenuItem_7.text=ATLASLOOT_FACTION_KURENAI;
    AtlasLootMenuItem_7:Show();
    --The Lower City
    AtlasLootMenuItem_22_Name:SetText(ATLASLOOT_FACTION_LOWERCITY);
    AtlasLootMenuItem_22_Extra:SetText("");
    AtlasLootMenuItem_22_Icon:SetTexture("Interface\\Icons\\Ability_Rogue_MasterOfSubtlety");
    AtlasLootMenuItem_22.type="Factions";
    AtlasLootMenuItem_22.lootpage="LowerCity1";
    AtlasLootMenuItem_22.text=ATLASLOOT_FACTION_LOWERCITY;
    AtlasLootMenuItem_22:Show();
    --The Mag'har
    AtlasLootMenuItem_8_Name:SetText(ATLASLOOT_FACTION_MAGHAR);
    AtlasLootMenuItem_8_Extra:SetText("|cffFF8400"..ATLASLOOT_HORDE);
    AtlasLootMenuItem_8_Icon:SetTexture("Interface\\Icons\\INV_Misc_Foot_Centaur");
    AtlasLootMenuItem_8.type="Factions";
    AtlasLootMenuItem_8.lootpage="Maghar1";
    AtlasLootMenuItem_8.text=ATLASLOOT_FACTION_MAGHAR;
    AtlasLootMenuItem_8:Show();
    --The Scale of the Sands
    AtlasLootMenuItem_23_Name:SetText(ATLASLOOT_FACTION_SCALE);
    AtlasLootMenuItem_23_Extra:SetText("");
    AtlasLootMenuItem_23_Icon:SetTexture("Interface\\Icons\\INV_Misc_MonsterScales_13");
    AtlasLootMenuItem_23.type="Factions";
    AtlasLootMenuItem_23.lootpage="ScaleSands1";
    AtlasLootMenuItem_23.text=ATLASLOOT_FACTION_SCALE;
    AtlasLootMenuItem_23:Show();
    --The Scryers
    AtlasLootMenuItem_9_Name:SetText(ATLASLOOT_FACTION_SCRYER);
    AtlasLootMenuItem_9_Extra:SetText("");
    AtlasLootMenuItem_9_Icon:SetTexture("Interface\\Icons\\Spell_Holy_ChampionsBond");
    AtlasLootMenuItem_9.type="Factions";
    AtlasLootMenuItem_9.lootpage="Scryer1";
    AtlasLootMenuItem_9.text=ATLASLOOT_FACTION_SCRYER;
    AtlasLootMenuItem_9:Show();
    --The Sha'tar
    AtlasLootMenuItem_24_Name:SetText(ATLASLOOT_FACTION_SHATAR);
    AtlasLootMenuItem_24_Extra:SetText("");
    AtlasLootMenuItem_24_Icon:SetTexture("Interface\\Icons\\Spell_Nature_LightningOverload");
    AtlasLootMenuItem_24.type="Factions";
    AtlasLootMenuItem_24.lootpage="Shatar1";
    AtlasLootMenuItem_24.text=ATLASLOOT_FACTION_SHATAR;
    AtlasLootMenuItem_24:Show();
    --Sporeggar
    AtlasLootMenuItem_10_Name:SetText(ATLASLOOT_FACTION_SPOREGGAR);
    AtlasLootMenuItem_10_Extra:SetText("");
    AtlasLootMenuItem_10_Icon:SetTexture("Interface\\Icons\\INV_Mushroom_10");
    AtlasLootMenuItem_10.type="Factions";
    AtlasLootMenuItem_10.lootpage="Sporeggar1";
    AtlasLootMenuItem_10.text=ATLASLOOT_FACTION_SPOREGGAR;
    AtlasLootMenuItem_10:Show();
    --Stormpike
    AtlasLootMenuItem_25_Name:SetText(ATLASLOOT_FACTION_STORMPIKE);
    AtlasLootMenuItem_25_Extra:SetText("|cffFF8400"..ATLASLOOT_ALLIANCE);
    AtlasLootMenuItem_25_Icon:SetTexture("Interface\\Icons\\INV_Jewelry_StormPikeTrinket_01");
    AtlasLootMenuItem_25.type="Factions";
    AtlasLootMenuItem_25.lootpage="Stormpike1";
    AtlasLootMenuItem_25.text=ATLASLOOT_FACTION_STORMPIKE;
    AtlasLootMenuItem_25:Show();
    --Thorium Brotherhood
    AtlasLootMenuItem_11_Name:SetText(ATLASLOOT_FACTION_THORIUM);
    AtlasLootMenuItem_11_Extra:SetText("");
    AtlasLootMenuItem_11_Icon:SetTexture("Interface\\Icons\\INV_Ingot_Mithril");
    AtlasLootMenuItem_11.type="Factions";
    AtlasLootMenuItem_11.lootpage="Thorium1";
    AtlasLootMenuItem_11.text=ATLASLOOT_FACTION_THORIUM;
    AtlasLootMenuItem_11:Show();
    --Thrallmar
    AtlasLootMenuItem_26_Name:SetText(ATLASLOOT_FACTION_THRALLMAR);
    AtlasLootMenuItem_26_Extra:SetText("|cffFF8400"..ATLASLOOT_HORDE);
    AtlasLootMenuItem_26_Icon:SetTexture("Interface\\Icons\\INV_BannerPVP_01");
    AtlasLootMenuItem_26.type="Factions";
    AtlasLootMenuItem_26.lootpage="Thrallmar1";
    AtlasLootMenuItem_26.text=ATLASLOOT_FACTION_THRALLMAR;
    AtlasLootMenuItem_26:Show();
    --The Timbermaw
    AtlasLootMenuItem_12_Name:SetText(ATLASLOOT_FACTION_TIMBERMAW);
    AtlasLootMenuItem_12_Extra:SetText("");
    AtlasLootMenuItem_12_Icon:SetTexture("Interface\\Icons\\INV_Misc_Horn_01");
    AtlasLootMenuItem_12.type="Factions";
    AtlasLootMenuItem_12.lootpage="Timbermaw";
    AtlasLootMenuItem_12.text=ATLASLOOT_FACTION_TIMBERMAW;
    AtlasLootMenuItem_12:Show();
    --The Tranquillien
    AtlasLootMenuItem_27_Name:SetText(ATLASLOOT_FACTION_TRANQ);
    AtlasLootMenuItem_27_Extra:SetText("");
    AtlasLootMenuItem_27_Icon:SetTexture("Interface\\Icons\\INV_Misc_Bandana_03");
    AtlasLootMenuItem_27.type="Factions";
    AtlasLootMenuItem_27.lootpage="Tranquillien1";
    AtlasLootMenuItem_27.text=ATLASLOOT_FACTION_TRANQ;
    AtlasLootMenuItem_27:Show();
    --The Violet Eye
    AtlasLootMenuItem_13_Name:SetText(ATLASLOOT_FACTION_VIOLETEYE);
    AtlasLootMenuItem_13_Extra:SetText("");
    AtlasLootMenuItem_13_Icon:SetTexture("Interface\\Icons\\Ability_Warrior_ShieldMastery");
    AtlasLootMenuItem_13.type="Factions";
    AtlasLootMenuItem_13.lootpage="VioletEye1";
    AtlasLootMenuItem_13.text=ATLASLOOT_FACTION_VIOLETEYE;
    AtlasLootMenuItem_13:Show();
    --The Wintersaber Trainers
    AtlasLootMenuItem_28_Name:SetText(ATLASLOOT_FACTION_WINTERSABER);
    AtlasLootMenuItem_28_Extra:SetText("|cffFF8400"..ATLASLOOT_ALLIANCE);
    AtlasLootMenuItem_28_Icon:SetTexture("Interface\\Icons\\Ability_Mount_PinkTiger");
    AtlasLootMenuItem_28.type="Factions";
    AtlasLootMenuItem_28.lootpage="Wintersaber1";
    AtlasLootMenuItem_28.text=ATLASLOOT_FACTION_WINTERSABER;
    AtlasLootMenuItem_28:Show();
    --Zandalar Tribe
    AtlasLootMenuItem_14_Name:SetText(ATLASLOOT_FACTION_ZANDALAR);
    AtlasLootMenuItem_14_Extra:SetText("");
    AtlasLootMenuItem_14_Icon:SetTexture("Interface\\Icons\\INV_Misc_Coin_08");
    AtlasLootMenuItem_14.type="Factions";
    AtlasLootMenuItem_14.lootpage="Zandalar1";
    AtlasLootMenuItem_14.text=ATLASLOOT_FACTION_ZANDALAR;
    AtlasLootMenuItem_14:Show();
    for i = 1, 30, 1 do
        getglobal("AtlasLootMenuItem_"..i.."_Extra"):Show();
    end
    AtlasLoot_BossName:SetText("|cffFFFFFF"..ATLASLOOT_PANEL_BUTTON_REPUTATION);
    AtlasLoot_SetItemInfoFrame(AtlasLoot_AnchorFrame);
end

--[[function AtlasLoot_Rep(setid, text)
    for i = 1, 30, 1 do
        getglobal("AtlasLootMenuItem_"..i):Hide();
    end
    getglobal("AtlasLootItemsFrame_NEXT"):Hide();
    getglobal("AtlasLootItemsFrame_PREV"):Hide();
    if(setid=="Thorium1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_THORIUM..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Thorium2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Thorium2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_THORIUM..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Thorium1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Cenarion1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CENARION..": "..ATLASLOOT_FRIENDLY, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Cenarion2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Cenarion2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CENARION..": "..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Cenarion3";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Cenarion1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Cenarion3") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CENARION..": "..ATLASLOOT_REVERED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Cenarion4";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Cenarion2";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Cenarion4") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CENARION..": "..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Cenarion3";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Argent1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ARGENT..": "..ATLASLOOT_FACTION_ARGENT_TOKEN, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Argent2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Argent2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ARGENT..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Argent3";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Argent1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Argent3") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ARGENT..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Argent2";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Zandalar1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ZANDALAR..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Zandalar2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Zandalar2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ZANDALAR..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Zandalar1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Aldor1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ALDOR..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Aldor2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Aldor2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_ALDOR..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Aldor1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Scryer1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_SCRYER..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Scryer2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Scryer2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_SCRYER..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Scryer1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="CExpedition1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CENARION_EXPEDITION..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="CExpedition2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="CExpedition2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CENARION_EXPEDITION..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="CExpedition1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Shatar1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_SHATAR..": "..ATLASLOOT_FRIENDLY.."-"..ATLASLOOT_REVERED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Shatar2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Shatar2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_SHATAR..": "..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Shatar1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="LowerCity1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_LOWERCITY..": "..ATLASLOOT_FRIENDLY.."-"..ATLASLOOT_REVERED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="LowerCity2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="LowerCity2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_LOWERCITY..": "..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="LowerCity1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Thrallmar1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_THRALLMAR..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Thrallmar2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Thrallmar2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_THRALLMAR..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Thrallmar1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="HonorHold1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_HONOR_HOLD..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="HonorHold2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="HonorHold2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_HONOR_HOLD..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="HonorHold1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(setid=="Consortium1") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CONSORTIUM..": "..ATLASLOOT_FRIENDLY.."/"..ATLASLOOT_HONORED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_NEXT").lootpage="Consortium2";
        getglobal("AtlasLootItemsFrame_NEXT"):Show();
    elseif(setid=="Consortium2") then
        AtlasLoot_ShowItemsFrame(setid, AtlasLootRepItems, ATLASLOOT_FACTION_CONSORTIUM..": "..ATLASLOOT_REVERED.."/"..ATLASLOOT_EXALTED, AtlasLoot_AnchorFrame);
        getglobal("AtlasLootItemsFrame_PREV").lootpage="Consortium1";
        getglobal("AtlasLootItemsFrame_PREV"):Show();
    elseif(this:GetName()=="AtlasLootItemsFrame_NEXT" or this:GetName()=="AtlasLootItemsFrame_PREV") then
        AtlasLootPvPButton_OnClick(this.lootpage);
    end
end

function AtlasLootRepButton_OnClick(setid, text)
    for i = 1, 30, 1 do
        getglobal("AtlasLootMenuItem_"..i):Hide();
    end
    getglobal("AtlasLootItemsFrame_NEXT"):Hide();
    getglobal("AtlasLootItemsFrame_PREV"):Hide();
    if (setid=="Darkmoon" or setid=="Timbermaw" or setid=="Sporeggar1" or setid=="Kurenai1" or setid=="KeepersofTime1") then
        AtlasLoot_ShowBossLoot(setid, text, AtlasLoot_AnchorFrame);
    elseif (setid=="Tranquillien1" or setid=="Maghar1" or setid=="Wintersaber1" or setid=="Stormpike1" or setid=="Frostwolf1" or setid=="VioletEye1") then
        AtlasLoot_ShowBossLoot(setid, text, AtlasLoot_AnchorFrame);
    elseif (setid=="AQBroodRings") then
        AtlasLoot_ShowBossLoot(setid, ATLASLOOT_FACTION_BROOD, AtlasLoot_AnchorFrame);
    else
        AtlasLoot_Rep(setid, text);
    end
end]]
