The native window.open system has been better for quite a while now, and it resolves a lot of issues. We should make it the default and deprecate the old `BrowserWindowProxy`-based method.
shell/browser/web_contents_preferences.cc
base::StringPiece path,
                 std::wstring* out) {
  if (val) {
    auto* found = val->FindKeyOfType(path, base::Value::Type::STRING);
    if (found) {
      *out = base::UTF8ToWide(found->GetString());
      return true;
    }
  }
  return false;
}
#endif
bool GetAsInteger(const base::Value* val, base::StringPiece path, int* out) {
  if (val) {
    auto* found = val->FindKey(path);
    if (found && found->is_int()) {
      *out = found->GetInt();
      return true;
    } else if (found && found->is_string()) {
      return base::StringToInt(found->GetString(), out);
    }
  }
  return false;
}
bool GetAsAutoplayPolicy(const base::Value* val,