fix some pointer in filetranfer window

This commit is contained in:
Yann Leboulanger 2013-01-05 10:07:10 +01:00
parent 7b82ab7b5d
commit c0a1e9ee88
1 changed files with 6 additions and 6 deletions

View File

@ -757,7 +757,7 @@ class FileTransfersWindow:
def on_transfers_list_motion_notify_event(self, widget, event):
pointer = self.tree.get_pointer()
props = widget.get_path_at_pos(int(event.x), int(event.y))
self.height_diff = pointer[2] - int(event.y)
self.height_diff = pointer[1] - int(event.y)
if self.tooltip.timeout > 0:
if not props or self.tooltip.id != props[0]:
self.tooltip.hide_tooltip()
@ -783,7 +783,7 @@ class FileTransfersWindow:
elif self.height_diff is 0:
return
pointer = self.tree.get_pointer()
props = self.tree.get_path_at_pos(pointer[1], pointer[2] - self.height_diff)
props = self.tree.get_path_at_pos(pointer[0], pointer[1] - self.height_diff)
if self.tooltip.timeout > 0:
if not props or self.tooltip.id == props[0]:
self.tooltip.hide_tooltip()
@ -952,8 +952,8 @@ class FileTransfersWindow:
self.tooltip.hide_tooltip()
return
pointer = self.tree.get_pointer()
props = self.tree.get_path_at_pos(pointer[1],
pointer[2] - self.height_diff)
props = self.tree.get_path_at_pos(pointer[0],
pointer[1] - self.height_diff)
# check if the current pointer is at the same path
# as it was before setting the timeout
if props and self.tooltip.id == props[0]: