Update the code samples and clean up the sample ViewController slightly.