INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Top Toolbar vs Playing Now Popups - Use different commands for time  (Read 511 times)

jack wallstreet

  • Citizen of the Universe
  • *****
  • Posts: 523

This wiki - https://wiki.jriver.com/index.php/Playing_Now_Popup - indicates that {e} and {t} are for a file's elapsed time and total time and that is used in the top toolbar with success.  IN the playing now popup, which I am trying to modify, there is no expression for elapsed time and it appears neither {e} nor {t} work in that popup's main.xml.  I am new to this.  Is there no elapsed time expression for this popup?  Why is playing now popup using [duration] instead of {t}.  Sorry for the ignorance.  Marko suggested using the top toolbar as an example, but those commands in the top toolbar popup don't seem to work in the playing now popup.  There must be something I am missing.
Logged
John

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9160
Re: Top Toolbar vs Playing Now Popups - Use different commands for time
« Reply #1 on: November 03, 2024, 01:30:40 am »

Could you paste the contents of your main.xml here?

It will be easier to help if we can see what you currently have, that's not working.

jack wallstreet

  • Citizen of the Universe
  • *****
  • Posts: 523
Re: Top Toolbar vs Playing Now Popups - Use different commands for time
« Reply #2 on: November 03, 2024, 08:29:45 am »

Here is the main.xml.  In the 6th line, I inserted the {e}//{t} and it shows in the pop-up as {e}/{t}. I was expecting: elapsed time/total time.

<MJPS version="1.0">
<SKIN Name="Control" Author="JRiver" />

<POPUP>
   <Settings Width="300" Height="115" BackImage="" BackColor="" Border="yes" />
   <ContentItem Type="image" Name="Thumbnail" X="15" Y="10" Width="75" Height="75" Source="[Large]" />
  <ContentItem Type="text" Name="Name" X="100" Y="10" Width="195" Height="15" Text="[Name]" FontStyle="bold" />
  <ContentItem Type="text" Name="Artist" X="100" Y="27" Width="195" Height="15" Text="[Artist]" />
  <ContentItem Type="text" Name="Album" X="100" Y="44" Width="195" Height="15" Text="[Album]" />
  <ContentItem Type="text" Name="Details" X="100" Y="61" Width="195" Height="15" Text="[pn_position]//[pn_count] {e}//{t} [Mood]  [Conductor]" />
  <ContentItem Type="rating" Name="Rating" X="15" Y="88" Width="100" Height="15"/>
  <ContentItem Type="image" Name="Previous" X="115" Y="78" Width="35" Height="35" Source="{PlayerBar,PreviousButton,0}||{PlayerBar,PreviousButton,1}||{PlayerBar,PreviousButton,2}" Tooltip="Previous: Char(10) [Name] by [Artist]" Command="10004,0" TrackOffset="-1"/>
  <ContentItem Type="image" Name="Play" X="150" Y="78" Width="35" Height="35" Source="{PlayerBar,PlayButton,0}||{PlayerBar,PlayButton,1}||{PlayerBar,PlayButton,2}" Tooltip="Play" Command="10000" HideStates="2,3" />
  <ContentItem Type="image" Name="Pause" X="150" Y="78" Width="35" Height="35" Source="{PlayerBar,PauseButton,0}||{PlayerBar,PauseButton,1}||{PlayerBar,PauseButton,2}" Tooltip="Pause" Command="10000" HideStates="0,1" />
  <ContentItem Type="image" Name="Stop" X="185" Y="78" Width="35" Height="35" Source="{PlayerBar,StopButton,0}||{PlayerBar,StopButton,1}||{PlayerBar,StopButton,2}" Tooltip="Stop" Command="10002"/>
  <ContentItem Type="image" Name="Next" X="220" Y="78" Width="35" Height="35" Source="{PlayerBar,NextButton,0}||{PlayerBar,NextButton,1}||{PlayerBar,NextButton,2}" Tooltip="Next: Char(10) [Name] by [Artist]" Command="10003,0" TrackOffset="1" />
</POPUP>

</MJPS>
Logged
John

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9160
Re: Top Toolbar vs Playing Now Popups - Use different commands for time
« Reply #3 on: November 03, 2024, 08:40:31 am »

Ok, so, you can't use it that way.
It has to be given it's own space in the pop-up layout with its own line in the xml, specifying the type "time" as detailed in the wiki, here: https://wiki.jriver.com/index.php/Playing_Now_Popup#%22time%22_type

The x and y values dictate where in the pop-up the item will display, where x=0 and y=0 would be the very top left corner, and the width and height values need to be giving enough space to display the desired content.


So, if you look at the entry in the top toolbar xml, the tokens only work because the "time" type is specified, and the other values control placement, size, colour, etc.


-marko

jack wallstreet

  • Citizen of the Universe
  • *****
  • Posts: 523
Re: Top Toolbar vs Playing Now Popups - Use different commands for time
« Reply #4 on: November 03, 2024, 09:22:26 am »

Thank you for the guidance!!!!.  I'll work on this.
Logged
John

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9160
Re: Top Toolbar vs Playing Now Popups - Use different commands for time
« Reply #5 on: November 03, 2024, 09:38:31 am »

One other thing...

You're editing the stock "Control" skin.
If you update or reinstall mc, this will be over written and you will lose all the work you have done.

To avoid this, make a copy of the control folder giving it a new name, and mirror that new name in line two of the xml. This will preserve your edits in the event of an update or upgrade. :)

jack wallstreet

  • Citizen of the Universe
  • *****
  • Posts: 523
Re: Top Toolbar vs Playing Now Popups - Use different commands for time
« Reply #6 on: November 03, 2024, 10:32:31 am »

My changes are now working just the way I want them. I really also appreciate the "make a new folder to avoid overwrite".  I've now done that too.  Kind of fun!  Thanks again for the advice.
Logged
John
Pages: [1]   Go Up