Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - PocketChange

Pages: [1]
Scripting / preserve_aspect_ratio flag not working with add_image?
« on: April 15, 2021, 02:17:45 PM »
I'm woking on a theme and am running into a possible bug. Would someone please help confirm that this is an issue with current AM 2.6.1.

When trying to use add_image, the preserve_aspect_ratio flag is not working and the image will always be stretched to the defined width/height. However, the flag does work correctly with add_artwork.

Looking through the forums I found a few older posts that seem to confirm that this is an issue, but I have not seen it directly addressed.  In case this is a platform specific issue then I am currently using Win10.

Thank you.

Scripting / Displays menu - detect current selection
« on: February 17, 2020, 11:49:12 AM »
I am trying to create a displays theme and am having difficulty with finding the currently selected display name.  The best option so far appears to be   fe.game_info(Info.Name), but I can only seem to get this value on the initial startup of the theme.

Code: [Select]
local selectionname = fe.game_info(Info.Name);

function my_transition_check( ttype, var, ttime ) {
   switch ( ttype ) {
    case Transition.StartLayout:
    case Transition.ToNewSelection:
    case Transition.ToNewList:
    case Transition.EndNavigation:
        selectionname = fe.game_info(Info.Name);
        local textselectionname = fe.add_text(selectionname, flx*0.18, fly*0.905, flw*0.3, flh*0.035 );
 return false;
fe.add_transition_callback("my_transition_check" );

This works on Transition.StartLayout, but not for any other transitions. Just never updates when selecting from the wheel. If I enter a display and return back then it is updated with the new value.

I need someone else's eyes to point out my mistake. Any help is appreciated.

Pages: [1]