Skip to content

Commit

Permalink
Merge pull request #12 from svkirans/gwtphonegap_capture
Browse files Browse the repository at this point in the history
Changes for supporting new error code and new video property in Capture API
  • Loading branch information
dankurka committed Feb 28, 2017
2 parents 6f1135d + cb4c824 commit 5258b96
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
Expand Up @@ -37,6 +37,10 @@ public interface CaptureError {
* The user exits the camera or audio capture application before capturing anything.
*/
public static final int CAPTURE_NO_MEDIA_FILES = 3;
/**
* The user denied a permission required to perform the given capture request.
*/
public static final int CAPTURE_PERMISSION_DENIED = 4;
/**
* The requested capture operation is not supported.
*/
Expand Down
Expand Up @@ -23,10 +23,13 @@ public class CaptureVideoOptions {
private int limit;

private long duration;

private int quality;

public CaptureVideoOptions() {
this.limit = 1;
this.duration = -1;
this.quality = 1;
}

/**
Expand Down Expand Up @@ -63,4 +66,21 @@ public void setDuration(long duration) {
this.duration = duration;
}

/**
* @return the quality
*/
public int getQuality() {
return quality;
}

/**
* Android supports an additional quality property, to allow capturing
* video at different qualities. A value of 1 ( the default ) means high
* quality and value of 0 means low quality, suitable for MMS messages.
* Android only.
* @param quality the quality to set
*/
public void setQuality(int quality) {
this.quality = quality;
}
}

0 comments on commit 5258b96

Please sign in to comment.