Correlation of alkali metal-induced work function changes on semiconductor and metal surfaces