Author Topic: Ndless 3.1 adds support for file associations  (Read 14382 times)

0 Members and 1 Guest are viewing this topic.

Offline critor

  • Editor
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2079
  • Rating: +439/-13
    • View Profile
    • TI-Planet
Ndless 3.1 adds support for file associations
« on: February 05, 2012, 09:32:12 am »
Latest Ndless 3.1 beta (r530) adds support for file associations based on file extensions.



Thanks to a little text config file (ndless_cfg.tns), you can tell Ndless to automatically look for a "mviewer.tns" file and launch it each time you try to open a ".png.tns" or ".bmp.tns" file.

All similar Ndless programs will have to be updated in order to support this new feature.



We hope to see updates for mViewer, nDoom, gbc4nspire and nespire soon ;)



Download the latest Ndless 3.1:
http://www.unsads.com/projects/nsptools/downloader/download/release/1
« Last Edit: February 05, 2012, 09:33:05 am by critor »
TI-Planet co-admin.

Offline whatkindofausernameisthis

  • LV1 Newcomer (Next: 20)
  • *
  • Posts: 11
  • Rating: +11/-0
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #1 on: February 05, 2012, 10:11:18 am »
Awesome. So does trying to open a ".png.tns" file open it with mViewer, or does it just open mViewer and you still have to navigate to the file you want to open?

Offline apcalc

  • The Game
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1393
  • Rating: +120/-2
  • VGhlIEdhbWUh (Base 64 :))
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #2 on: February 05, 2012, 01:40:18 pm »
Great update!  I'll try to update nPlayer soon! :)


Offline Spyro543

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1189
  • Rating: +74/-3
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #3 on: February 05, 2012, 01:50:06 pm »
Wow, this is just getting better and better.

Offline Juju

  • Incredibly sexy mare
  • Coder Of Tomorrow
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 5730
  • Rating: +500/-19
  • Weird programmer
    • View Profile
    • juju2143's shed
Re: Ndless 3.1 adds support for file associations
« Reply #4 on: February 05, 2012, 01:58:43 pm »
Something with argc/argv?

Remember the day the walrus started to fly...

I finally cleared my sig after 4 years you're happy now?
THEGAME
This signature is ridiculously large you've been warned.

The cute mare that used to be in my avatar is Yuki Kagayaki, you can follow her on Facebook and Tumblr.

Offline ExtendeD

  • CoT Emeritus
  • LV8 Addict (Next: 1000)
  • *
  • Posts: 825
  • Rating: +167/-2
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #5 on: February 05, 2012, 02:01:05 pm »
The file name is passed in argv[1]. I just haven't had the time to update the documentation (anyway this update is useless as long nespire/gbc4nspire/mViewer/nPlayer aren't updated too).
Ndless.me with the finest TI-Nspire programs

Offline apcalc

  • The Game
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1393
  • Rating: +120/-2
  • VGhlIEdhbWUh (Base 64 :))
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #6 on: February 05, 2012, 02:10:41 pm »
Here is nPlayer CX, updated to support this feature!  I also updated the version in the Omni archives! :D  (If someone could, please update the version on TI-Planet also ;)).
« Last Edit: February 05, 2012, 02:35:12 pm by apcalc »


Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55942
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Ndless 3.1 adds support for file associations
« Reply #7 on: February 05, 2012, 02:24:45 pm »
apcalc DFon't forget TI-Planet too :P

Also I can't wait for being able to launch WAD files directly from the Nspire file list :D
« Last Edit: February 05, 2012, 02:25:10 pm by DJ_O »
Now active at https://discord.gg/cuZcfcF (CodeWalrus server)

Offline apcalc

  • The Game
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1393
  • Rating: +120/-2
  • VGhlIEdhbWUh (Base 64 :))
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #8 on: February 05, 2012, 02:34:51 pm »
apcalc DFon't forget TI-Planet too :P

Oh, yeah, I meant TI-Planet. D:

* apcalc forgot about the change!


Offline calc84maniac

  • eZ80 Guru
  • Coder Of Tomorrow
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2912
  • Rating: +471/-17
    • View Profile
    • TI-Boy CE
Re: Ndless 3.1 adds support for file associations
« Reply #9 on: February 05, 2012, 02:47:54 pm »
Hmm, I guess it would even be possible for a program to auto-install its own file associations by accessing the config file, right? It would be cool if Ndless included a built-in function for that, to enforce the correct format and not allow duplicates and such.
"Most people ask, 'What does a thing do?' Hackers ask, 'What can I make it do?'" - Pablos Holman

Offline ExtendeD

  • CoT Emeritus
  • LV8 Addict (Next: 1000)
  • *
  • Posts: 825
  • Rating: +167/-2
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #10 on: February 05, 2012, 02:50:46 pm »
I thought of this, but I'm not sure if it will be really intuitive for users to ask them to run at least one time the main program for the file extensions to work.
Ndless.me with the finest TI-Nspire programs

Offline calc84maniac

  • eZ80 Guru
  • Coder Of Tomorrow
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2912
  • Rating: +471/-17
    • View Profile
    • TI-Boy CE
Re: Ndless 3.1 adds support for file associations
« Reply #11 on: February 05, 2012, 02:51:43 pm »
I thought of this, but I'm not sure if it will be really intuitive for users to ask them to run at least one time the main program for the file extensions to work.
It's more intuitive than setting it up manually (though of course, that would also be possible).

Edit: Here's another idea which would make it simple to package file associations with program releases (no text editing required). For example, for .nes.tns, there could be a file called ndless_cfg_nes.tns which contains the name of the program to open. (Since that file doesn't actually have a .nes.tns extension, it won't be treated as a NES file itself, naturally)
« Last Edit: February 05, 2012, 03:04:50 pm by calc84maniac »
"Most people ask, 'What does a thing do?' Hackers ask, 'What can I make it do?'" - Pablos Holman

Offline Jim Bauwens

  • Lua! Nspire! Linux!
  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1881
  • Rating: +206/-7
  • Linux!
    • View Profile
    • nothing...
Re: Ndless 3.1 adds support for file associations
« Reply #12 on: February 05, 2012, 03:08:10 pm »
Very nice :)

Offline calc84maniac

  • eZ80 Guru
  • Coder Of Tomorrow
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2912
  • Rating: +471/-17
    • View Profile
    • TI-Boy CE
Re: Ndless 3.1 adds support for file associations
« Reply #13 on: February 05, 2012, 03:11:02 pm »
Hmm, I also wonder how I'll handle file associations for gbc4nspire, which has 3 different versions with different program names (gbc4click, gbc4touch, gbc4cx)
"Most people ask, 'What does a thing do?' Hackers ask, 'What can I make it do?'" - Pablos Holman

Offline ExtendeD

  • CoT Emeritus
  • LV8 Addict (Next: 1000)
  • *
  • Posts: 825
  • Rating: +167/-2
    • View Profile
Re: Ndless 3.1 adds support for file associations
« Reply #14 on: February 05, 2012, 03:13:48 pm »
Excale suggests that the config file value contains {CX_program,[touchpad_program,[clickpad_program]]}.
Ndless.me with the finest TI-Nspire programs