[F/OS] PedrozaThumbnail Extension

according to the documentation (which is not very detailed)


I would try a relative path…

let’s assume, your video is in the root directory of the internal sdcard, the path to try is
myVideo.mp4
alternatively try with a slash like this
/myVideo.mp4

or in case it is in a subdirectory of the internal sdcard, the path to try is
mySubDirectory/myVideo.mp4
(without leading slash)
alternatively try with a slash like this
/mySubDirectory/myVideo.mp4

see also the relevant snippet from the java source file
String mPath = Environment.getExternalStorageDirectory().toString() + File.separator + fileName;

and make sure, you have WRITE_EXTERNAL_STORAGE permission…

@CarlosPedroza27 might want to improve the documentation and add some working example directories …

Taifun

1 Like

Nice Extension :grin:


But I am unable to download this extension.

3 Likes

Since it is open-source, you can remove the package name from the source and compile it yourself using AppyBuilder IDE.

EDIT: If you go to github, you can see that he has uploaded the extension there, so you may download it that way:

https://github.com/carlospedroza27/PedrozaThumbnail/raw/master/com.pedroza.PedrozaThumbnail.aix

3 Likes

its work on live test but not work after build apk

:thinking:

1 Like

hello now a new issue come permission dined. it not ask the permission


i used this method to get permission success

The Pedroza Thumbnail extension does not add WRITE_EXTERNAL_STORAGE to the Manifest. Therefore the app can’t ask for it. Permissions MUST be declared in the Manifest to ask for them.

So try to add the File component (as a dummy, without using it) to your app. Build the APK and try again.

Note: There is no need to use special blocks anymore (→ Daily Challange 46), so remove them.

See also here:

1 Like

so just i have use file component for dummy and it will ask permission or allow permission automatic

1 Like

Means, your problem is solved?

i have not test yet i am testing now lets see what happens

No problem not solved . its get and Error 701 . i just use video picker for chose video and upload to cloudnairy with thumbnail… i am just drag and drop the file component but i am use it . as you said the without use it

But the error 908 seems to be solved. Right?

grafik

Since you got a new error (error 701), show the (relevant) blocks.

Hi, I used this open source and built it with Rush, but how am I going to fix this?

Microsoft Windows [Version 10.0.19042.964]
(c) Microsoft Corporation. All rights reserved.

D:\Rush\y-tthumb>rush build -r
                      __
     _______  _______/ /_
    / ___/ / / / ___/ __ \
   / /  / /_/ (__  / / / /
  /_/   \__,_/____/_/ /_/

• Build initialized

┌ Validating project files
│
│  OKAY Metadata file (rush.yml)
│
│  OKAY AndroidManifest.xml file
└ Done
┌ Compiling Java files
│
│  ERR src\com\sgview\ytthumb\YTthumb.java:192: error: cannot find symbol
│         @SimpleProperty(category = PropertyCategory.BEHAVIOR, description = "Returns number 1 to be used in the kind parameter")
│                                                    ^
│         symbol:   method category()
│         location: @interface SimpleProperty
│
│  ERR src\com\sgview\ytthumb\YTthumb.java:200: error: cannot find symbol
│               @SimpleProperty(category = PropertyCategory.BEHAVIOR, description = "Returns number 3 to be used in the kind parameter")
│                                                          ^
│         symbol:   method category()
│         location: @interface SimpleProperty
│
│  Total errors: 2
└ Failed

• Build failed

D:\Rush\y-tthumb>

The category property in @SimpleProperty annotation does not exist in Rush. To get rid of that error, simply remove the category property from all the annotations, and you’d be good to go.

The reason why I removed it is that the category property has no effect on the behavior and working of the extension. I’m not sure why MIT implemented it in the first place; maybe for differentiating between various properties while reading the code? IDK. :man_shrugging:

When I first started with extension development, it was one of those things that were super confusing to me as it had no effect on the extension no matter what I set the category to be.

1 Like

Yes, it seems so.
Although it has no effect in AI2 but Kodular handles it cleverly.

I would like to know how Kodular handles it.

Designer properties in Kodular are divided into various categories such as advanced, experimental.

This post was flagged by the community and is temporarily hidden.

Nope, those aren’t based on the category property of SimpleProperty annotation. There’s no way for the Creator (and AI2) to read the category of a simple property, the reason behind it being the fact that this information (category of property) does not exist in the component info files of the extensions.