About 15 years ago I got a demo at a Gartner conference from a company doing just that. The vendor's primary goal, they said, was to measure where the developer was spending his time (coding vs debugger vs editor... I think it was a Visual Studio add-in?). But they admitted employers could use it to track what the developer was/wasn't doing.
...and that was before Facebook.
The solution is really to use communication tools like Slack and also put the focus on deliverables instead of "work units".
If someone is in front of you banging on their keyboard, you need not have any assurance that they're doing work, either.