mirror of https://github.com/GNOME/gimp.git
Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/tools/gimprectangleselecttool.c: if there is a floating selection and mouse is clicked outside it without movement, anchor it. * app/tools/gimprectangletool.c: corner handle area was scaling improperly when image was zoomed.
This commit is contained in:
parent
2b1d8c0012
commit
c646d2eee5
|
@ -1,3 +1,11 @@
|
|||
2006-06-21 Bill Skaggs <weskaggs@primate.ucdavis.edu>
|
||||
|
||||
* app/tools/gimprectangleselecttool.c: if there is a floating selection
|
||||
and mouse is clicked outside it without movement, anchor it.
|
||||
|
||||
* app/tools/gimprectangletool.c: corner handle area was scaling
|
||||
improperly when image was zoomed.
|
||||
|
||||
2006-06-21 Bill Skaggs <weskaggs@primate.ucdavis.edu>
|
||||
|
||||
* app/dialogs/authors.h: autogenerated file; committing changes
|
||||
|
|
|
@ -440,19 +440,6 @@ gimp_rect_select_tool_cursor_update (GimpTool *tool,
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
* This function is called if the user clicks and releases the left
|
||||
* button without moving it. There are four things we might want
|
||||
* to do here:
|
||||
* 1) If there is an existing rectangle and we are inside it, we
|
||||
* convert it into a selection.
|
||||
* 2) If there is an existing rectangle and we are outside it, we
|
||||
* clear it.
|
||||
* 3) If there is no rectangle and we are inside the selection, we
|
||||
* create a rectangle from the selection bounds.
|
||||
* 4) If there is no rectangle and we are outside the selection,
|
||||
* we clear the selection.
|
||||
*/
|
||||
static void
|
||||
gimp_rect_select_tool_select (GimpRectangleTool *rectangle,
|
||||
gint x,
|
||||
|
@ -512,6 +499,21 @@ gimp_rect_select_tool_real_select (GimpRectSelectTool *rect_select,
|
|||
options->feather_radius);
|
||||
}
|
||||
|
||||
/*
|
||||
* This function is called if the user clicks and releases the left
|
||||
* button without moving it. There are the things we might want
|
||||
* to do here:
|
||||
* 1) If there is an existing rectangle and we are inside it, we
|
||||
* convert it into a selection.
|
||||
* 2) If there is an existing rectangle and we are outside it, we
|
||||
* clear it.
|
||||
* 3) If there is no rectangle and there is a floating selection,
|
||||
* we anchor it.
|
||||
* 4) If there is no rectangle and we are inside the selection, we
|
||||
* create a rectangle from the selection bounds.
|
||||
* 5) If there is no rectangle and we are outside the selection,
|
||||
* we clear the selection.
|
||||
*/
|
||||
static gboolean
|
||||
gimp_rect_select_tool_execute (GimpRectangleTool *rectangle,
|
||||
gint x,
|
||||
|
@ -526,6 +528,12 @@ gimp_rect_select_tool_execute (GimpRectangleTool *rectangle,
|
|||
gint pressx;
|
||||
gint pressy;
|
||||
|
||||
if (gimp_image_floating_sel (image))
|
||||
{
|
||||
floating_sel_anchor (gimp_image_floating_sel (image));
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
g_object_get (rectangle,
|
||||
"pressx", &pressx,
|
||||
"pressy", &pressy,
|
||||
|
|
|
@ -1639,7 +1639,7 @@ gimp_rectangle_tool_oper_update (GimpTool *tool,
|
|||
coords->x, coords->y,
|
||||
GIMP_HANDLE_SQUARE,
|
||||
x1, y1,
|
||||
handle_w, handle_h,
|
||||
private->dcw, private->dch,
|
||||
GTK_ANCHOR_NORTH_WEST,
|
||||
FALSE))
|
||||
{
|
||||
|
@ -1654,7 +1654,7 @@ gimp_rectangle_tool_oper_update (GimpTool *tool,
|
|||
coords->x, coords->y,
|
||||
GIMP_HANDLE_SQUARE,
|
||||
x2, y2,
|
||||
handle_w, handle_h,
|
||||
private->dcw, private->dch,
|
||||
GTK_ANCHOR_SOUTH_EAST,
|
||||
FALSE))
|
||||
{
|
||||
|
@ -1669,7 +1669,7 @@ gimp_rectangle_tool_oper_update (GimpTool *tool,
|
|||
coords->x, coords->y,
|
||||
GIMP_HANDLE_SQUARE,
|
||||
x2, y1,
|
||||
handle_w, handle_h,
|
||||
private->dcw, private->dch,
|
||||
GTK_ANCHOR_NORTH_EAST,
|
||||
FALSE))
|
||||
{
|
||||
|
@ -1684,7 +1684,7 @@ gimp_rectangle_tool_oper_update (GimpTool *tool,
|
|||
coords->x, coords->y,
|
||||
GIMP_HANDLE_SQUARE,
|
||||
x1, y2,
|
||||
handle_w, handle_h,
|
||||
private->dcw, private->dch,
|
||||
GTK_ANCHOR_SOUTH_WEST,
|
||||
FALSE))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue