fixes "undefined is not an object" exception in af.ui on "exit-edit-resh...

We've got the exception "undefined is not an object in appframework.ui.js:4702" on orientationchange (ios6) with an open modal panel, which has a form and input field. After this small fix everything seems fine