For compatibility with the middle-click clipboard in Unix/Linux, it's better to do:

    QApplication::clipboard()->setText(..., QClipboard::Clipboard)
    QApplication::clipboard()->setText(..., QClipboard::Selection)

To prevent blowing up this code it might be better to add a function to GUIUtil to do both in one go.