Revise tst_applicationwindow

Use more reliable/applicable waitForRendering(item) instead of wait(0)
and make the window visible before testing content item geometry.

Task-number: QTBUG-36938
Change-Id: I414749019d1fca01c09ab3361c0355d231b2bcb3
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>