function osDS()
	local active = GetActiveSpecGroup()
	if active == 2 then
		SetActiveSpecGroup(1);
	elseif active == 1 then
		SetActiveSpecGroup(2);
	else
	end
end

SLASH_DS1 = "/ds";
SLASH_DS2 = "/dualspec";
SlashCmdList["DS"] = osDS

local s1 = string.gsub(ERR_LEARN_ABILITY_S:gsub('%.', '%.'), '%%s', '(.*)')
local s2 = string.gsub(ERR_LEARN_SPELL_S:gsub('%.', '%.'), '%%s', '(.*)')
local s3 = string.gsub(ERR_SPELL_UNLEARNED_S:gsub('%.', '%.'), '%%s', '(.*)')
local s4 = string.gsub(ERR_LEARN_PASSIVE_S:gsub('%.', '%.'), '%%s', '(.*)')

local OSDS1 = GetSpellInfo(63645)
local OSDS2 = GetSpellInfo(63644)

OSDS = CreateFrame("Frame");
OSDS:RegisterEvent("ACTIVE_TALENT_GROUP_CHANGED");
OSDS:RegisterEvent("UNIT_SPELLCAST_START");
OSDS:RegisterEvent("UNIT_SPELLCAST_STOP");
OSDS:RegisterEvent("UNIT_SPELLCAST_INTERRUPTED");

OSDS.filter = function(self, event, msg, ...)
	if strfind(msg, s1) then
		return true
	elseif strfind(msg, s2) then
		return true
	elseif strfind(msg, s3) then
		return true
	elseif strfind(msg, s4) then
		return true
	end
	return false, msg, ...
end

OSDS:SetScript("OnEvent", function( self, event, ...)

	local unit, spellName = ...

	if(event == "UNIT_SPELLCAST_START") then
		if unit == "player" and (spellName == OSDS1 or spellName == OSDS2) then
			ChatFrame_AddMessageEventFilter("CHAT_MSG_SYSTEM", self.filter)
		end	
	elseif(event == "UNIT_SPELLCAST_STOP") or (event == "UNIT_SPELLCAST_INTERRUPTED") then
		if unit == "player" and (spellName == OSDS1 or spellName == OSDS2) then
			ChatFrame_RemoveMessageEventFilter("CHAT_MSG_SYSTEM", self.filter)
		end	
	elseif(event == "ACTIVE_TALENT_GROUP_CHANGED") then
		
	end
end);
