Design notes

Context-sensitive components

The links represented by this subsystem have two different modes of behavior. When the links are embedded in the WebRunner Sample, they open "in-place" by commanding this program. When the links are embedded in another location, they behave differently, by opening a new document "out-of-place."

This sensitivity is achieved by careful handling of the parent document's TModelReference. When this program creates a component to embed, it stores a reference to itself in the link, but when the link is streamed or copied, it does not maintain this reference. This ensures that if the component is dragged or copied to a new location, it no longer thinks it is embedded in a valid WebRunner Sample program.

TWebLink isn't a model

To reduce code, TWebLink isn't designed as a model. It is written with streaming operators to provide persistent semantics--it isn't necessary to implement all model details that are used within a document component because it is possible to leverage off the Atomic Model enabler.


[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker