According to Teamviewer’s community blog, Teamviewer has added support to Wayland recently. Due to security reasons, whenever we want to remote our computer or share our screen with someone, we have to permit TeamViewer manually. In my opinion, it is pretty annoying. To disable Wayland and switch back to Xorg on Ubuntu 22.04, just type
sudo sed -i 's/#WaylandEnable=false/WaylandEnable=false/' /etc/gdm3/custom.conf
Another way is to modify the /etc/gdm3/custom.conf by
sudo nano /etc/gdm3/custom.conf
and then change
Press Ctrl + X to save the file.
Restart your computer to take effect.
If you do not want to restart your computer, restart GDM3 to take effect.
sudo systemctl restart gdm3