Fixed a bug in SHButton

Fixed a bug when creating the button from code