Bug 1035279 - [Messages][Refactoring] Move error codes mapping from dialog.js to a separate file. r=julien

* ErrorDialog moved to a separate file;
* Removed ErrorDialog dependency on Errors mapping;
* Errors mapping moved to a separate file;
* ErrorCodes organized into enums.
I'd silence the error `Do not use 'new' for side effects.` instead. And I'd silence it inside the various functions where I need it, instead of silencing it globally, so that it's closer to the issue and easier to read.