patch 8.2.3628: looking terminal colors is a bit slow

Problem:    Looking terminal colors is a bit slow.
Solution:   Cache the terminal colors. (closes #9130, closes #9058)
diff --git a/src/popupwin.c b/src/popupwin.c
index 2c903bc..d5f8d26 100644
--- a/src/popupwin.c
+++ b/src/popupwin.c
@@ -732,8 +732,13 @@
 
     str = dict_get_string(dict, (char_u *)"highlight", FALSE);
     if (str != NULL)
+    {
 	set_string_option_direct_in_win(wp, (char_u *)"wincolor", -1,
 						   str, OPT_FREE|OPT_LOCAL, 0);
+#ifdef FEAT_TERMINAL
+	term_update_wincolor(wp);
+#endif
+    }
 
     set_padding_border(dict, wp->w_popup_padding, "padding", 999);
     set_padding_border(dict, wp->w_popup_border, "border", 1);