(clientData, eventPtr)
| 699 | * None. |
| 700 | * |
| 701 | * Side effects: |
| 702 | * When the window gets deleted, internal structures get |
| 703 | * cleaned up. When it gets exposed, it is redisplayed. |
| 704 | * |
| 705 | *-------------------------------------------------------------- |
| 706 | */ |
| 707 | |
| 708 | static void |
| 709 | MessageEventProc(clientData, eventPtr) |
| 710 | ClientData clientData; /* Information about window. */ |
| 711 | XEvent *eventPtr; /* Information about event. */ |
| 712 | { |
| 713 | Message *msgPtr = (Message *) clientData; |
| 714 | |
| 715 | if ((eventPtr->type == Expose) && (eventPtr->xexpose.count == 0)) { |
| 716 | if ((msgPtr->tkwin != NULL) && !(msgPtr->flags & REDRAW_PENDING)) { |
| 717 | Tk_DoWhenIdle(DisplayMessage, (ClientData) msgPtr); |
| 718 | msgPtr->flags |= REDRAW_PENDING; |
| 719 | } |
| 720 | } else if (eventPtr->type == DestroyNotify) { |
| 721 | Tcl_DeleteCommand(msgPtr->interp, Tk_PathName(msgPtr->tkwin)); |
| 722 | msgPtr->tkwin = NULL; |
| 723 | if (msgPtr->flags & REDRAW_PENDING) { |
| 724 | Tk_CancelIdleCall(DisplayMessage, (ClientData) msgPtr); |
nothing calls this directly
no test coverage detected