ui: Check for !pixmap() before trying to export QR code

Adds null pointer checks as well as prevents the Save/Copy context
menu from appearing at all if no image is shown.

Fixes issue #4140
Merge pull request #4141

9d558e1 ui: Check for !pixmap() before trying to export QR code (Wladimir J. van der Laan)