fixing the bug of dialoglayer
....