Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

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

Comments

Projects
None yet
3 participants
@Ashedragon
Copy link

Ashedragon commented Sep 1, 2014

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.

Copy link
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.

Copy link
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.

Copy link
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.

Copy link
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 Detect Previous Instance 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.

Copy link
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

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

@daisyowl

This comment has been minimized.

Copy link

daisyowl commented Oct 9, 2018

should this be working on windows now? i have png files associated with aseprite but they always open a new instance of aseprite when opened from the desktop or any other app

i'm on win10 / aseprite v1.2.9x64

@dacap

This comment has been minimized.

Copy link
Member

dacap commented Oct 9, 2018

This should be working on Windows too, did you use the installer or the portable version? did you associate the .aseprite file format with Aseprite manually?

@daisyowl

This comment has been minimized.

Copy link

daisyowl commented Oct 10, 2018

i installed with the installer. looks like it opens .aseprite files in the same aseprite instance, but not .png files (which I bound to aseprite manually i think)

@dacap

This comment has been minimized.

Copy link
Member

dacap commented Oct 23, 2018

@daisyowl you can check the details of the #1070 issue to see how to associate other files as the .aseprite type

@daisyowl

This comment has been minimized.

Copy link

daisyowl commented Jan 17, 2019

hmm, i followed the instructions here as best as i could understand and it still doesn't work (opening a .png from the windows explorer or in unity)

regedit

@daisyowl

This comment has been minimized.

Copy link

daisyowl commented Feb 25, 2019

ok so, update: after a bunch of fiddling, it will open from unity/file exlorer with my current setup, which is:

  • having the registry entry for .png point to AsepriteFile as above
  • ALSO setting the file explorer "open with" dialogue to aseprite
@daisyowl

This comment has been minimized.

Copy link

daisyowl commented Feb 25, 2019

without the second step (file explorer dialog) it would keep opening them in new instances of aseprite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.