From 45ecfbe3630a17cab3d70e078362517dadbc8ff4 Mon Sep 17 00:00:00 2001 From: Matthew Einhorn Date: Sun, 28 Apr 2013 13:44:11 -0400 Subject: [PATCH] Don't freeze when openning a modal view twice. --- kivy/uix/modalview.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kivy/uix/modalview.py b/kivy/uix/modalview.py index fc5efb5bc..8e0ad91c8 100644 --- a/kivy/uix/modalview.py +++ b/kivy/uix/modalview.py @@ -166,6 +166,9 @@ class ModalView(AnchorLayout): window, the view will attach to the global :class:`~kivy.core.window.Window`. ''' + if self._window is not None: + Logger.warning('ModalView: you can only open once.') + return self # search window self._window = self._search_window() if not self._window: