Hi
I'm making some changes to my Kodi interface and I'm adding some shortcuts. I now want to add a shortcut to a specific folder (/Shared/new) so I need these few lines of code for opening folder in TC. I have no experience in programming but for now I'm doing well. This is an example for my Kodi favorites item that simply opens Total Commander app:
<favourite name="Total Commander">
StartAndroidActivity("com.ghisler.android.TotalCommander")
</favourite>
Now I need the same for opening a specific dir in TC (which I would put instead of these line in italics).
I would be very thankful if someone could provide me these few lines of code.
Greetings
How to 'Open directory in TC' from my launcher?
Moderators: Hacker, petermad, Stefan2, white
- ghisler(Author)
- Site Admin
- Posts: 50532
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: How to 'Open directory in TC' from my launcher?
Does Kodi somehow allow to pass URLs to opened apps? If yes, try sending e.g.
file:///storage/emulated/0
or
content:///storage/emulated/0
file:///storage/emulated/0
or
content:///storage/emulated/0
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Re: How to 'Open directory in TC' from my launcher?
Yes, it does. However, the question is what is the right action for opening a dir. I'm pretty sure ACTION_VIEW is not for opening folders, so I need to know the right action. Does Kodi allows to pass URLs to opened apps, it does, yes.
Re: How to 'Open directory in TC' from my launcher?
For example, this would work in Kodi:
That would open a web page url in Chrome.
Code: Select all
StartAndroidActivity(com.android.chrome,android.intent.action.VIEW,,http://kodi.tv/)
- ghisler(Author)
- Site Admin
- Posts: 50532
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: How to 'Open directory in TC' from my launcher?
MAIN should work, that's the one used by the launcher for the main form:
StartAndroidActivity(com.ghisler.android.TotalCommander,android.intent.action.MAIN,,content:///storage/emulated/0)
StartAndroidActivity(com.ghisler.android.TotalCommander,android.intent.action.MAIN,,content:///storage/emulated/0)
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com