treat odd resize problem