From c658f1ebc28935e3a89539f59deaa58c702b49cf Mon Sep 17 00:00:00 2001 From: Smallpath Date: Thu, 25 May 2017 19:55:04 +0800 Subject: [PATCH] fix max height beyond screen height thus making dropdownlist disappears --- dist/Sp_memory.jsx | 2 ++ src/ui/function.js | 2 ++ 2 files changed, 4 insertions(+) diff --git a/dist/Sp_memory.jsx b/dist/Sp_memory.jsx index 5da21be..044dec6 100644 --- a/dist/Sp_memory.jsx +++ b/dist/Sp_memory.jsx @@ -6846,6 +6846,8 @@ module.exports = function () { sp.parentDroplist.size.height = sp.droplist.size.height; sp.parentDroplist.location.y = 0; sp.parentDroplist.itemSize.width = (parentDroplistWidth - 27 * scale) / scale; + var screen = $.screens[0].toString().split('-').pop().split(':'); + sp.droplist.maximumSize = sp.parentDroplist.maximumSize = [undefined, parseInt(screen[1]) - 100]; sp.gv.refresh(); }; this.winClose = function () { diff --git a/src/ui/function.js b/src/ui/function.js index 89ca869..e3f4ea7 100644 --- a/src/ui/function.js +++ b/src/ui/function.js @@ -746,6 +746,8 @@ module.exports = function() { sp.parentDroplist.size.height = sp.droplist.size.height sp.parentDroplist.location.y = 0 // fix margin error for mac sp.parentDroplist.itemSize.width = (parentDroplistWidth - 27 * scale) / scale + var screen = $.screens[0].toString().split('-').pop().split(':') + sp.droplist.maximumSize = sp.parentDroplist.maximumSize = [undefined, parseInt(screen[1]) - 100] sp.gv.refresh() } this.winClose = function() {