diff options
| author | jacob1 <jfu614@gmail.com> | 2013-01-10 17:02:54 (GMT) |
|---|---|---|
| committer | jacob1 <jfu614@gmail.com> | 2013-01-10 17:02:54 (GMT) |
| commit | f814d264b24bdddee2e2eeeae9bec42978615c94 (patch) | |
| tree | bf95aa1d246a1d1e9f096d0b0d933a2f13fb53b5 /src/interface/Panel.cpp | |
| parent | 17302f03c79287be3e987b53a6008c8bf81881d3 (diff) | |
| download | powder-f814d264b24bdddee2e2eeeae9bec42978615c94.zip powder-f814d264b24bdddee2e2eeeae9bec42978615c94.tar.gz | |
defocus components removed from scrollpanels, to prevent crashes
Diffstat (limited to 'src/interface/Panel.cpp')
| -rw-r--r-- | src/interface/Panel.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/interface/Panel.cpp b/src/interface/Panel.cpp index d673037..b78a2cc 100644 --- a/src/interface/Panel.cpp +++ b/src/interface/Panel.cpp @@ -82,6 +82,8 @@ void Panel::RemoveChild(Component* c) { //remove child from parent. Does not free memory children.erase(children.begin() + i); + if (this->GetParentWindow()->IsFocused(c)) + this->GetParentWindow()->FocusComponent(NULL); break; } } |
