#ifdef __PRIVATE__
//#
//#	File:		Facet.idl
//#
//#	Contains:	SOM class definition for ODFacet
//#
//#	Written by:	Joshua Susser
//#
//#	Copyright:	c 1994 by Apple Computer, Inc., all rights reserved.
//#
//#	Change History (most recent first):
//#
//#		 <8>	10/18/94	JBS		1174640: added fIsUpdating field
//#		 <7>	 8/16/94	JBS		1180387: add CreateCanvas()
//#		 <6>	 8/15/94	JBS		1180387: added Imaging factory methods
//#		 <5>	 8/12/94	JBS		1179920: move fWindow from Facet to Frame
//#		 <4>	 8/10/94	JBS		1179919: coordinate system bias changes
//#		 <3>	 6/22/94	JBS		add functionprefix
//#		 <2>	  6/8/94	NP		Restore lost changes.
//#		 <6>	  6/7/94	RR		Privatise change log
//#		 <5>	 5/23/94	RR		ChangeGeometry replaces ChangeClipShape and
//#									ChangeExternalTransform
//#
//#	To Do:
//#
#else
//#	Copyright:	c 1993-1994 by Apple Computer, Inc., all rights reserved.
#endif

#ifndef _FACET_
#define _FACET_

#ifndef _FACETB_
#include "FacetB.idl"
#endif

//=====================================================================================
// Classes defined in this interface
//=====================================================================================

interface  ODFacet;

//=====================================================================================
// Classes used by this interface
//=====================================================================================

interface  ODCanvas;
interface  ODDragItemIterator;
interface  ODFacet;
interface  ODFacetIterator;
interface  ODFrame;
interface  ODShape;
interface  ODTransform;
interface  ODWindow;

//=====================================================================================
// Implementation Types
//=====================================================================================

#ifdef __PRIVATE__
typedef somToken FacetNode;
#endif

//=====================================================================================
// ODFacet
//=====================================================================================

interface ODFacet :  ODBaseFacet
{

	void InitFacet(in ODFrame frame,
				   in ODShape clipShape,
				   in ODTransform externalTransform,
				   in ODCanvas canvas,
				   in ODCanvas biasCanvas);

#ifdef __PRIVATE__

	void InitChildFacet(in FacetNode* node,
				  		in ODFrame frame,
				  		in ODShape clipShape,
				  		in ODTransform externalTransform,
				  		in ODCanvas canvas,
				  		in ODCanvas biasCanvas);

	FacetNode* GetNode();

	ODBoolean NeedsUpdate();

	void SetNeedsUpdate(in ODBoolean needsUpdate);

#endif

#ifdef __SOMIDL__
  implementation
  {
    functionprefix = ODFacet;
	
    override:
    	somInit,
    	somUninit,
        Purge,

        GetFrame,
        CreateEmbeddedFacet,
        RemoveFacet,
        MoveBefore,
        MoveBehind,
        GetContainingFacet,
        CreateFacetIterator,
		CreateShape,
        GetClipShape,
        ChangeGeometry,
        GetAggregateClipShape,
        GetWindowAggregateClipShape,
        InvalidateAggregateClipShape,
        GetActiveShape,
        ChangeActiveShape,
		CreateTransform,
        GetExternalTransform,
        InternalTransformChanged,
        GetFrameTransform,
        GetContentTransform,
        GetWindowFrameTransform,
        GetWindowContentTransform,
        InvalidateAggregateTransforms,
		CreateCanvas,
        HasCanvas,
        GetCanvas,
        SetCanvas,
        GetWindow,
        GetPartInfo,
        SetPartInfo,
        DragEnter,
        DragWithin,
        DragLeave,
        Drop,
        Update,
        Invalidate,
        Validate,
        Draw,
        DrawChildren,
        DrawChildrenAlways,
        DrawnIn,
        InvalidateActiveBorder,
        DrawActiveBorder,
        MouseEnter,
        MouseWithin,
        MouseLeave,
        ContainsPoint,
        ActiveBorderContainsPoint,
        IsSelected,
        SetSelected,
        GetHighlight,
        ChangeHighlight;
	releaseorder:
		InitFacet,
	#ifdef __PRIVATE__
		InitChildFacet,
        GetNode,
        NeedsUpdate,
        SetNeedsUpdate;
	#else
		reserved1,
		reserved2,
		reserved3;
	#endif

	majorversion = 1; minorversion = 0;

    #ifdef __PRIVATE__
	passthru C_xh = "
	""
	"class FacetNode;"
	"";
      ODFrame     	fFrame;
      ODShape     	fClipShape;
      ODShape     	fActiveShape;
      ODTransform   fExternalTransform;
      ODCanvas     	fCanvas;
      ODInfoType    fPartInfo;
      ODBoolean    	fIsSelected;
      ODHighlight  	fHighlight;
      FacetNode*    fNode;
      ODBoolean    	fNeedsUpdate;
      ODBoolean    	fIsUpdating;
      ODShape     	fAggregateClipShape;
      ODShape     	fWindowAggregateClipShape;
      ODTransform   fFrameTransform;
      ODTransform   fContentTransform;
      ODTransform   fWindowFrameTransform;
      ODTransform   fWindowContentTransform;
    #endif

  };
#endif
};

#endif //# _FACET_
