Since when has "the press" meant the news media?

According to etymonline, the press in the sense of media is from 1921. This usage was gradually replaced by media with the advent of television:

  • Specific sense "machine for printing" is from 1530s; this was extended to publishing houses by 1570s and to publishing generally (in phrases like freedom of the press) from c. 1680. This gradually shifted c. 1800-1820 to "periodical publishing, journalism." The press, meaning "journalists collectively" is attested from 1921 (though superseded by media since the rise of television, etc.)

Wikionary cites the following 1918 usage:

1918, W. B. Maxwell, chapter 22, in The Mirror and the Lamp:

  • From another point of view, it was a place without a soul. The well-to-do had hearts of stone; the rich were brutally bumptious; the Press, the Municipality, all the public men, were ridiculously, vaingloriously self-satisfied.