Agent-Logs-Url: https://github.com/kk14222/3D_EDFM_SIM-X/sessions/a128ab7f-6b94-4048-a847-f2dc37bbe0ab Co-authored-by: kk14222 <217880052+kk14222@users.noreply.github.com>
34 lines
1.0 KiB
Matlab
34 lines
1.0 KiB
Matlab
classdef EDFMGuideApp < dynamicprops
|
|
%EDFMGUIDEAPP App-like container used by the GUIDE implementation.
|
|
|
|
properties
|
|
Controller EDFMAppController
|
|
end
|
|
|
|
methods
|
|
function obj = EDFMGuideApp(handles)
|
|
names = fieldnames(handles);
|
|
for i = 1:numel(names)
|
|
name = names{i};
|
|
if isprop(obj, name)
|
|
obj.(name) = obj.wrapHandle(name, handles.(name));
|
|
else
|
|
addprop(obj, name);
|
|
obj.(name) = obj.wrapHandle(name, handles.(name));
|
|
end
|
|
end
|
|
end
|
|
end
|
|
|
|
methods (Access = private)
|
|
function value = wrapHandle(~, name, handleObj)
|
|
if strcmp(name, 'UIFigure') || isa(handleObj, 'matlab.ui.container.TabGroup') || ...
|
|
isa(handleObj, 'matlab.ui.container.Tab') || isa(handleObj, 'matlab.graphics.axis.Axes')
|
|
value = handleObj;
|
|
else
|
|
value = EDFMGuideComponent(handleObj);
|
|
end
|
|
end
|
|
end
|
|
end
|