On stock android it's in developer settings (activate by going to settings > about phone and then tapping on the Build Number 7 times) and is called "stay awake" within settings > developer settings. I'd check there or for the TouchWiz equivalent of that. If it's not there, the next place I would check is in settings > display for screen timeout settings.