Windows Media Player SDK banner art
PreviousNext

Sample Button Section

The following lines show a typical button section of a skin definition file:

[ Buttons ]

//  <Function> <Type>     <Location>     <Push Image Src>  <Dis Image Src>    <Hit R,G,B>  <Norm 2 Image Src>  <Push 2 Image Src>
//  ---------- ------     ----------     ----------------  ---------------    -----------  ------------------  ------------------
    PlayPause  2PushHit   84,99,67,67   Pushed @ 44,50    Disabled @ 44,50     0,255,255  Pushed @ 160,5      Pushed @ 160,98
    Info       PushHit    97,49,43,43    Pushed @ 57,0     Disabled @ 57,0      0,  0,  0
    Stop       PushHit    97,173,43,43   Pushed @ 57,124   Disabled @ 57,124  255,255,  0
    Prev       PushHit    40,83,43,43    Pushed @ 0,34     Disabled @ 0,34      0,  0,255
    Next       PushHit    153,83,43,43   Pushed @ 113,34   Disabled @ 113,34  255,  0,  0
    Shuffle    ToggleHit  40,136,43,43   Pushed @ 0,87     Disabled @ 0,87      0,255,  0
    Repeat     ToggleHit  153,136,43,43  Pushed @ 113,87   Disabled @ 113,87  255,  0,255
    Mute       Toggle     5,220,24,23    Super @ 247,29    Super @ 4,28         0,  0,  0

Note that the line length of this code may wrap on the screen or printed page, but you should only see 10 lines of code: two lines of column headings and definitions for 8 buttons.

This code defines eight buttons that are used to play, pause, and stop the media content; shuffle, repeat, and move through the playlist; and mute the volume. All the buttons except the mute button are region buttons. The mute button gets its pushed and disabled images from the Super bitmap for convenience.

PreviousNext


© 2000-2001 Microsoft Corporation. All rights reserved.