Detect previous instance: open file / sprite as a new tab in existing Aseprite session / window #477

Open
Ashedragon opened this Issue Sep 1, 2014 · 5 comments

Comments

Projects
None yet
2 participants
@Ashedragon

A setting that could be toggleable that would allow aseprite to use the instance already open to open the file rather than creating a new instance every time. I'll elucidate:
Say I have .ase files set to open with aseprite. I double-click one of them and it opens aseprite. If I then double-click another file to open it, it would (instead of creating an entirely new instance of aseprite) simply open the file in the aseprite that currently exists.

image

@dacap dacap added this to the v1.0 milestone Sep 1, 2014

@dacap dacap added the enhancement label Sep 1, 2014

@dacap

This comment has been minimized.

Show comment
Hide comment
@dacap

dacap Sep 1, 2014

Member

The Mac OS X port is already working in this way and is something I'd really love to see working in the Windows side.

Member

dacap commented Sep 1, 2014

The Mac OS X port is already working in this way and is something I'd really love to see working in the Windows side.

@dacap dacap self-assigned this Sep 1, 2014

@dacap dacap modified the milestones: v1.0, v1.1 Oct 25, 2014

@dacap dacap modified the milestones: v1.2, v1.1 Nov 17, 2015

@dacap dacap added the native label Nov 17, 2015

@dacap dacap modified the milestones: v1.1, v1.2 Dec 4, 2015

@dacap

This comment has been minimized.

Show comment
Hide comment
@dacap

dacap Feb 2, 2016

Member

This feature is needed for the Steam release:

  • when we double-click a .ase file, a new Aseprite.exe is launched
  • if there is a Aseprite.exe running, we've to send a command to this instance to open the file, then we are done (we can close the second instance)
  • if we are the first Aseprite.exe instance running, we check if we are installed on Steam, in that case we've to launch the appid and close this instance (so the app is initialized from Steam).
  • the first running instance has to start in a "server" mode, so other instances can send commands to this instance (e.g. like open a file)

This IPC could be used to solve #533 too.

Member

dacap commented Feb 2, 2016

This feature is needed for the Steam release:

  • when we double-click a .ase file, a new Aseprite.exe is launched
  • if there is a Aseprite.exe running, we've to send a command to this instance to open the file, then we are done (we can close the second instance)
  • if we are the first Aseprite.exe instance running, we check if we are installed on Steam, in that case we've to launch the appid and close this instance (so the app is initialized from Steam).
  • the first running instance has to start in a "server" mode, so other instances can send commands to this instance (e.g. like open a file)

This IPC could be used to solve #533 too.

@dacap

This comment has been minimized.

Show comment
Hide comment
@dacap

dacap Feb 3, 2016

Member

This can be solved on Windows using DDE. This is an old technology, but it looks like Microsoft Office is still using it, so we can go for it.

Note: The Allegro port cannot handle DDE messages correctly, it looks like only the Skia port will be able to fix this issue. Anyway in the future, when we implement a full COM server, we can remove the DDE processing.

Member

dacap commented Feb 3, 2016

This can be solved on Windows using DDE. This is an old technology, but it looks like Microsoft Office is still using it, so we can go for it.

Note: The Allegro port cannot handle DDE messages correctly, it looks like only the Skia port will be able to fix this issue. Anyway in the future, when we implement a full COM server, we can remove the DDE processing.

@dacap dacap closed this in 210ffc0 Feb 4, 2016

@dacap

This comment has been minimized.

Show comment
Hide comment
@dacap

dacap Feb 4, 2016

Member

This fix will be available for first time in the beta branch of the Steam release. (It means, using the Skia branch + special registry keys to use DDE.)

Member

dacap commented Feb 4, 2016

This fix will be available for first time in the beta branch of the Steam release. (It means, using the Skia branch + special registry keys to use DDE.)

@dacap dacap changed the title from Detect Previous Instance to Detect previous instance: open file / sprite as a new tab in existing Aseprite session / window Aug 2, 2016

@dacap dacap reopened this Aug 2, 2016

@dacap dacap added the linux label Aug 2, 2016

@dacap

This comment has been minimized.

Show comment
Hide comment
@dacap

dacap Aug 2, 2016

Member

I'm reopening this issue to add Linux support.

Member

dacap commented Aug 2, 2016

I'm reopening this issue to add Linux support.

@dacap dacap modified the milestones: v1.1, v1.1-bugs Jan 8, 2017

@dacap dacap modified the milestones: v1.1-bugs, v1.2-bugs Sep 12, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment