2015年5月4日 星期一

HedgeHao LiveCode Android External Store -- HaoDropbox4LC for $7.99 USD (2015/05/04 update)




HaoDropbox4LC_Doc


HaoDropbox4LC is an LiveCode Android External for user to create, download, modify and delete folders and files on user's dropbox account. HaoDropbox4LC includes Dropbox Android SDK.
Price : $7.99 USD / each
The payment is processed via PayPal. Please
send an email to me (hedgehao@gmail.com) if you want to place an order.
You will receive an invoice. After the payment is finished, you will
get your external files through your email.



Document    

Chiu, Chih Hao (HedgeHao) @ 2015/05/04

Installation

LiveCode Version : 7.0.4

1. First you need to replace LiveCode built classes for android
with the "Classses" file in haoDropbox4LC-1.0.0.zip. I made some
changes in LiveCode Classes to fit Dropbox's API. Copy "Classes" in
haoDropbox4LC-1.0.0 to [LiveCode install path]/Tools/Runtime/Android.
(Backup the original Classes file in case something went wrong)



2.  Copy "revsaveasandroidstandalone.livecodescript" in
haoDropbox4LC-1.0.0.zip to
[LiveCode install
path]/Tools/Toolset/libraries/ .
(Backup the original "revsaveasandroidstandalone.livecodescript"
file in case something went wrong)


3. Add "haoDropbox4LC.lcext" and "AndroidManifest.xml" to the copy
files of your stack



4. Make sure "Internet" is check in Android permissions setting



5. Set up Dropbox Develop App on
https://www.dropbox.com/developers/apps. Get your API_KEY and API_SCRET




Documentation
function haoDropboxInit(apiKey, apiScret)
Set up your develop account key and scret which get from Dropbox. Need to be call before any other functions.

return : "OK" if success




function haoDropboxLink()
Link to user's Dropbox account.

return : "OK" if success


function haoDropboxUnLink()

Unlink from Dropbox account.


return : "OK" if success

function haoDropboxIsLinked()


Check if application is linked to Dropbox.


return : "true" if the current session is linked to a account, esle retrun "false"


function haoUpload(dropboxPath, localFilePath)

Upload a file to Dropbox
*dropboxPath : the full dropbox path where to
upload file.


*localFilePath : path of the file you want to upload.

return : "OK" if success

function haoDropboxCreateFolder(dropboxPath)

Create a Dropbox folder.

*dropboxPath : the Dropbox path to the new folder.

return : "OK" if success

function haoDropboxListDirectory(dropboxPath)

list all files and subfolders in Dropbox folder.

*dropboxPath : the Dropbox path to the directory for which to list
return : the metadata of all contents in folder (JSON format).

function haoDropboxDownload(dropboxFilePath, localFilePath)

Download a file from Dropbox

*dropboxFilePath : the dropbox path to the file.

*localFilePath : file path where you want to save this file.

return : "OK" if success
, "FAIL" if file does not exists or connection lost.

function haoDropboxMove(fromPath, toPath)


Moves a file or folder (and all of the folder's contents) from one path
to another.
*fromPath : the dropbox path to move from.

*toPath : the dropbox path to move to.


return : "OK" if success, "FAIL" if file does not exists or connection lost.


function haoDropboxCopy(fromPath, toPath)
Copy a file or folder (and all of the folder's contents) from one path
to another.
*fromPath : the dropbox path to copy from.

*toPath : the dropbox path to copy to.


return : "OK" if success, "FAIL" if file does not exists or connection lost.


function haoDropboxDelete(dropboxFilePath)

Delete a file or folder (and all of the folder's contents).


*dropboxFilePath : the dropbox path to delete.
return : "OK" if success, "FAIL" if file does not exists or connection lost.




function haoDropboxShare(dropboxFilePath)

Get a url for sharing the specified directory or file.

*dropboxFilePath : the dropbox path to share.
return : the url of sharing file or directory.





沒有留言:

張貼留言