Liking cljdoc? Tell your friends :D

chromex.app.media-galleries

clj

Use the chrome.mediaGalleries API to access media files (audio, images, video) from the user's local disks (with the user's consent).

Use the chrome.mediaGalleries API to access media files (audio,
images, video) from the user's local disks (with the user's consent).

  * available since Chrome 36
  * https://developer.chrome.com/apps/mediaGalleries
raw docstring

(add-gallery-watch gallery-id)

Adds a gallery watch for the gallery with the specified gallery ID. The given callback is then fired with a success or failure result.

|gallery-id| - https://developer.chrome.com/apps/mediaGalleries#property-addGalleryWatch-galleryId.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [result] where:

|result| - https://developer.chrome.com/apps/mediaGalleries#property-callback-result.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-addGalleryWatch.

Adds a gallery watch for the gallery with the specified gallery ID. The given callback is then fired with a success or
failure result.

  |gallery-id| - https://developer.chrome.com/apps/mediaGalleries#property-addGalleryWatch-galleryId.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [result] where:

  |result| - https://developer.chrome.com/apps/mediaGalleries#property-callback-result.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-addGalleryWatch.
sourceraw docstring

(add-gallery-watch* config gallery-id)
source

add-user-selected-folderclj/smacro

(add-user-selected-folder)

Present a directory picker to the user and add the selected directory as a gallery. If the user cancels the picker, selectedFileSystemName will be empty. A user gesture is required for the dialog to display. Without a user gesture, the callback will run as though the user canceled.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [media-file-systems selected-file-system-name] where:

|media-file-systems| - https://developer.chrome.com/apps/mediaGalleries#property-callback-mediaFileSystems. |selected-file-system-name| - https://developer.chrome.com/apps/mediaGalleries#property-callback-selectedFileSystemName.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-addUserSelectedFolder.

Present a directory picker to the user and add the selected directory as a gallery. If the user cancels the picker,
selectedFileSystemName will be empty. A user gesture is required for the dialog to display. Without a user gesture, the
callback will run as though the user canceled.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [media-file-systems selected-file-system-name] where:

  |media-file-systems| - https://developer.chrome.com/apps/mediaGalleries#property-callback-mediaFileSystems.
  |selected-file-system-name| - https://developer.chrome.com/apps/mediaGalleries#property-callback-selectedFileSystemName.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-addUserSelectedFolder.
sourceraw docstring

add-user-selected-folder*cljs

(add-user-selected-folder* config)
source

api-tableclj

source

gen-callclj

source

gen-wrapclj/smacro

(gen-wrap kind item-id config & args)
source

get-media-file-system-metadataclj/smacro

(get-media-file-system-metadata media-file-system)
Get metadata about a specific media file system.

  |media-file-system| - https://developer.chrome.com/apps/mediaGalleries#property-getMediaFileSystemMetadata-mediaFileSystem.

https://developer.chrome.com/apps/mediaGalleries#method-getMediaFileSystemMetadata.
sourceraw docstring

get-media-file-system-metadata*cljs

(get-media-file-system-metadata* config media-file-system)
source

get-media-file-systemsclj/smacro

(get-media-file-systems)
(get-media-file-systems details)

Get the media galleries configured in this user agent. If none are configured or available, the callback will receive an empty array.

|details| - https://developer.chrome.com/apps/mediaGalleries#property-getMediaFileSystems-details.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [media-file-systems] where:

|media-file-systems| - https://developer.chrome.com/apps/mediaGalleries#property-callback-mediaFileSystems.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-getMediaFileSystems.

Get the media galleries configured in this user agent. If none are configured or available, the callback will receive an
empty array.

  |details| - https://developer.chrome.com/apps/mediaGalleries#property-getMediaFileSystems-details.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [media-file-systems] where:

  |media-file-systems| - https://developer.chrome.com/apps/mediaGalleries#property-callback-mediaFileSystems.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-getMediaFileSystems.
sourceraw docstring

get-media-file-systems*cljs

(get-media-file-systems* config details)
source

get-metadataclj/smacro

(get-metadata media-file)
(get-metadata media-file options)

Gets the media-specific metadata for a media file. This should work for files in media galleries as well as other DOM filesystems.

|media-file| - https://developer.chrome.com/apps/mediaGalleries#property-getMetadata-mediaFile. |options| - https://developer.chrome.com/apps/mediaGalleries#property-getMetadata-options.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [metadata] where:

|metadata| - https://developer.chrome.com/apps/mediaGalleries#property-callback-metadata.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-getMetadata.

Gets the media-specific metadata for a media file. This should work for files in media galleries as well as other DOM
filesystems.

  |media-file| - https://developer.chrome.com/apps/mediaGalleries#property-getMetadata-mediaFile.
  |options| - https://developer.chrome.com/apps/mediaGalleries#property-getMetadata-options.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [metadata] where:

  |metadata| - https://developer.chrome.com/apps/mediaGalleries#property-callback-metadata.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/apps/mediaGalleries#method-getMetadata.
sourceraw docstring

get-metadata*cljs

(get-metadata* config media-file options)
source

(on-gallery-changed* config channel & args)
source

(remove-gallery-watch gallery-id)
Removes a gallery watch for the gallery with the specified gallery ID.

  |gallery-id| - https://developer.chrome.com/apps/mediaGalleries#property-removeGalleryWatch-galleryId.

https://developer.chrome.com/apps/mediaGalleries#method-removeGalleryWatch.
sourceraw docstring

(remove-gallery-watch* config gallery-id)
source

tap-all-eventsclj/smacro

(tap-all-events chan)

Taps all valid non-deprecated events in chromex.app.media-galleries namespace.

Taps all valid non-deprecated events in chromex.app.media-galleries namespace.
sourceraw docstring

(tap-on-gallery-changed-events channel & args)

Fired when a media gallery is changed or a gallery watch is dropped.

Events will be put on the |channel| with signature [::on-gallery-changed [details]] where:

|details| - https://developer.chrome.com/apps/mediaGalleries#property-onGalleryChanged-details.

Note: |args| will be passed as additional parameters into Chrome event's .addListener call.

https://developer.chrome.com/apps/mediaGalleries#event-onGalleryChanged.

Fired when a media gallery is changed or a gallery watch is dropped.

Events will be put on the |channel| with signature [::on-gallery-changed [details]] where:

  |details| - https://developer.chrome.com/apps/mediaGalleries#property-onGalleryChanged-details.

Note: |args| will be passed as additional parameters into Chrome event's .addListener call.

https://developer.chrome.com/apps/mediaGalleries#event-onGalleryChanged.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close