bundles/org.eclipse.orion.client.editor/web/orion/editor/annotations.js
function(textModel) {
			if (this._model) {
				this._model.removeEventListener("Changed", this._listener.onChanged); //$NON-NLS-0$
			}
			this._model = textModel;
			if (this._model) {
				this._model.addEventListener("Changed", this._listener.onChanged); //$NON-NLS-0$
			}
		}
function(textModel) {
			if (this._model) {
				this._model.removeEventListener("Changed", this._listener.onChanged); //$NON-NLS-0$
			}
			this._model = textModel;
			if (this._model) {
				this._model.addEventListener("Changed", this._listener.onChanged); //$NON-NLS-0$
			}
		}
function ( textModel ) { if ( this . _model ) { this . _model . removeEventListener ( "Changed" , this . _listener . onChanged ) ; //$NON-NLS-0$ } this . _model = textModel ; if ( this . _model ) { this . _model . addEventListener ( "Changed" , this . _listener . onChanged ) ; //$NON-NLS-0$ } }
Sets the text model of the annotation model.  The annotation
model listens for changes in the text model to update and remove
annotations that are affected by the change.

@param {orion.editor.TextModel} textModel the text model.

@see orion.editor.AnnotationModel#getTextModel
Sets the text model of the annotation model . The annotation model listens for changes in the text model to update and remove annotations that are affected by the change .