LayerMsgHandler Class Reference

Intercepts messages to ensure that layers are up to date. More...

#include <layer.h>

Inheritance diagram for LayerMsgHandler:

MessageHandler ListItem CCObject SimpleCCObject List of all members.

Public Member Functions

 LayerMsgHandler ()
 Constructs a LayerMsgHandler, an object which handles messages for layers.

Protected Member Functions

MsgResult Message (Msg *Msg)
 Process messages on behalf of layers.

Detailed Description

Intercepts messages to ensure that layers are up to date.

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
10/10/95

Definition at line 404 of file layer.h.


Constructor & Destructor Documentation

LayerMsgHandler::LayerMsgHandler  ) 
 

Constructs a LayerMsgHandler, an object which handles messages for layers.

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
10/10/95
Returns:
Errors: -
See also:
MessageHandler

Definition at line 3419 of file layer.cpp.


Member Function Documentation

MsgResult LayerMsgHandler::Message Msg Message  )  [protected, virtual]
 

Process messages on behalf of layers.

Author:
Mark_Neves (Xara Group Ltd) <camelotdev@xara.com>
Date:
10/10/95
Parameters:
Message,: The message [INPUTS]

Reimplemented from MessageHandler.

Definition at line 3436 of file layer.cpp.

03437 {
03438 #if !defined(EXCLUDE_FROM_RALPH)
03439     if (MESSAGE_IS_A(Message, ColourChangingMsg))
03440     {
03441         ColourChangingMsg *Msg = (ColourChangingMsg *) Message;
03442         switch ( Msg->State )
03443         {
03444             case ColourChangingMsg::LISTDELETED:
03445             case ColourChangingMsg::LISTDESELECTED:
03446             case ColourChangingMsg::LISTPAGED:
03447             case ColourChangingMsg::LISTUPDATED:
03448                 if (Msg->ScopeDoc != NULL)
03449                 {
03450 PORTNOTE("spread", "Multi-spread warning!")
03451                     Spread* pSpread = Msg->ScopeDoc->FindFirstSpread();
03452                     if (pSpread != NULL)
03453                     {
03454                         Layer* pGuideLayer = pSpread->FindFirstGuideLayer();
03455                         if (pGuideLayer != NULL)
03456                             pGuideLayer->ColourDeleted();
03457                     }
03458                 }               
03459                 break;
03460 
03461             case ColourChangingMsg::COLOURUPDATED:
03462                 if (Msg->ScopeDoc != NULL)
03463                 {
03464 PORTNOTE("spread", "Multi-spread warning!")
03465                     Spread* pSpread = Msg->ScopeDoc->FindFirstSpread();
03466                     if (pSpread != NULL)
03467                     {
03468                         Layer* pGuideLayer = pSpread->FindFirstGuideLayer();
03469                         if (pGuideLayer != NULL)
03470                             pGuideLayer->ColourChanged(Msg->ChangedColour);
03471                     }
03472                 }               
03473                 break;
03474             default:
03475                 break;
03476         }
03477     }
03478 #endif
03479     return OK; 
03480 }


The documentation for this class was generated from the following files:
Generated on Sat Nov 10 03:55:45 2007 for Camelot by  doxygen 1.4.4