summaryrefslogtreecommitdiff
path: root/plugins/DropBox/src/dropBox_proto.h
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2014-02-18 13:55:55 +0000
committerAlexander Lantsev <aunsane@gmail.com>2014-02-18 13:55:55 +0000
commita81202e45d9f67032e4c230ce1e3a46270c3a1db (patch)
tree015c087e84d289248247f6c1756017bcb76b16a0 /plugins/DropBox/src/dropBox_proto.h
parent51ae9808067b2be06568d10214bee8a60c1160c0 (diff)
- initial commit
git-svn-id: http://svn.miranda-ng.org/main/trunk@8161 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/DropBox/src/dropBox_proto.h')
-rw-r--r--plugins/DropBox/src/dropBox_proto.h43
1 files changed, 43 insertions, 0 deletions
diff --git a/plugins/DropBox/src/dropBox_proto.h b/plugins/DropBox/src/dropBox_proto.h
new file mode 100644
index 0000000000..2127755059
--- /dev/null
+++ b/plugins/DropBox/src/dropBox_proto.h
@@ -0,0 +1,43 @@
+#ifndef _DROPBOX_PROTO_H_
+#define _DROPBOX_PROTO_H_
+
+//#include "common.h"
+#include "http_request.h"
+
+#define DROPBOX_API_VER "1"
+
+#define DROPBOX_API_URL "https://api.dropbox.com/" DROPBOX_API_VER
+#define DROPBOX_APICONTENT_URL "https://api-content.dropbox.com/" DROPBOX_API_VER
+
+#define DROPBOX_API_KEY "fa8du7gkf2q8xzg"
+#include "..\..\DropBoxApi\sekret_key.h"
+
+#define DROPBOX_FILE_CHUNK_SIZE 100 * 1024 //100 KB
+//4 * 1024 * 1024 // 4 MB
+
+extern ULONG g_fileId;
+
+void SetContactStatus(MCONTACT hContact, int newStatus);
+bool DropBoxLogIn();
+
+int OnOptionsInit(WPARAM wParam, LPARAM lParam);
+int OnModulesLoaded(WPARAM wParam, LPARAM lParam);
+
+INT_PTR DropBoxGetCaps(WPARAM wParam, LPARAM lParam);
+
+INT_PTR DropBoxSendMessage(WPARAM wParam, LPARAM lParam);
+INT_PTR DropBoxReceiveMessage(WPARAM wParam, LPARAM lParam);
+
+HttpRequest *DropBoxCreateFileChunkedRequest(const char *data, int length);
+bool DropBoxSendFileChunkedStart(const char *data, int length, char *uploadId, int &offset);
+bool DropBoxSendFileChunkedNext(const char *data, int length, const char *uploadId, int &offset);
+bool DropBoxSendFileChunkedEnd(const char *fileName, const char *uploadId, MCONTACT hContact);
+
+void DropBoxAsyncFileSend(void *args);
+
+INT_PTR DropBoxSendFile(WPARAM wParam, LPARAM lParam);
+
+INT_PTR CALLBACK MainOptionsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+INT_PTR CALLBACK TokenRequestProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+
+#endif //_DROPBOX_PROTO_H_ \ No newline at end of file