diff --git a/src/ui/WebView.cpp b/src/ui/WebView.cpp index 2f066a0..8145d29 100644 --- a/src/ui/WebView.cpp +++ b/src/ui/WebView.cpp @@ -14,6 +14,7 @@ namespace wfl::ui namespace { constexpr auto const WHATSAPP_WEB_URI = "https://web.whatsapp.com"; + constexpr auto const USER_AGENT = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"; std::optional getSystemLanguage() { @@ -186,6 +187,7 @@ namespace wfl::ui } auto const settings = webkit_web_view_get_settings(*this); + webkit_settings_set_user_agent(settings, USER_AGENT); webkit_settings_set_enable_developer_extras(settings, TRUE); auto hwAccelPolicy = static_cast(util::Settings::getInstance().getValue("web", "hw-accel", 1)); webkit_settings_set_hardware_acceleration_policy(settings, hwAccelPolicy);