fixed a bug in button demo