This is a static copy of a profile report

Home

findToolbarModeButtonsById (Calls: 16, Time: 0.024 s)
Generated 16-Jul-2020 17:09:23 using performance time.
function in file /Applications/MATLAB_R2020a.app/toolbox/matlab/uitools/+matlab/+ui/+internal/findToolbarModeButtonsById.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
uigettoolfunction16
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
17
if isequal(get(toolbarChildren...
1600.010 s43.1%
15
if ishandle(toolbarChildren(i)...
1600.007 s28.9%
16
toolid = getappdata(toolbarChi...
1600.004 s18.9%
18
out = [out; toolbarChildren(i)...
160.001 s3.7%
11
for i=1:length(toolbarChildren...
160.000 s2.0%
All other lines  0.001 s3.3%
Totals  0.024 s100% 
Children (called functions)
No children
Code Analyzer results
No Code Analyzer messages.
Coverage results
Show coverage for parent directory
Total lines in function21
Non-code lines (comments, blank lines)12
Code lines (lines that can run)9
Code lines that did run9
Code lines that did not run0
Coverage (did run/can run)100.00 %
Function listing
time 
Calls 
 line
   1 
function out = findToolbarModeButtonsById(toolbarChildren,id)
   2 
% This function is undocumented and will change in a future release
   3 

   4 
% Returns objects where the tag or toolid appdata matches the specified id. 
   5 
% This is used by uigettool and implementations of uimodes to find mode toolbar
   6 
% buttons in standard figure or in GUIDE
   7 

   8 
%   Copyright 2019 The MathWorks, Inc.
   9 

< 0.001 
     16 
  10
out = []; 
< 0.001 
     16 
  11
for i=1:length(toolbarChildren) 
  12 
    % getappdata expects a handle object. Some object in the cameratoolbar
  13 
    % are not handle objects so when it is visible, and rotate is activated,
  14 
    % this will error g2054396
  0.007 
    160 
  15
    if ishandle(toolbarChildren(i)) 
  0.004 
    160 
  16
        toolid = getappdata(toolbarChildren(i),'toolid'); 
  0.010 
    160 
  17
        if isequal(get(toolbarChildren(i),'Tag'), id) || isequal(toolid, id) 
< 0.001 
     16 
  18
            out = [out; toolbarChildren(i)]; %#ok<AGROW> 
< 0.001 
    160 
  19
        end 
< 0.001 
    160 
  20
    end 
< 0.001 
    160 
  21
end