Skip to content

Commit 5a7ebe7

Browse files
mattalxndrvasily-v-ryabov
authored andcommitted
Fix Issue 233: Rename add_extension_error method
1 parent c87624d commit 5a7ebe7

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

‎Xlib/display.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,8 +340,8 @@ def extension_add_subevent(self, code, subcode, evt, name = None):
340340
# extension dict maintained in the display object
341341
setattr(self.extension_event, name, (code,subcode))
342342

343-
def add_extension_error(self, code, err):
344-
"""add_extension_error(code, err)
343+
def extension_add_error(self, code, err):
344+
"""extension_add_error(code, err)
345345
346346
Add an extension error. CODE is the numeric code, and ERR is
347347
the error class.

‎Xlib/ext/damage.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,4 +179,4 @@ def init(disp, info):
179179

180180
disp.extension_add_event(info.first_event + DamageNotifyCode, DamageNotify)
181181

182-
disp.add_extension_error(code=BadDamageCode, err=BadDamageError)
182+
disp.extension_add_error(code=BadDamageCode, err=BadDamageError)

‎test/test_xlib_display.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ def test_cannot_add_existing_font_method(self):
8787
self.assertRaises(AssertionError, self.display.extension_add_method, "font", "__init__", lambda x: x)
8888

8989
def test_can_add_extension_error(self):
90-
self.display.add_extension_error(1, Xlib.error.XError)
90+
self.display.extension_add_error(1, Xlib.error.XError)
9191
self.assertEqual(self.display.display.error_classes[1], Xlib.error.XError)
9292

9393
def test_keycode_to_keysym_for_invalid_index(self):

0 commit comments

Comments
 (0)