Bugfix/issue 368

Fix issue #368 where opening a screen twice from the same parent would cause a crash.
One actual line of real code; the rest is tests. :)