fix leak upon theme changes

Change-Id: I1a4931710b6c1f5ff115bda4cedfa0f505108d65