www.gusucode.com > mbcguitools 工具箱 matlab 源码程序 > mbcguitools/@mbcmultiview/@MultiViewPanel/getSelectedViewTypeIndex.m

    function idx = getSelectedViewTypeIndex(obj)
%GETSELECTEDVIEWTYPEINDEX Get the index of the type of the selected view
%
%  IDX = GETSELECTEDVIEWTYPEINDEX(OBJ) returns the index into the current
%  ViewList of the currently selected view.

%  Copyright 2005 The MathWorks, Inc. and Ford Global Technologies, Inc.


hVC = obj.getSelectedViewContainer;
data = hVC.MVP_Data;
lbl = data.ConstructorLabel;
idx = obj.ViewList.findViewLabel(lbl);