Handle 0 files open for tooltip

This commit is contained in:
Matt Pass
2019-08-25 13:23:42 +01:00
committed by GitHub
parent 0f10702cf9
commit f623303c0b

View File

@@ -728,6 +728,12 @@ var ICEcoder = {
// Show Function & class params tooltip
functionClassParamsTooltip: function(e, area) {
if (top.ICEcoder.indexData) {
// If we have no files open, return early
if (top.ICEcoder.openFiles.length === 0) {
get('tooltip').style.display = "none";
return true;
}
var i;
// Get cM instance, and the word under mouse pointer
var cM = top.ICEcoder.getcMInstance();