new bitmap files containing the new mouse cursors.
* pixmaps/mouse1*: new bitmap files containing the new mouse cursors.
* app/parasitelist.c: use g_str_equal instead of parasite_compare_func.
* app/paint_core.c: interpret perfectmouse right way round.
* app/rect_select{P,}.[ch]: set custom cursors when the operation type
changes. Centralize the calculation of op based on the modifier
keys being held.
* app/fuzzy_select.c, app/free_select.c: allow the rect_select
functions calculate the operation type.
* app/ellipse_select.c: use the SelectionOps typedefs.
* app/edit_selection.c: convert MaskToLayerTranslate into
FloatingSelTranslate if there is already a floating selection in
init_edit_selection.
* app/disp_callbacks.c: fixed the calculation of state.
* app/gdisplay.[ch], app/cursorutil.[ch]: new functions to allow
the loading of customized cursors.
* app/paint_funcs.[ch], app/channel.c: border_region now accepts
seperate xradius and yradius arguments.
This commit is contained in:
@ -39,12 +39,13 @@ struct _fuzzy_select
|
||||
{
|
||||
DrawCore * core; /* Core select object */
|
||||
|
||||
int op; /* selection operation (ADD, SUB, etc) */
|
||||
|
||||
int x, y; /* Point from which to execute seed fill */
|
||||
int last_x; /* */
|
||||
int last_y; /* variables to keep track of sensitivity */
|
||||
int threshold; /* threshold value for soft seed fill */
|
||||
|
||||
int op; /* selection operation (ADD, SUB, etc) */
|
||||
};
|
||||
|
||||
|
||||
@ -343,26 +344,15 @@ fuzzy_select_button_press (Tool *tool, GdkEventButton *bevent,
|
||||
tool->state = ACTIVE;
|
||||
tool->gdisp_ptr = gdisp_ptr;
|
||||
|
||||
if (bevent->state & GDK_MOD1_MASK)
|
||||
if (fuzzy_sel->op == SELECTION_MOVE_MASK)
|
||||
{
|
||||
init_edit_selection (tool, gdisp_ptr, bevent, MaskTranslate);
|
||||
return;
|
||||
}
|
||||
else if ((bevent->state & GDK_SHIFT_MASK) && !(bevent->state & GDK_CONTROL_MASK))
|
||||
fuzzy_sel->op = ADD;
|
||||
else if ((bevent->state & GDK_CONTROL_MASK) && !(bevent->state & GDK_SHIFT_MASK))
|
||||
fuzzy_sel->op = SUB;
|
||||
else if ((bevent->state & GDK_CONTROL_MASK) && (bevent->state & GDK_SHIFT_MASK))
|
||||
fuzzy_sel->op = INTERSECT;
|
||||
else
|
||||
else if (fuzzy_sel->op == SELECTION_MOVE)
|
||||
{
|
||||
if (! (layer_is_floating_sel (gimage_get_active_layer (gdisp->gimage))) &&
|
||||
gdisplay_mask_value (gdisp, bevent->x, bevent->y) > HALF_WAY)
|
||||
{
|
||||
init_edit_selection (tool, gdisp_ptr, bevent, MaskToLayerTranslate);
|
||||
return;
|
||||
}
|
||||
fuzzy_sel->op = REPLACE;
|
||||
init_edit_selection (tool, gdisp_ptr, bevent, MaskToLayerTranslate);
|
||||
return;
|
||||
}
|
||||
|
||||
/* calculate the region boundary */
|
||||
|
||||
Reference in New Issue
Block a user