"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "ts/services/bounce.ts" between
Signal-Desktop-1.35.2.tar.gz and Signal-Desktop-1.36.1.tar.gz

About: Signal-Desktop is a cross-platform encrypted messaging service (also available for mobile devices).

bounce.ts  (Signal-Desktop-1.35.2):bounce.ts  (Signal-Desktop-1.36.1)
import { app, BrowserWindow, ipcMain } from 'electron'; import { app, BrowserWindow, ipcMain } from 'electron';
let bounceId = -1; let bounceId = -1;
export function init(win: BrowserWindow) { export function init(win: BrowserWindow): void {
ipcMain.on('bounce-app-icon-start', (_, isCritical = false) => { ipcMain.on('bounce-app-icon-start', (_, isCritical = false) => {
if (app.dock) { if (app.dock) {
const type = isCritical ? 'critical' : 'informational'; const type = isCritical ? 'critical' : 'informational';
bounceId = app.dock.bounce(type); bounceId = app.dock.bounce(type);
if (bounceId < 0) {
return;
}
} else if (win && win.flashFrame) { } else if (win && win.flashFrame) {
win.once('focus', () => { win.once('focus', () => {
win.flashFrame(false); win.flashFrame(false);
}); });
win.flashFrame(true); win.flashFrame(true);
} }
}); });
ipcMain.on('bounce-app-icon-stop', () => { ipcMain.on('bounce-app-icon-stop', () => {
if (app.dock) { if (app.dock) {
 End of changes. 2 change blocks. 
5 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)