local _, core = ...; -- Namespace

local AceGUI = LibStub("AceGUI-3.0")


function core.JewelcraftingLevellingTBC(container)



--[[
local AzureMoonstone = TSM_API.GetCustomPriceValue("dbmarket","i:23117")*30
local DeepPeridot = TSM_API.GetCustomPriceValue("dbmarket","i:23079")*35
local StarofElune = TSM_API.GetCustomPriceValue("dbmarket","i:23438")*20
local Talasite = TSM_API.GetCustomPriceValue("dbmarket","i:23437")*10


Add1 = AzureMoonstone + DeepPeridot
Add2 = Add1 + StarofElune
Add3 = Add2 + Talasite



local Item = TSM_API.FormatMoneyString(Add3)
--]]




--[[ Scroll Frame ]]--
local scrollcontainer = AceGUI:Create("SimpleGroup") 
scrollcontainer:SetFullWidth(true)
scrollcontainer:SetFullHeight(true) 
scrollcontainer:SetLayout("Fill") 

container:AddChild(scrollcontainer)

local scroll = AceGUI:Create("ScrollFrame")
scroll:SetLayout("Flow") 
scrollcontainer:AddChild(scroll)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)  
  
  --[[ Material List ]]--
  local desc = AceGUI:Create("Label")  
  desc:SetText("|cff00C78CMaterial List:")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)
  
  
  

  local desc = AceGUI:Create("Label")
  desc:SetText("1. Azure Moonstone".." - ".."30")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)

  local desc = AceGUI:Create("Label")
  desc:SetText("2. Deep Peridot".." - ".."35")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
    local desc = AceGUI:Create("Label")
  desc:SetText("3. Star of Elune".." - ".."20")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
    local desc = AceGUI:Create("Label")
  desc:SetText("4. Talasite".." - ".."10")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  

--[[ Estimated Cost ]]-- 

  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space) 

if (IsAddOnLoaded("TradeSkillMaster")) then
local AzureMoonstone = TSM_API.GetCustomPriceValue("dbmarket","i:23117")*30
local DeepPeridot = TSM_API.GetCustomPriceValue("dbmarket","i:23079")*35
local StarofElune = TSM_API.GetCustomPriceValue("dbmarket","i:23438")*20
local Talasite = TSM_API.GetCustomPriceValue("dbmarket","i:23437")*10


Add1 = AzureMoonstone + DeepPeridot
Add2 = Add1 + StarofElune
Add3 = Add2 + Talasite



local Item = TSM_API.FormatMoneyString(Add3)


  local desc = AceGUI:Create("Label")  
  desc:SetText("|cff00C78CEstimated Cost: ".."|cffffffff"..Item)
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
 
  else
  
  		  local desc = AceGUI:Create("Label")
		  desc:SetText("|cffff6060Estimated Cost:".."|cffffffff TradeSkillMaster Not Installed For Estimated Cost")
		  desc:SetFullWidth(true)
		  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
		  scroll:AddChild(desc)
  
  
  
  
end  

 
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)


--[[ Trainer ]]-- 

if (IsAddOnLoaded("TomTom")) then  
  local ShadowlandsWaypoint = AceGUI:Create("Button")
  ShadowlandsWaypoint:SetText("Trainer Waypoint")
  ShadowlandsWaypoint:SetWidth(350)
  scroll:AddChild(ShadowlandsWaypoint)
  ShadowlandsWaypoint:SetCallback("OnClick", function() 

DEFAULT_CHAT_FRAME.editBox:SetText("/way Shattrath City 35.8 20.6") ChatEdit_SendText(DEFAULT_CHAT_FRAME.editBox, 0)
  
  end)

		else
		
		  local desc = AceGUI:Create("Label")
		  desc:SetText("|cffff6060Waypoint:".."|cffffffff TomTom Not Installed For Waypoint")
		  desc:SetFullWidth(true)
		  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
		  scroll:AddChild(desc)
  
  
  
end


--[[ Levelling ]]--
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("|cff00C78CStep 1:".."|cffffffff 1-25")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("25x Jagged Deep Peridot")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)
  
  local desc = AceGUI:Create("Label")
  desc:SetText("|cff00C78CStep 2:".."|cffffffff 25-35")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("10x Regal Deep Peridot")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("|cff00C78CStep 3:".."|cffffffff 35-50")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("30x Rigid Azure Moonstone")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("|cff00C78CStep 4:".."|cffffffff 50 - 60")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("10x Steady Talasite ")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("|cff00C78CStep 5:".."|cffffffff 50 - 75")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)

  local desc = AceGUI:Create("Label")
  desc:SetText("20x Falling Star")
  desc:SetFullWidth(true)
  desc:SetFont("Fonts\\FRIZQT__.TTF", 13, '')
  scroll:AddChild(desc)
  
  local Space = AceGUI:Create("Label")
  Space:SetText("  ")
  Space:SetFullWidth(true)
  scroll:AddChild(Space)  
  
  
  
  
  
  
  
end