Paste logic moved to core
Correct dialog shown in case of wrong format.