Fix or remove calls deprecated in 1.25

Change-Id: I352ec380cadf0933e17b56e8a321ef8d692c8cef
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/854
Merge "Fix or remove calls deprecated in 1.25"