Skip to content

Instantly share code, notes, and snippets.

@Temidtech
Created April 13, 2018 23:52
Show Gist options
  • Save Temidtech/045356b5f84c46951039134bc5a1a257 to your computer and use it in GitHub Desktop.
Save Temidtech/045356b5f84c46951039134bc5a1a257 to your computer and use it in GitHub Desktop.
Flutter AssetManager
String assetName = call.argument("asset");
String assetLookupKey = registrar.lookupKeyForAsset(assetName);
AssetFileDescriptor fd = registrar.context().getAssets().openFd(assetLookupKey);
player = new VideoPlayer(eventChannel, handle, fd, result);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment