dropbox

How to play streaming video using Dropbox API?

时光总嘲笑我的痴心妄想 提交于 2019-12-04 19:54:22
Now I develope application that play video streaming. My video fild uploaded at dropbox and using Dropbox Core API and media method. Media method , Core API What I made code is this. @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); AndroidAuthSession session = buildSession(); mDBApi = new DropboxAPI<AndroidAuthSession>(session); checkAppKeySetup(); btn_con=(Button)findViewById(R.id.con_btn); btn_con.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { if (mLoggedIn) {

How to determine if Dropbox has been installed on iOS device?

走远了吗. 提交于 2019-12-04 17:14:02
My app uses Dropbox to allow users to make backups of their core data store. Is there a way to determine programmatically if the Dropbox app has been installed, so I can prompt users to set up the backup? I don't want to bug users who don't use Dropbox, but I want to try to get as many users to use backups as possible. Dropbox define their own URI scheme, dbapi-1 , and as such you can see if the OS can open URLs using that scheme, as so: if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"dbapi-1://"]]) { NSLog(@"Dropbox is installed."); } else { NSLog(@"Dropbox is not

Git and Dropbox - local repo

痞子三分冷 提交于 2019-12-04 14:33:06
问题 I have read noumerous threads and watched many videos on combining Dropbox and Git functionality. One such thread is this: Using Git and Dropbox together effectively? Here is what i want to do: I am currently working on a large personal project (only me, no need for encryption). Work is done on two desktop computers (Win 7, Ubuntu) and one laptop (OSx). I wish to have my files accesible from anywhere and under version control (git) It would be great to have web-access to all the files (trough

Cannot download file from Dropbox

不打扰是莪最后的温柔 提交于 2019-12-04 14:01:27
I am uploading and downloading a file from Dropbox. When I upload a file it uploads it correctly. When I download a file and open it, the file is zero bytes. Can someone tell me why this is happening? Download code: try { File localFile = new File(localFilePath); File fileSelected = new File(dropboxPath); if (!localFile.exists()) { localFile.createNewFile(); } else { //copy(fileSelected, localFile); //mApi.copy("/Test/test.png", "/sdcard/testfile.png"); BufferedInputStream br = null; BufferedOutputStream bw = null; DropboxInputStream fd; try { fd = mApi.getFileStream(fileSelected.getPath(),

Recursive touch to fix syncing between computers [closed]

江枫思渺然 提交于 2019-12-04 11:45:09
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 7 years ago . I'm looking for a way from the command-line to touch every file in a directory (and subdirectories) due to a mistake of mine a synced repo of mine has gotten a bit out of step on my development machines. I've now through some unpleasant voodoo managed to get it back into a clean state on one machine, before I do

User Id in DropBox SDK

安稳与你 提交于 2019-12-04 10:21:59
How can i find the user id of current User who has logined through XCode In DropBox SDK. I need it done programmatically. In your code after you've linked, you can add: [self.restClient loadAccountInfo]; and the delegate: - (void)restClient:(DBRestClient*)client loadedAccountInfo:(DBAccountInfo*)info { NSLog(@"UserID: %@ %@", [info displayName], [info userId]); } After you linked to dropbox, you can try the following code: NSString* dropbox_id=[[DBSession sharedSession].userIds objectAtIndex:0]; 来源: https://stackoverflow.com/questions/5580415/user-id-in-dropbox-sdk

Download file from Dropbox with JavaScript

爱⌒轻易说出口 提交于 2019-12-04 08:18:14
I have I have a web site were try to provide a service to a client to be abel to download from Dropbox a file. For simplicity of development I use Dropbox chooser . For this I enable domains I expect to download from and include <script> tag suggested by Dropbox itself (with corresponding data-app-key ) into my HTML page. Everything works sweet. Problem Now I need to download a file selected by the user. Dropbox chooser doesn't seem to provide any functionality for this, what it does, is just retrieve an information about file. In my case this is a direct link , to download the file. To

Git fatal: Reference has invalid format: 'refs/heads/master

一个人想着一个人 提交于 2019-12-04 07:21:12
问题 I am using Dropbox to sync a git repository, but now when I try and push I am getting an error: fatal: Reference has invalid format: 'refs/heads/master (MacBook-Pro's conflicted copy 2012-10-07)' So, it seems that Dropbox detected a conflict and created a copy. Ok, no problem, so I deleted the conflicted file. Still, getting the above git error though. $ git checkout master M index.html Already on 'master' $ git add . $ git commit -a -m "Cleanup repo" [master ff6f817] Cleanup repo 1 file

Dropbox Core API - 1021 error before upload - only in iOS 5 and below [duplicate]

巧了我就是萌 提交于 2019-12-04 05:22:45
问题 This question already has answers here : NSURLErrorDomain error -1021 (2 answers) Closed 6 years ago . I integrated dropbox core API with two of my iOS apps. Successfully. A few weeks ago, it was working fine. But now when I run those apps on devices with iOS 5.0 or iOS 4.2, and try to call the uploadFile: API, I get this error: error making request to /1/files_put/sandbox/abc.xyz - (-1021) Error Domain=NSURLErrorDomain Code=-1021 "The operation couldnÕt be completed. (NSURLErrorDomain error

Download file from Dropbox and save it into SDCARD

白昼怎懂夜的黑 提交于 2019-12-04 04:27:29
Am really frustated now..I want to download a file from Dropbox and save that file into SDCARD..and I got the code as: private boolean downloadDropboxFile(String dbPath, File localFile) throws IOException{ BufferedInputStream br = null; BufferedOutputStream bw = null; try { if (!localFile.exists()) { localFile.createNewFile(); //otherwise dropbox client will fail silently } FileDownload fd = api.getFileStream("dropbox", dbPath, null); **br = new BufferedInputStream(fd.is);** bw = new BufferedOutputStream(new FileOutputStream(localFile)); byte[] buffer = new byte[4096]; int read; while (true) {