Indeed, that is precisely what has been discovered. In a series of groundbreaking scientific papers starting in 2002, Veizer, Shaviv, Carslaw, and most recently Svensmark et al., have collectively demonstrated that as the output of the sun varies, and with it, our star's protective solar wind, varying amounts of galactic cosmic rays from deep space are able to enter our solar system and penetrate the Earth's atmosphere. These cosmic rays enhance cloud formation which, overall, has a cooling effect on the planet. When the sun's energy output is greater, not only does the Earth warm slightly due to direct solar heating, but the stronger solar wind generated during these "high sun" periods blocks many of the cosmic rays from entering our atmosphere. Cloud cover decreases and the Earth warms still more.
The opposite occurs when the sun is less bright. More cosmic rays are able to get through to Earth's atmosphere, more clouds form, and the planet cools more than would otherwise be the case due to direct solar effects alone. This is precisely what happened from the middle of the 17th century into the early 18th century, when the solar energy input to our atmosphere, as indicated by the number of sunspots, was at a minimum and the planet was stuck in the Little Ice Age. These new findings suggest that changes in the output of the sun caused the most recent climate change. By comparison, CO2 variations show little correlation with our planet's climate on long, medium and even short time scales.
...Solar scientists predict that, by 2020, the sun will be starting into its weakest Schwabe solar cycle of the past two centuries, likely leading to unusually cool conditions on Earth. Beginning to plan for adaptation to such a cool period, one which may continue well beyond one 11-year cycle, as did the Little Ice Age, should be a priority for governments. It is global cooling, not warming, that is the major climate threat to the world, especially Canada. As a country at the northern limit to agriculture in the world, it would take very little cooling to destroy much of our food crops, while a warming would only require that we adopt farming techniques practiced to the south of us.