Fixed matchMedia usage to make unit tests work in PhantomJS

PhantomJS has a bug that makes it impossible to properly stub
window.matchMedia. This fix adds a wrapper as OC._matchMedia
that is used for unit tests