Component methods that accept a callback return a promise

Already mentioned in #2642.
All methods that accept a callback should return a promise if Promises/A+ are supported. Otherwise, they return `undefined` as before.