Also switched to using surfaceObserver and cleaned up some trailing whitespace. Change-Id: If9a2b390e86f54b4c5ddfd499eefb31f0ab2c96f