You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by er...@apache.org on 2020/07/23 07:28:22 UTC

[cordova-plugin-camera] branch chore/remove-deprecated-file-transfer created (now 41396d0)

This is an automated email from the ASF dual-hosted git repository.

erisu pushed a change to branch chore/remove-deprecated-file-transfer
in repository https://gitbox.apache.org/repos/asf/cordova-plugin-camera.git.


      at 41396d0  chore: remove deprecated file transfer plugin

This branch includes the following new commits:

     new 41396d0  chore: remove deprecated file transfer plugin

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org


[cordova-plugin-camera] 01/01: chore: remove deprecated file transfer plugin

Posted by er...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

erisu pushed a commit to branch chore/remove-deprecated-file-transfer
in repository https://gitbox.apache.org/repos/asf/cordova-plugin-camera.git

commit 41396d0fb66cf26a05fb29b5acb0bd872ebff34f
Author: Erisu <el...@gmail.com>
AuthorDate: Thu Jul 23 16:28:02 2020 +0900

    chore: remove deprecated file transfer plugin
---
 tests/plugin.xml |  2 --
 tests/tests.js   | 26 +-------------------------
 2 files changed, 1 insertion(+), 27 deletions(-)

diff --git a/tests/plugin.xml b/tests/plugin.xml
index cb90303..ea2a188 100644
--- a/tests/plugin.xml
+++ b/tests/plugin.xml
@@ -26,8 +26,6 @@
     <name>Cordova Camera Plugin Tests</name>
     <license>Apache 2.0</license>
 
-    <dependency id="cordova-plugin-file-transfer" />
-
     <js-module src="tests.js" name="tests">
     </js-module>
 </plugin>
diff --git a/tests/tests.js b/tests/tests.js
index 23bc470..2e76581 100644
--- a/tests/tests.js
+++ b/tests/tests.js
@@ -19,7 +19,7 @@
  *
 */
 
-/* globals Camera, resolveLocalFileSystemURL, FileEntry, CameraPopoverOptions, FileTransfer, FileUploadOptions, LocalFileSystem, MSApp */
+/* globals Camera, resolveLocalFileSystemURL, FileEntry, CameraPopoverOptions, LocalFileSystem, MSApp */
 /* eslint-env jasmine */
 
 exports.defineAutoTests = function () {
@@ -167,26 +167,6 @@ exports.defineManualTests = function (contentEl, createActionButton) {
         };
     }
 
-    function uploadImage () {
-        var ft = new FileTransfer();
-        var options = new FileUploadOptions();
-        options.fileKey = 'photo';
-        options.fileName = 'test.jpg';
-        options.mimeType = 'image/jpeg';
-        ft.onprogress = function (progressEvent) {
-            console.log('progress: ' + progressEvent.loaded + ' of ' + progressEvent.total);
-        };
-        var server = 'http://sheltered-retreat-43956.herokuapp.com';
-
-        ft.upload(pictureUrl, server + '/upload', win, fail, options);
-        function win (information_back) {
-            log('upload complete');
-        }
-        function fail (message) {
-            log('upload failed: ' + JSON.stringify(message));
-        }
-    }
-
     function logCallback (apiName, success) {
         return function () {
             log('Call to ' + apiName + (success ? ' success: ' : ' failed: ') + JSON.stringify([].slice.call(arguments)));
@@ -498,10 +478,6 @@ exports.defineManualTests = function (contentEl, createActionButton) {
         writeImage();
     }, 'write');
 
-    createActionButton('Upload Image', function () {
-        uploadImage();
-    }, 'upload');
-
     createActionButton('Draw Using Canvas', function () {
         displayImageUsingCanvas();
     }, 'draw_canvas');


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org