www.gusucode.com > mbcview 工具箱matlab源码程序 > mbcview/@cgsurfview/@surfaceoptions/connectToLineOptions.m

    function connectToLineOptions(obj,opts)
%CONNECTTOLINEOPTIONS Creates a two way connection to a lineoptions object
%
% obj.connectToLineOptions(lineopts)
%
% For the purposes of sharing the "Common Y/Z-Range" property, a two-way
% connection between the two objects is set up.  When the options are
% changed, the notifyListeners method of BOTH objects are called.

%  Copyright 2000-2007 The MathWorks, Inc. and Ford Global Technologies, Inc.


if ~isempty(opts) && ~isa(opts,'cgsurfview.lineoptions')
    error(message('mbc:cgsurfview:surfaceoptions:InvalidArgument'));
end
obj.hLineOptions = opts;
obj.hLineOptions.hSurfaceOptions = obj;