added click handlers to show all flags and clear all flags