What is the meaning of うい?

sad, gloomy

fine (person), good, nice, splendid, admirable (referring to someone of lower status)

Source: wiktionary.org