Changeset 701 for trunk/src/mouse_up.m


Ignore:
Timestamp:
Dec 13, 2013, 10:51:21 PM (10 years ago)
Author:
sommeria
Message:

several bugs repaired

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/mouse_up.m

    r699 r701  
    9696                if size(ObjectData.Coord,1)==1 % this is the mouse up for the first point, continue until next click
    9797                    check_multiple=1;
    98                 else
    99                     %ObjectData.Coord=[ObjectData.Coord ;CurrentOrigin];% append the second point of the line (the last pointed position during mouse down)
    10098                end
    10199            case {'rectangle','ellipse','volume'}
    102                 %                  if size(ObjectData.Coord,1)==1 % this is the mouse up for the first point, continue until next click
    103                 %                     check_multiple=1;
    104                 %                  else
    105100                ObjectData.Coord=(CurrentOrigin+xy(1,1:2))/2;% keep only the first point coordinate
    106101                ObjectData.RangeX=abs(ObjectData.Coord(1,1)-xy(1,1));%rectangle width
     
    109104                    check_multiple=1;% pass to next mous up if width of height=0
    110105                end
    111                 %                 ObjectData.Coord(1,1)=(xy(1,1)+XYData(1))/2;%origin rectangle, x coordinate
    112                 %                 ObjectData.Coord(1,2)=(xy(1,2)+XYData(2))/2;
    113                 %                 ObjectData.RangeX=abs(xy(1,1)-XYData(1))/2;%rectangle width
    114                 %                 ObjectData.RangeY=abs(xy(1,2)-XYData(2))/2;%rectangle height
    115                 %                  end
    116106            case 'plane' %case of 'plane'
    117107                DX=(xy(1,1)-ObjectData.Coord(1,1));
     
    130120   
    131121    %show object coordinates in the GUI set_object
    132     %     h_set_object=findobj(allchild(0),'Tag','set_object');
    133     %     hh_set_object=guidata(h_set_object);
    134     %     set(hh_set_object.Coord,'Data',ObjectData.Coord);
    135122    if strcmp(ObjectData.Type,'rectangle')||strcmp(ObjectData.Type,'ellipse')
    136123        set(hh_set_object.num_RangeX_2,'String',num2str(ObjectData.RangeX,4));
     
    179166            end
    180167            set(hhuvmat.CheckViewField,'Value',1);%
    181             set(hhuvmat.CheckEditObject,'Value',1);%           
     168            set(hhuvmat.CheckEditObject,'Value',1);%   
     169            set(hhuvmat.MenuObject,'checked','off'); %desactivate object creation mode
    182170            set(hhuvmat.CheckEditObject,'Enable','on');%
    183171            set(get(h_set_object,'children'),'Enable','on')
Note: See TracChangeset for help on using the changeset viewer.