summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/tasklist/tasklist.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/tasklist/tasklist.js b/plugins/tasklist/tasklist.js
index 0b0a561..e9429e2 100644
--- a/plugins/tasklist/tasklist.js
+++ b/plugins/tasklist/tasklist.js
@@ -308,8 +308,8 @@ function rcube_tasklist_ui(settings)
}
else {
pos = ref.offset();
- pos.top += ref.outerHeight();
pos.left += ref.width() - menu.outerWidth();
+ pos.top += (pos.top + ref.outerHeight() + menu.height() > $(window).height() ? -menu.height() : ref.outerHeight());
menu.css({ top:pos.top+'px', left:pos.left+'px' }).show();
menu.data('refid', id);
me.selected_task = rec;