Backport PR #5493: made a minor fix to one of the widget examples
Merge pull request #5520 from jdfreder/2.x

Backport PR #5493: made a minor fix to one of the widget examples