adobe/brackets — pull request #1923 by redmunds (2012-10-23 22:48:05+00:00)
Title: make mode string more presentable

This is for #1826

This fixes exception with many modes such as JSON. Mode can be either a string or an Object with a name property, but it was assumed to be a string.

Handled as a special case: JavaScript, HTML, CSS. Any others we should handle?

For remaining cases, we strip "/" and everything after it, and then capitalize what's left. Most of these are simply "Text".