Sticker Creator Window
This commit is contained in:
parent
498b116794
commit
d380817a44
213 changed files with 34677 additions and 40 deletions
|
@ -112,7 +112,7 @@ export class SettingsChannel extends EventEmitter {
|
|||
this.installSetting('phoneNumberDiscoverabilitySetting');
|
||||
this.installSetting('phoneNumberSharingSetting');
|
||||
|
||||
installPermissionsHandler({ session, userConfig });
|
||||
installPermissionsHandler({ session: session.defaultSession, userConfig });
|
||||
|
||||
// These ones are different because its single source of truth is userConfig,
|
||||
// not IndexedDB
|
||||
|
@ -126,13 +126,19 @@ export class SettingsChannel extends EventEmitter {
|
|||
userConfig.set('mediaPermissions', value);
|
||||
|
||||
// We reinstall permissions handler to ensure that a revoked permission takes effect
|
||||
installPermissionsHandler({ session, userConfig });
|
||||
installPermissionsHandler({
|
||||
session: session.defaultSession,
|
||||
userConfig,
|
||||
});
|
||||
});
|
||||
ipc.handle('settings:set:mediaCameraPermissions', (_event, value) => {
|
||||
userConfig.set('mediaCameraPermissions', value);
|
||||
|
||||
// We reinstall permissions handler to ensure that a revoked permission takes effect
|
||||
installPermissionsHandler({ session, userConfig });
|
||||
installPermissionsHandler({
|
||||
session: session.defaultSession,
|
||||
userConfig,
|
||||
});
|
||||
});
|
||||
|
||||
ipc.on('settings:response', (_event, seq, error, value) => {
|
||||
|
|
|
@ -48,6 +48,8 @@ const FILES_TO_IGNORE = new Set(
|
|||
'components/webaudiorecorder/lib/WebAudioRecorderMp3.js',
|
||||
'js/Mp3LameEncoder.min.js',
|
||||
'js/WebAudioRecorderMp3.js',
|
||||
'sticker-creator/src/util/protos.d.ts',
|
||||
'sticker-creator/src/util/protos.js',
|
||||
].map(
|
||||
// This makes sure the files are correct on Windows.
|
||||
path.normalize
|
||||
|
|
|
@ -336,6 +336,9 @@ const excludedFilesRegexp = RegExp(
|
|||
'^node_modules/webpack-hot-middleware/.+',
|
||||
'^node_modules/webpack-merge/.+',
|
||||
'^node_modules/webpack/.+',
|
||||
|
||||
// Sticker Creator
|
||||
'^sticker-creator/.+',
|
||||
].join('|')
|
||||
);
|
||||
|
||||
|
|
14
ts/windows/sticker-creator/preload.ts
Normal file
14
ts/windows/sticker-creator/preload.ts
Normal file
|
@ -0,0 +1,14 @@
|
|||
// Copyright 2023 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
import { contextBridge, ipcRenderer } from 'electron';
|
||||
|
||||
contextBridge.exposeInMainWorld('getCredentials', async () =>
|
||||
ipcRenderer.invoke('get-art-creator-auth')
|
||||
);
|
||||
|
||||
contextBridge.exposeInMainWorld(
|
||||
'installStickerPack',
|
||||
(packId: string, key: string) =>
|
||||
ipcRenderer.invoke('install-sticker-pack', packId, key)
|
||||
);
|
Loading…
Add table
Add a link
Reference in a new issue