use delete-region to remove empty lines.

Author:yangyingchao, 2013-03-15