bugfixed resize