www.gusucode.com > mbcview 工具箱matlab源码程序 > mbcview/@cgtradeoffgui/@tradeoffInfoBarView/createDefaultWindowContainer.m

    function hPane = createDefaultWindowContainer(obj,PanelHandle)
%CREATEDEFAULTWINDOWCONTAINER Create an appropriate container for the view
%
%  HCONAINER = CREATEDEFAULTWINDOWCONTAINER(OBJ) creates and returns a
%  handle to a ViewContainer that has been set up to contain OBJ.  The
%  container should be appropriate for viewing OBJ in a standard
%  application window.  This object creates a PanelViewContainer.

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


if nargin>1
    % User suplied Panel
    Parent = get(PanelHandle,'Parent');
    OtherArgs = {'PanelHandle',PanelHandle};
else
    % Use the View's parent
    Parent = get(View,'Parent');
    OtherArgs = {};
end

hPane = mbcmultiview.PanelViewContainer( ...
    'Parent', Parent, ...
    'Visible', obj.Visible, ...
    'View', obj,...
    OtherArgs{:});