0
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
1 function g_WindlengthCallback(hObject,varargin)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
2
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
3 global params
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
4
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
5 currParamID = get(hObject,'UserData');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
6 selectedWind = params.params(currParamID).val.type;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
7 currWindLength = str2double(get(hObject,'String'));
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
8
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
9
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
10 if strcmp(selectedWind,'Kaiser')
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
11 windobj = specwin(selectedWind,currWindLength, params.params(currParamID).val.psll);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
12 else
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
13 windobj = specwin(selectedWind,currWindLength);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
14 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
15
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
16 params=pset(params,params.params(currParamID).key,windobj);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
17
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
18 set(findobj('Tag','apply'),'Enable','on');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
19 set(findobj('Tag','undo'),'Enable','on');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
20
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
21 end |