I’ve been using Vivaldi for awhile and decided to switch back to Brave. I installed Brave via flatpak and opened Default Applications and chose Brave. However, if I click on the Web Browser icon I get the following error:
You can work around it by creating one manually /usr/share/application named brave.dsktop.
$ cat /usr/share/applications/brave.desktop
[Desktop Entry]
Version=1.0
Name=Google Chrome
GenericName=Web Browser
Comment=Access the Internet
StartupWMClass=Google-chrome
Exec=/usr/bin/flatpak run com.brave.Browser %u
StartupNotify=true
Terminal=false
Icon=google-chrome
Type=Application
Categories=Network;WebBrowser;
MimeType=application/pdf;application/rdf+xml;application/rss+xml;application/xhtml+xml;application/xhtml_xml;application/xml;image/gif;image/jpeg;image/png;image/webp;text/html;text/xml;x-scheme-handler/http;x-scheme-handler/https;
Actions=new-window;new-private-window;
[Desktop Action new-window]
Name=New Window
StartupWMClass=Google-chrome
Exec=/usr/bin/flatpak run com.brave.Browser
[Desktop Action new-private-window]
Name=New Incognito Window
StartupWMClass=Google-chrome
Exec=/usr/bin/flatpak run com.brave.Browser --incognito
Then set the default browser - which is done using below commands - where $1 is your browser’s launcher e.g. firefox.desktop or in your case you newly created brave.desktop