Merge lp://qastaging/~craighewetson-deactivatedaccount/docky/bug-477807 into lp://qastaging/docky

Proposed by Craig Hewetson
Status: Merged
Merged at revision: 1220
Proposed branch: lp://qastaging/~craighewetson-deactivatedaccount/docky/bug-477807
Merge into: lp://qastaging/docky
Diff against target: 48 lines (+23/-1)
1 file modified
Docky/Docky/Interface/DockDragTracker.cs (+23/-1)
To merge this branch: bzr merge lp://qastaging/~craighewetson-deactivatedaccount/docky/bug-477807
Reviewer Review Type Date Requested Status
Robert Dyer (community) Approve
Craig Hewetson (community) Needs Resubmitting
Review via email: mp+20833@code.qastaging.launchpad.net

Description of the change

I've attempted a fix on the bug 477807.

To post a comment you must log in.
Revision history for this message
Robert Dyer (psybers) wrote :

Thanks. I'll try to play with this later and give you feedback. :-)

Revision history for this message
Robert Dyer (psybers) wrote :

1) I dont think ADI needs a DragHover method. Especially since all it does it call OnScrolled. You can just call a Scrolled from the drag manager and be done with it.

2) I dont think there needs to be a call from DockWindow (at all).

3) I think perhaps the code in the drag manager probably needs to be cleaned up. There doesnt need to be a method (because of #2) now. Also, the code should probably always disable the timer (that way if the drag changes and there is a timer, it is disabled). Then if drag_data isnt null start a new timer. Inside the timer there doesnt need to be a check for drag_data = null (because if it is null, the timer wont start and if it becomes null the timer will be canceled).

review: Needs Fixing
Revision history for this message
Craig Hewetson (craighewetson-deactivatedaccount) wrote :

Thanks for the feeback.

1) Ok.

2) I think I called it from the DockWindow because I found that if I started the dock for the first time and the mouse entered the dock for the first time in drag mode, the dock doesn't generate an event for that. Its only when I drag the mouse out and back in again that it worked... note if I subsequently dragged the mouse in the dock it worked everytime. It was just that first time.

I move the code somewhere else and then we can live with this bug. (Because it will be rare that the user will do a drag the first time the dock starts and the first time the mouse moves into the dock.)

3) Ok.

1167. By Craig Hewetson <email address hidden>

merged with trunk

1168. By <Craig Hewetson><email address hidden>

Changes from feed back:
https://code.launchpad.net/~craighewetson/docky/bug-477807/+merge/20833/comments/55197

Revision history for this message
Craig Hewetson (craighewetson-deactivatedaccount) wrote :

I've removed the method call from DockWindow.

I needed to have a private method because of the problem i mentioned above in point 2.

I cancel the timer every time the hover event happens. GLib.Source.remove(...)

I do the null check before creating the timer ... but... I need to still check for null when i return from the delegate... the reason for this is the following:
If I open two instances of gedit, and I would like to drag and hover a file over the dock item (representing both instances) and have it open the first instance of gedit after 1,5 seconds then i would like the timer to continue so that the 2nd instance of will be opened... note if I keep my mouse over the dock item in the drag mode it will keep cycling through these instances, until i stop dragging data (first null check inside timer ) and if i don't have an dock item under my cursor. (second null check item != null)
BTW: I'm talking about the return statement in the delegate.

review: Needs Resubmitting
Revision history for this message
Robert Dyer (psybers) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to status/vote changes: