mirror of
https://github.com/anyproto/anytype-ts.git
synced 2025-06-08 05:57:02 +09:00
fix deeplink
This commit is contained in:
parent
5cfeebe226
commit
2c318aa36f
1 changed files with 9 additions and 0 deletions
|
@ -92,6 +92,9 @@ nativeTheme.on('updated', () => {
|
|||
});
|
||||
|
||||
function createWindow () {
|
||||
Util.log('info', 'CreateWindow: ' + deeplinkingUrl + ' ' + JSON.stringify(process.argv));
|
||||
|
||||
|
||||
mainWindow = WindowManager.createMain({ route: Util.getRouteFromUrl(deeplinkingUrl), isChild: false });
|
||||
|
||||
mainWindow.on('close', (e) => {
|
||||
|
@ -189,5 +192,11 @@ app.on('activate', () => {
|
|||
|
||||
app.on('open-url', (e, url) => {
|
||||
e.preventDefault();
|
||||
|
||||
deeplinkingUrl = url;
|
||||
|
||||
if (mainWindow) {
|
||||
Util.send(mainWindow, 'route', Util.getRouteFromUrl(url));
|
||||
mainWindow.show();
|
||||
};
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue