I have been using VI and VIM for years (30 or more) (in xterms, not its own window, gvim) and I have a huge library of vim commands that I give vim using the mouse middle button as a selection.
For example I would often do things like...
paste vim commands using mouse - one paste per file.
The selection would include lots of VIM commands to do things things like replacing test, formatting, move lines around, etc., etc., etc., and typically ends with :w and :next VIM commands, at the end of the selection, so vim is ready for me to paste again into the next file. This lets me update huge numbers of files in VERY complex ways, without needing special scripts (such as perl in-place editing) to do it.
Some of these vim command pastes are 200+ lines long (stored in text files I pop-up on screen, and 'copy-all'! These make a LOT of changes to the set of thousands of files I am re-formatting. But only for the specific set of files, not for my day-to-day vim work. EG: Bulk re-formating for text/data files.
During my last system patch (Fedora 25) vim now pastes the mouse selection AS TEXT and not as vim commands, and I can't seem to stop it!
It still works fine on another system (Fedora 24).
If I want to paste as text, I enter insert mode before pasting! I don't want VIM automatically pasting selections AS text when it is not in insert mode. I understand this was meant as a security feature, but to me it is a MAJOR usability issue.
I have tried back dating terminfo entries (xterm-256color) from a machine that does not do this (especially the "kmous" terminfo entry). I have also looked at the vim ":set mouse=" setting (which is null!). I do not know if it is the xterm (doubtful), or something that changed in VIM (likely), and change logs and google have been unhelpful.
Nothing however seems to get me the old behaviour.