Mercurial > hg > aimmat
view aim-mat/gui/aim_getcurrent_module.m @ 0:74dedb26614d
Initial checkin of AIM-MAT version 1.5 (6.4.2011).
author | tomwalters |
---|---|
date | Fri, 20 May 2011 12:32:31 +0100 |
parents | |
children | 20ada0af3d7d |
line wrap: on
line source
% procedure for 'aim-mat' % % INPUT VALUES: % column number % RETURN VALUE: % % % helping function, that gives back the current selected module for a given % column number % % (c) 2011, University of Southampton % Maintained and written by Stefan Bleeck (bleec@gmail.com) % http://www.soton.ac.uk/aim function [generating_module,generating_function,coptions]=aim_getcurrent_module(handles,columnnr) switch columnnr case 2 options=handles.all_options.pcp; generating_module=handles.info.current_pcp_module; % this one is selected by the user handles.info.calculated_pcp_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.pcp',generating_module); eval(optline); case 3 options=handles.all_options.bmm; generating_module=handles.info.current_bmm_module; handles.info.calculated_bmm_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.bmm',generating_module); eval(optline); case 4 options=handles.all_options.nap; generating_module=handles.info.current_nap_module; handles.info.calculated_nap_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.nap',generating_module); eval(optline); case 5 options=handles.all_options.strobes; generating_module=handles.info.current_strobes_module; handles.info.calculated_strobes_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.strobes',generating_module); eval(optline); case 6 options=handles.all_options.sai; generating_module=handles.info.current_sai_module; handles.info.calculated_sai_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.sai',generating_module); eval(optline); case 7 options=handles.all_options.usermodule; generating_module=handles.info.current_usermodule_module; handles.info.calculated_usermodule_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.usermodule',generating_module); eval(optline); case 8 options=handles.all_options.movie; generating_module=handles.info.current_movie_module; handles.info.calculated_movie_module=generating_module; % this one is really calculated generating_functionline=['options.' generating_module '.generatingfunction']; eval(sprintf('generating_function=%s;',generating_functionline')); optline=sprintf('coptions=%s.%s;','handles.all_options.movie',generating_module); eval(optline); end