Updated sample-code with swipe test changes
Merge pull request #3970 from 0x1mason/swipe_fix_sample_code

Updated sample-code with swipe test changes