[PLUGIN] Dropbox

Post your completed addons to share with the community

Post » Fri Jan 11, 2013 7:44 pm

Dropbox
Version: 1.02 (21/01/2013)
Special thanks to @Ashley for his precious help.
Download Dropbox.rar


Hi there, it's been a while I didn't take time to do a plugin.
I've always been frustrated to not be able to access to my files with JS.
This is the main reason I decided to do this Dropbox Plugin.
This is adapted from the Victor Costan's Dropbox.JS library.
The Dropbox.JS library is Copyright (c) 2012 Dropbox Inc., and distributed under the MIT License.

Please test it and report me if you find any bugs, since I didn't take all the required time to do this beta test phase.
Also, I should write a help file since there are some conditions/expressions which'll need to use action before.
For the most experimented, you can read this discussion between Ashley and me here.

To give you an idea, here is a little helpful screenshot:



In order to make it working, you have to registered your application on the Dropbox site and get an API key. Here are the steps.

1. Go to the App Developer Dropbox section and click on 'Create an app'.



2. Set "Core API", then enter your "Appname" (which'll be displayed when the user'll be asked to accept the access to his dropbox), its description and choose if you want the user access to the Application folder or to the full user's Dropbox.
Then, click on 'Create'.
You should use App folder as much as possible since it is the most safety mode for your dropbox's files (in case of applications bugs, etc.



3. You'll be able to find your App key and App secret on the next page.
I encourage you to don't use your App and App secret though.
You have to encode it.



4. Go to the Dropbox API key encoder, and enter your App key and App secret then click on 'Generate the encoded key' and copy it to your clipboard.



5. Paste your encoded key to the "Encoded API key" property in the Dropbox plugin's properties.


You can now play with the differents actions, conditions and expressions.

I'm around here if you need help ;)
Enjoy.
Last edited by septeven on Tue Apr 25, 2017 2:33 pm, edited 1 time in total.
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Post » Fri Jan 11, 2013 8:57 pm

Pretty good so far. Dropbox access is definitely working.
Under actions I take it that "Generate a public link" would be "Dropbox.getPublicLink("pathname")" as a string?
Also I take it that "Dropbox.getListFolder("pathname")" would also return a string, but is that formatted so I can parse it with tokenAt?

Thanks btw been wanting this myself quite a while.
Image ImageImage
B
166
S
49
G
155
Posts: 8,111
Reputation: 100,743

Post » Fri Jan 11, 2013 9:03 pm

Please guys, download it again! I fixed a bug occured when exporting with the minifier.

@newt
It returns a string like "folder1,folder2,..." but you can change the separator in the "Access to a file or folder" action, in order to tokenAt then.

septeven2013-01-11 21:31:29
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Post » Sat Jan 12, 2013 4:27 pm

Awesome!
This is exactly what i needed for my app.
Thank u for creating this septeven
B
59
S
20
G
13
Posts: 779
Reputation: 13,347

Post » Sun Jan 13, 2013 2:17 am

@Savvy001 You're welcome ! Let me know if you need help on this one ;)
I just try a database app with and it works perfectly, really usefull !
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Post » Sun Jan 13, 2013 7:11 pm

@septeven

Wow, this is realy a perfect app for anyone who wants their users to save data online.
It works flawless for me.

I have a Question/Request:
At this point the dropbox plugin wants to login from the start of the gamelaunch.
Can u add a feature so we can let the user activate the plugin via an event.
That way the user doesn't "have" to use the dropbox plugin if he/she does not have internet.

In my app i have a sync option embedded in my Menu.
So the login would be logical to open a webbrowser only when the user visits that menu section, instead of "right at the start".
Is that possible?

Kind Regards.
Savvy001
B
59
S
20
G
13
Posts: 779
Reputation: 13,347

Post » Sun Jan 13, 2013 7:44 pm

@Savvy001
Look at the 'Connect mode' property and set it to "Manual"
Then, use the 'Log in' action.

Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Post » Sun Jan 13, 2013 8:00 pm

@septeven

Super! u where way ahead of me.

Kind Regards.
Savvy001
B
59
S
20
G
13
Posts: 779
Reputation: 13,347

Post » Thu Jan 17, 2013 11:11 pm

V.1.01
Improve and fix some minor things.
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Post » Sun Jan 20, 2013 1:16 am

For those who'll need help with this plugin, I just finished to write an help for the multimedia fusion version. I'm gonna write the construct 2 version soon. Read it here
The MMF2 version is a little bit different than the C2 one, but it's enough close for helping.
Also, you'll be able see the first idea of layout for the website that I'm writing to host all my creation, plugins and tools.septeven2013-01-20 01:16:15
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Next

Return to Completed Addons

Who is online

Users browsing this forum: Majestic-12 [Bot] and 0 guests