Skip to content

Commit a2d3e8f

Browse files
committed
Cleaned up some event code
1 parent bb6d5c5 commit a2d3e8f

5 files changed

Lines changed: 32 additions & 21 deletions

File tree

Xlib/ChangeLog

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
2001-01-16 <petli@cendio.se>
2+
3+
* xobject/drawable.py (Window.send_event):
4+
* display.py (Display.send_event): Changed the order of the
5+
event_mask and propagate arguments.
6+
17
2001-01-10 <petli@cendio.se>
28

39
* display.py (Display._update_keymap): The first half of the

Xlib/display.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: display.py,v 1.14 2001-01-11 15:13:05 petli Exp $
1+
# $Id: display.py,v 1.15 2001-01-18 13:11:04 petli Exp $
22
#
33
# Xlib.display -- high level display object
44
#
@@ -343,7 +343,7 @@ def get_selection_owner(self, selection):
343343
selection = selection)
344344
return r.owner
345345

346-
def send_event(self, destination, event, propagate = 0, event_mask = 0,
346+
def send_event(self, destination, event, event_mask = 0, propagate = 0,
347347
onerror = None):
348348

349349
request.SendEvent(display = self.display,

Xlib/protocol/ChangeLog

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
2001-01-16 <petli@cendio.se>
2+
3+
* event.py: Changed some class names so that they correspond
4+
exactly to the event type constants.
5+
16
Tue Jan 9 10:03:25 2001 Peter Liljenberg <petli@cendio.se>
27

38
* display.py (Display.send_request): Fixed a call to append() with

Xlib/protocol/event.py

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: event.py,v 1.3 2000-09-06 01:51:34 petli Exp $
1+
# $Id: event.py,v 1.4 2001-01-18 13:11:05 petli Exp $
22
#
33
# Xlib.protocol.event -- definitions of core events
44
#
@@ -122,7 +122,7 @@ class Expose(rq.Event):
122122
rq.Pad(14),
123123
)
124124

125-
class GraphicsExposure(rq.Event):
125+
class GraphicsExpose(rq.Event):
126126
_code = X.GraphicsExpose
127127
_fields = rq.Struct( rq.Card8('type'),
128128
rq.Pad(1),
@@ -138,7 +138,7 @@ class GraphicsExposure(rq.Event):
138138
rq.Pad(11),
139139
)
140140

141-
class NoExposure(rq.Event):
141+
class NoExpose(rq.Event):
142142
_code = X.NoExpose
143143
_fields = rq.Struct( rq.Card8('type'),
144144
rq.Pad(1),
@@ -149,7 +149,7 @@ class NoExposure(rq.Event):
149149
rq.Pad(21),
150150
)
151151

152-
class Visibility(rq.Event):
152+
class VisibilityNotify(rq.Event):
153153
_code = X.VisibilityNotify
154154
_fields = rq.Struct( rq.Card8('type'),
155155
rq.Pad(1),
@@ -217,7 +217,7 @@ class MapRequest(rq.Event):
217217
rq.Pad(20),
218218
)
219219

220-
class Reparent(rq.Event):
220+
class ReparentNotify(rq.Event):
221221
_code = X.ReparentNotify
222222
_fields = rq.Struct( rq.Card8('type'),
223223
rq.Pad(1),
@@ -265,7 +265,7 @@ class ConfigureRequest(rq.Event):
265265
rq.Pad(4),
266266
)
267267

268-
class Gravity(rq.Event):
268+
class GravityNotify(rq.Event):
269269
_code = X.GravityNotify
270270
_fields = rq.Struct( rq.Card8('type'),
271271
rq.Pad(1),
@@ -288,7 +288,7 @@ class ResizeRequest(rq.Event):
288288
rq.Pad(20),
289289
)
290290

291-
class Circulate(rq.Event):
291+
class CirculateNotify(rq.Event):
292292
_code = X.CirculateNotify
293293
_fields = rq.Struct( rq.Card8('type'),
294294
rq.Pad(1),
@@ -312,7 +312,7 @@ class CirculateRequest(rq.Event):
312312
rq.Pad(15),
313313
)
314314

315-
class Property(rq.Event):
315+
class PropertyNotify(rq.Event):
316316
_code = X.PropertyNotify
317317
_fields = rq.Struct( rq.Card8('type'),
318318
rq.Pad(1),
@@ -362,7 +362,7 @@ class SelectionNotify(rq.Event):
362362
rq.Pad(8),
363363
)
364364

365-
class Colormap(rq.Event):
365+
class ColormapNotify(rq.Event):
366366
_code = X.ColormapNotify
367367
_fields = rq.Struct( rq.Card8('type'),
368368
rq.Pad(1),
@@ -414,26 +414,26 @@ class KeymapNotify(rq.Event):
414414
X.FocusOut: FocusOut,
415415
X.KeymapNotify: KeymapNotify,
416416
X.Expose: Expose,
417-
X.GraphicsExpose: GraphicsExposure,
418-
X.NoExpose: NoExposure,
419-
X.VisibilityNotify: Visibility,
417+
X.GraphicsExpose: GraphicsExpose,
418+
X.NoExpose: NoExpose,
419+
X.VisibilityNotify: VisibilityNotify,
420420
X.CreateNotify: CreateNotify,
421421
X.DestroyNotify: DestroyNotify,
422422
X.UnmapNotify: UnmapNotify,
423423
X.MapNotify: MapNotify,
424424
X.MapRequest: MapRequest,
425-
X.ReparentNotify: Reparent,
425+
X.ReparentNotify: ReparentNotify,
426426
X.ConfigureNotify: ConfigureNotify,
427427
X.ConfigureRequest: ConfigureRequest,
428-
X.GravityNotify: Gravity,
428+
X.GravityNotify: GravityNotify,
429429
X.ResizeRequest: ResizeRequest,
430-
X.CirculateNotify: Circulate,
430+
X.CirculateNotify: CirculateNotify,
431431
X.CirculateRequest: CirculateRequest,
432-
X.PropertyNotify: Property,
432+
X.PropertyNotify: PropertyNotify,
433433
X.SelectionClear: SelectionClear,
434434
X.SelectionRequest: SelectionRequest,
435435
X.SelectionNotify: SelectionNotify,
436-
X.ColormapNotify: Colormap,
436+
X.ColormapNotify: ColormapNotify,
437437
X.ClientMessage: ClientMessage,
438438
X.MappingNotify: MappingNotify,
439439
}

Xlib/xobject/drawable.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: drawable.py,v 1.8 2001-01-06 17:58:06 petli Exp $
1+
# $Id: drawable.py,v 1.9 2001-01-18 13:11:05 petli Exp $
22
#
33
# Xlib.xobject.drawable -- drawable objects (window and pixmap)
44
#
@@ -420,7 +420,7 @@ def convert_selection(self, selection, target, property, time, onerror = None):
420420
property = property,
421421
time = time)
422422

423-
def send_event(self, event, propagate = 0, event_mask = 0, onerror = None):
423+
def send_event(self, event, event_mask = 0, propagate = 0, onerror = None):
424424
request.SendEvent(display = self.display,
425425
onerror = onerror,
426426
propagate = propagate,

0 commit comments

Comments
 (0)