Changeset 681 for trunk/src/keyboard_callback.m
- Timestamp:
- Sep 2, 2013, 2:42:52 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/keyboard_callback.m
r625 r681 4 4 cur_axes=get(hObject,'CurrentAxes');%current plotting axes of the figure with handle hObject 5 5 xx=double(get(hObject,'CurrentCharacter')); %get the keyboard character 6 if ~isempty(xx) 6 7 switch xx 7 8 case {29,28,30,31} %arrows for displacement … … 44 45 end 45 46 end 46 case {8, 127} %if the delete or suppr key is pressed, delete the current object47 currentobject=gco;48 huvmat=findobj(allchild(0),'tag','uvmat');49 hlist_object=findobj(huvmat,'Tag','list_object_1');50 ObjIndex=get(hlist_object,'Value');51 if ObjIndex>152 delete_object(ObjIndex)53 end54 if ishandle(currentobject)55 tag=get(currentobject,'Tag');%tag of the current selected object56 if isequal(tag,'proj_object')57 delete_object(currentobject)58 end59 end47 % case {8, 127} %if the delete or suppr key is pressed, delete the current object 48 % currentobject=gco; 49 % huvmat=findobj(allchild(0),'tag','uvmat'); 50 % hlist_object=findobj(huvmat,'Tag','list_object_1'); 51 % ObjIndex=get(hlist_object,'Value'); 52 % if ObjIndex>1 53 % delete_object(ObjIndex) 54 % end 55 % if ishandle(currentobject) 56 % tag=get(currentobject,'Tag');%tag of the current selected object 57 % if isequal(tag,'proj_object') 58 % delete_object(currentobject) 59 % end 60 % end 60 61 case 112% key 'p' 61 62 uvmat('runplus_Callback',hObject,eventdata,handleshaxes) 62 63 case 109% key 'm' 63 64 uvmat('runmin_Callback',hObject,eventdata,handleshaxes) 65 otherwise 66 set(handleshaxes.run0,'BackgroundColor',[1 0 1])%indicat that Run must be activated (todo: rplace by REFRESH) 64 67 end 65 68 end
Note: See TracChangeset
for help on using the changeset viewer.