Fixing canvas resize