当我的电子应用程序名为win.hide()时,我有一个情况,我希望最新的应用程序因为显示我的电子应用程序而变得模糊。
我在电子的GitHub上看到了一些问题,它被标记为bug,但仍未修复。 https://github.com/electron/electron/issues/10023
是否有一些解决方案或想法可以实现它?
答案 0 :(得分:0)
我无法在Linux上重现这一点。但是,作为一种低成本的解决方法,您可以执行以下操作:
const {app, BrowserWindow} = require('electron');
BrowserWindow.prototype.my_hide = function() {
this.blur();
this.hide();
return;
};
let window = null;
window = new BrowserWindow({...init...});
//at a point where you want to blur and hide your window
window.my_hide();