bvqxfigurecallback.m

来自「toolbox of BVQX, This is the access betw」· M 代码 · 共 40 行

M
40
字号
function BVQXfigureCallback(cbstr, fig, cbo, setparent)
% BVQXfigure::docallback  - make sure a callback has its own workspace
%
% Since this callback is only for internal use of the BVQXfigure class
% it must not be used directly!
%
% See also @BVQXfigure

% Version:      v0.7b
% Build:        7090411
% Date:         Sep-04 2007, 11:05 AM CEST
% Author:       Jochen Weber, Brain Innovation, B.V., Maastricht, NL
% URL / Info:   http://wiki.brainvoyager.com/BVQXtools

% set references
try
    this = BVQXfigure(cbo);
    if ~isBVQXfigure(this, true)
        error('INVALID_HANDLE');
    end
    gcf  = fig;
    gcbf = fig;
    gcbo = cbo;
    
    % set parent?
    if nargin > 3 && ...
       ~isempty(setparent)
        parent = BVQXfigure(get(gcbo, 'Parent'));
        thisfig = BVQXfigure(gcf);
    end

    % evaluate callback
    eval(cbstr);
catch
    warning( ...
        'BVQXfigure:BadHandle', ...
        'Callback of handle failed.' ...
    );
end

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?