![]() |
|
|||||||
|
|
||||||
|
|
|||
|
|||
|
If it's implemented, then either only as an option for MSI installer, or an option (disabled by default) for installation verification tool. Until then, you can add the association by yourself.
|
|
|
|||
|
|||
|
Quote:
|
|
|
|||
|
|||
|
I'm not sure how Orbiter receives the filehandle for the scenario, but couldn't you just pass it as a pointer to argv?
|
|
|
|||
|
|||
|
Quote:
Code:
cmd.exe /c start "Orbiter" /DD:\Orbiter\101016 D:\Orbiter\101016\orbiter.exe -s "%1" |
|
|
|||
|
|||
|
Ok, this is not exactly what I want to be implented.
I want *.scn files to be associated with orbiter just after installation. They should have an description and icon(It may be Orbiter default icon; I don't mean that every scenario file will have it's own icon(but it could be great ))e.g. ### ### Current state.scn | Orbiter scenario file ### |
|
|
|||
|
|||
|
Quote:
![]() When it's implemented though, I just don't want .scn automatically associated with Orbiter, because I usually use a couple of Orbiter installations at the same time, so just clicking on a scenario file isn't very useful for me. For example you can add .scn association from (elevated / ran as Administrator in Vista/7) command line this way: Code:
assoc .scn=OrbiterScenario
ftype OrbiterScenario=cmd.exe /c start "{window_title}" /D{path_to_orbiter} {path_to_orbiter}\orbiter.exe -s "%1"
After you have made that file association, you can edit it (by regedit) to add icon (create DefaultIcon key in HKEY_CLASSES_ROOT\OrbiterScenario and change the default value to path of icon file and index of the icon if it's inside of executable/library). |
|
|
||
|
||
|
Bad idea, IMHO. What happens if you have multiple Orbiter installations? And as an addon developer, I would find this annoying - it makes editing the scenario file harder. I have *.scn associated with Notepad, so I can easily look at or edit scenarios.
|
|
|
|||
|
|||
|
Same as SiameseCat. My .SCN files are associated to Notepad and this is great. This feature would also has to write in the registry. If you forgot to delete it when you uninstall Orbiter, you have another registry key that is unused. If you accumulate them, you'll end with a huge registry for nothing.
|
|
|
|||
|
|||
|
Quote:
Removing from registry: One of the reasons I prefer adding this feature only to the MSI installer is the fact that uninstalling Orbiter (so not just simply deleting extracted from archive files) would be done via Windows installer as well, so it could remove added association too, if there was checked the checkbox to associate files during installation (the other reason is that I don't use the MSI installer for Orbiter ).Preferred opening with Notepad: Scenario files can be associated with Notepad and Orbiter at the same time: with Orbiter for "Open" action, and with Notepad for "Edit" action. And even more, "Edit" action can be made as the default one (by setting the value of "shell" subkey), for example (shown as a part of .reg file for all users): Code:
[HKEY_CLASSES_ROOT\.scn] @="Orbiter.ScenarioFile" [HKEY_CLASSES_ROOT\Orbiter.ScenarioFile] @="Orbiter scenario" [HKEY_CLASSES_ROOT\Orbiter.ScenarioFile\DefaultIcon] @="<Path to Orbiter>\\orbiter.exe,0" [HKEY_CLASSES_ROOT\Orbiter.ScenarioFile\shell] @="edit" [HKEY_CLASSES_ROOT\Orbiter.ScenarioFile\shell\edit\command] @="notepad.exe \"%1\"" [HKEY_CLASSES_ROOT\Orbiter.ScenarioFile\shell\open\command] @="cmd.exe /c start \"Orbiter\" /D\"<Path to Orbiter>\" \"<Path to Orbiter>\\orbiter.exe\" -s \"%1\"" "HKEY_CURRENT_USER\SOFTWARE\Classes" or system-wide, for all users: "HKEY_LOCAL_MACHINE\SOFTWARE\Classes" = "HKEY_CLASSES_ROOT" Note, that I'm not an advocate for that feature, as I voted against implementing it. I'm just showing, that other presented explanations against it, than only multiple installations of Orbiter, aren't any issue preventing implementing this feature. |
|
|
|||
|
|||
|
i forget how it's done - but i think it's possible to just add a right-click menu option for .scn files to "Launch in Orbiter" by just adding a couple of registry entries like these...
i had done this once so i get an "open cmd here" command for launching the prompt at the current folder, but that was a while back and i forgot how i did it ![]() |
|
|
|||
|
|||
|
Quote:
Code:
[HKEY_CLASSES_ROOT\Orbiter.ScenarioFile\shell\LaunchInOrbiter] @="Launch in Orbiter" [HKEY_CLASSES_ROOT\Orbiter.ScenarioFile\shell\LaunchInOrbiter\command] @="cmd.exe /c start \"Orbiter\" /D\"<Path to Orbiter>\" \"<Path to Orbiter>\\orbiter.exe\" -s \"%1\"" |
|
|
|||
|
|||
|
Oh, I've just done the file association that you describe after my post. This is really great ! Thank you ! However, when you have multiple installations (like me), it is less useful.
I think that simply having the instructions to create the file association is the best. |
|
| Issue Tools |
|---|
Subscribe to this issue |
| Quick Links | Need Help? |