[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: CVS update: i_callbacks.c



  User: cnieves 
  Date: 06/10/22 05:59:18

  Modified:    .        Tag: glist_dev i_callbacks.c
  Log:
  * src/i_callbacks.c: objects can be rotated while moving or copying,
  
  so make the edit_rotate_90 callback aware of this.
  
  
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.69.2.2  +30 -5     eda/geda/gaf/gschem/src/i_callbacks.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: i_callbacks.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/i_callbacks.c,v
  retrieving revision 1.69.2.1
  retrieving revision 1.69.2.2
  diff -u -b -r1.69.2.1 -r1.69.2.2
  --- i_callbacks.c	21 Oct 2006 22:20:44 -0000	1.69.2.1
  +++ i_callbacks.c	22 Oct 2006 09:59:17 -0000	1.69.2.2
  @@ -885,22 +885,47 @@
   {
     TOPLEVEL *w_current = (TOPLEVEL *) data;
     GList *object_list;
  +  int redraw_state; 
   
     exit_if_null(w_current);
  +  if (w_current->inside_action == 0)
     o_redraw_cleanstates(w_current);	
   
  +  if (w_current->inside_action) {
  +    object_list = w_current->page_current->complex_place_list;
  +  } else {
     object_list = w_current->page_current->selection_list;    
  +  }
   
     if (object_list) {
       i_update_middle_button(w_current,
                              i_callback_edit_rotate_90_hotkey, _("Rotate"));
       /* Allow o_rotate_90 to redraw the objects */
       w_current->DONT_REDRAW = 0;
  +    if (w_current->inside_action == 0) 
       o_rotate_90(w_current, object_list, mouse_x, mouse_y);
  +    else {
  +      o_drawbounding(w_current, NULL, object_list,
  +		     x_get_darkcolor(w_current->bb_color), TRUE);
  +      /* Don't allow o_rotate_90 to erase the selection, neither to
  +	 redraw the objects after rotating */
  +      /* skip over head node */
  +      redraw_state = w_current->DONT_REDRAW;
  +      w_current->DONT_REDRAW = 1;
  +      o_rotate_90(w_current, object_list,
  +		  fix_x(w_current, w_current->start_x),
  +		  fix_y(w_current, w_current->start_y));
  +      w_current->DONT_REDRAW = redraw_state;
  +      
  +      o_drawbounding(w_current, NULL, object_list,
  +		     x_get_darkcolor(w_current->bb_color), TRUE);
  +    }
     }
   
  +  if (w_current->inside_action == 0) {
     w_current->event_state = SELECT;
     w_current->inside_action = 0;
  +  }
     i_update_toolbar(w_current);
   }
   
  
  
  


_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs