by Section 15 of the Charter. The courts struck down the common law definition of marriage used under federal law, and held that same-sex couples had the right to marry in those jurisdictions. Trial courts deferred the effect of their rulings, to allow the federal government time to consider whether it would enact legislation or appeal the decisions. However, the Ontario Court of Appeal in its decision held that the new definition came into effect immediately in Ontario. Courts in other provinces and one territory followed that approach, with the result that those Canadian jurisdictions became the third in the world to allow same-sex marriage, after the Netherlands and Belgium. By July 2005, same-sex marriages were legally recognized in all provinces and territories except Alberta, Prince Edward Island, the Northwest Territories and Nunavut, encompassing over 85% of Canada's population. Federal government response The Federal Government announced in the summer of 2003 that it would not appeal the decisions, and would draft legislation to allow same-sex marriages across the country. The bill was put before the Supreme Court of Canada to ensure that it would withstand a Charter challenge by those who oppose same-sex marriage. In December 2004, the Supreme Court declared the proposed definition of "marriage" as being consistent with respect to all matters referred to in the Charter, and as falling within the exclusive legislative authority of the Parliament of Canada. Parliament passed the bill on July 20, 2005, making Canada the fourth country to legalize same-sex marriage nationwide, and the first to do so without a residency requirement. Public opinion One study by Mark W. Lehman suggests that between 1997 and 2004, Canadian public opinion on legalizing same-sex marriage underwent a dramatic shift: moving from minority support to majority support and that this support was the result of a significant shift in positive feelings towards gays and lesbians. Adoption The first province to allow adoption of children by same-sex couples in Canada was British Columbia in 1996. Since then, adoption by same-sex couples has been legalized in Ontario (1999), Nova Scotia (2001), Saskatchewan (2001), Newfoundland and Labrador (2002), Quebec (2002), Manitoba (2002), the Northwest Territories (2002) and Yukon (2003). In Alberta, stepchild adoption was legalized in 1999. Eight years later, in 2007, joint adoption became legal in Alberta. New Brunswick legalized joint adoption in 2008, while Prince Edward Island did so in 2009. Nunavut legalized adoption by same-sex