Replace dict.has_key(x) with x in dict for performance gain

svn: r10874
This commit is contained in:
Gerald Britton
2008-07-17 18:10:32 +00:00
parent a6a264d1ce
commit 882199f1c2
80 changed files with 188 additions and 188 deletions

View File

@@ -459,7 +459,7 @@ class StyledTextBuffer(gtk.TextBuffer):
iter = self.get_iter_at_offset(pos)
for tag in iter.get_tags():
name = tag.get_property('name')
if tagdict.has_key(name):
if name in tagdict:
if tagdict[name][-1][1] == pos - 1:
tagdict[name][-1] = (tagdict[name][-1][0], pos)
else: