You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nifi.apache.org by "Matt Gilman (JIRA)" <ji...@apache.org> on 2015/02/12 17:05:11 UTC

[jira] [Commented] (NIFI-347) Odd behavior when attempting to create relationships

    [ https://issues.apache.org/jira/browse/NIFI-347?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14318437#comment-14318437 ] 

Matt Gilman commented on NIFI-347:
----------------------------------

I believe this is functioning as designed. 

3) The add connection icon accompanies the mouse pointer as the connection is being drawn. It doesn't need to but thought it provided a nice user experience.

1) Since the icon is accompanying the connection as its drawn we always want it on top. It is shifted so it doesn't interfere with the mouse events of entering a new component. During this event we draw a straight line using the shortest distance between the two components providing a 'snap' effect. I forget the exact details but there are some events that don't bubble up. Shifting the icon easily solved that problem because it moved the icon away from the mouse pointer and still provided the desired effect.

2) If you mouse up before dragging off the component, the resulting action is going to depend on where you mouse upped. For instance, if you initiate the drag and move a set number of pixels it will treat the action as drawing a connection to itself. This is should be obvious because the component will highlight green which shows it's a valid target for the connection. I've added this threshold because of the sensitivity of drag events. Without it, a click over the add connection icon may be interpreted as the start of a drag when the users intent was to select the component. There's always going to be some uncertainty as we don't know the user's intent. In the action you described were they simply trying to select the component or were they canceling a drag because they changed their minds? In some cases the event may be ambiguous because a click (mouse down through mouse up) spans a pixel or two (or three) based on the tracking speed of the mouse pointer.

I suppose I could redraw the add connection icon if the user mouse's up prior to the set threshold. This would beneficial in the case that the user starts a drag, opts to cancel that drag, but then decides that they did actually want to create a connection. Currently, the process is started (the add connection icon is shown) when the user mouses into the component.

> Odd behavior when attempting to create relationships
> ----------------------------------------------------
>
>                 Key: NIFI-347
>                 URL: https://issues.apache.org/jira/browse/NIFI-347
>             Project: Apache NiFi
>          Issue Type: Improvement
>          Components: Core UI
>    Affects Versions: 0.0.1
>         Environment: Linux FireFox
>            Reporter: Dan Bress
>            Priority: Minor
>
> A few strange things happen when I attempt to drag a relationship from an entity on the graph to another.
> 1) If I move my mouse over a processor/processor group/funnel/input port and see the (->+) to create a new relationship icon, then mouse down on it, the mouse down action causes the icon to move down about 10 pixels.  I don't know why this causes the icon to move.
> 2) If I do a mouse up before dragging the mouse pointer off the processor, then the new relationship icon goes away, and I cannot get it to return unless I move my mouse off of the processor and back onto it again.  I would expect the icon to come back without having to move my mouse off the processor
> 3) If I do click and drag a relationship from one processor to another the (->+) new relationship icon gets dragged along.  Is this intentional?  It does not seem necessary to me.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)