Commit 99222c5c authored by Colin Eles's avatar Colin Eles
Browse files

latest update, undo manager working better, need to implement redo for a few...

latest update, undo manager working better, need to implement redo for a few senarios, and fix undo when deleting the last remaining cell in a grid

git-svn-id: https://groke.mcmaster.ca/svn/grad/colin/trunk/TableTool@6207 57e6efec-57d4-0310-aeb1-a6c144bb1a8b
parent 108599b7
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -11,6 +11,9 @@
            
            if((strcmp(event.Character,'z')) && (strcmp(char(event.Modifier),'command') || strcmp(char(event.Modifier),'control')))
                return
            end
            if((strcmp(event.Character,'r')) && (strcmp(char(event.Modifier),'command') || strcmp(char(event.Modifier),'control')))
                return
            end
             if(~isempty(unicode2native(event.Character)))
                 % make sure the character is a printable character
@@ -23,10 +26,13 @@
                         end
                     end
                 end
                 time = toc
                %if time > 0.2
                
                %uicontrol(object.function_name_control);
                
                % hack because api does not update the string field of
                % textbox until after it loses focus. temporarily focus on
                % label, read string, refocus on textbox.
                uicontrol(object.name_label);
                   
                
@@ -35,8 +41,6 @@
                undo_data.cell = src;
                undo_data.text = get(src,'String');
               undo_data.subgrid = []
               get(src,'String')
               event
                
                object.undo_man.new_state(undo_data);
                %end
Loading