Make preview view only work with uri