diff mercurial/ui.py @ 31113:268caf97c38f

color: move the dict with terminfo parameters on the ui object This dictionnary is affected by the content of the config, so we should have one for each ui config. We rename the global dict to '_baseterminfoparams' to make the situation clearer.
author Pierre-Yves David <pierre-yves.david@ens-lyon.org>
date Sat, 25 Feb 2017 15:00:51 +0100
parents 3f8f53190d6a
children 1613c55ad3d6
line wrap: on
line diff
--- a/mercurial/ui.py	Sat Feb 25 15:00:44 2017 +0100
+++ b/mercurial/ui.py	Sat Feb 25 15:00:51 2017 +0100
@@ -157,6 +157,7 @@
         self.logblockedtimes = False
         # color mode: see mercurial/color.py for possible value
         self._colormode = None
+        self._terminfoparams = {}
 
         if src:
             self.fout = src.fout
@@ -174,6 +175,7 @@
             self.callhooks = src.callhooks
             self.insecureconnections = src.insecureconnections
             self._colormode = src._colormode
+            self._terminfoparams = src._terminfoparams.copy()
 
             self.fixconfig()