Skip to content

Changes

v3.0.1#

Bug fixes#

  • Calling DrawImage with bad srcW or srcH arguments now silently fails instead of turning the whole panel black.

v3.0.0#

New additions#

Sample changes#

  • The Queue Viewer and Playback Buttons samples have been removed.
  • The Album Art sample no longer has a CD Jewel Case option.
  • JS Smooth Browser no longer creates playlists on selection changes. To send tracks to the Library selection playlist, a group has to be double clicked. The destination playlist name can be changed via the panel properties. As before, groups can be added to existing playlists using the right click>Add to... option.
  • The default view in JS Smooth Browser has been changed to Column + Album Art with extra group count and group length info. All previous options are still available via the right click menu.
  • The group headers in JS Smooth Playlist are no longer collapsable.
  • Thumbs now has a circular option available via the right click menu,

Removed features#

  • There is no longer a playback stats database.
  • There is no pseudo transparent option in Columns UI.
  • Panels cannot be added as toolbars in Columns UI.
  • Support for WebP images is no longer baked in to the component. Now it relies on the Windows Imaging Component. Windows 10/11 users should have WebP extensions already installed by default from the Windows Store. If you're really averse to using the store or are running Windows 7/8/8.1, you can install this to enable WebP support. Like Columns UI and Spider Monkey Panel, using the Windows Imaging Component opens up the possibility of using more exotic formats like HEIF and AVIF. Extensions for these and more can be installed via the Windows Store on Windows 10/11. The included Thumbs sample will display these automatically.

Removal of gdi#

There is no longer a gdi namespace. Those methods have been replaced as follows:

Removed Replacement
gdi.CreateImage utils.CreateImage
gdi.Font Stringified JSON
gdi.Image utils.LoadImage
gdi.LoadImageAsync utils.LoadImageAsync

Removal of IGdiGraphics#

The replacement is IJSGraphics which uses DirectWrite instead of Gdiplus. The most commonly used methods have changed as follows:

Removed Replacement Notes
gr.DrawRect gr.DrawRectangle No changes in usage.
gr.FillSolidRect gr.FillRectangle No changes in usage.
gr.DrawString, gr.GdiDrawText gr.WriteText

Special care has to be taken with all other methods as their behaviour has changed.

The most commonly used method will be gr.DrawImage which used to take angle and alpha as the last 2 arguments. Now the last 2 are opacity and angle. They were/are always optional so may be omitted.

// old
gr.DrawImage(img, dstx, dsty, dstw, dsth, srcx, srcy, srcw, srch[, angle, alpha])

// new
gr.DrawImage(img, dstx, dsty, dstw, dsth, srcx, srcy, srcw, srch[, opacity, angle])

Unlike alpha which accepted values between 0-255, opacity takes a floating point number between 0-1.

gr.DrawPolygon and gr.FillPolygon no longer exist at all.

Removal of IGdiBitmap#

Since Gdiplus is no longer used, the Windows Imaging Component is used for all image handling. I've managed to transfer most but not all previous functionality.

ApplyMask and InvertColours no longer exist but similar functionality can be replicated with new methods.

See IJSImage for full details.

Callback changes#

on_main_menu and on_playlist_item_ensure_visible have been removed entirely.

on_get_album_art_done no longer receives image_path because it's now a property of the image.

Example

function on_get_album_art_done(handle, art_id, image)
{
    if (image) g_img_path = image.Path;
}

on_load_image_done has different arguments where the image_path supplied to utils.LoadImageAsync is now the identifier instead of a task_id.

Example

function on_load_image_done(image_path, image) {
    if (image) { // could be null if supplied path was bad
        // do something
    }
}

Renamed/moved methods#

This list may be incomplete.

Old New Notes
fb.AcquireUiSelectionHolder fb.AcquireSelectionHolder
fb.CopyHandleListToClipboard IMetadbHandleList CopyToClipboard
fb.CreateProfiler utils.CreateProfiler
fb.DoDragDrop IMetadbHandleList DoDragDrop
fb.GetQueryItems IMetadbHandleList GetQueryItems
fb.GetSelections fb.GetSelection This replaces the old fb.GetSelection
fb.IsMetadbInMediaLibrary IMetadbHandle IsInLibrary
fb.RunContextCommandWithMetadb IMetadbHandleList RunContextCommand
fb.ShowPopupMessage utils.ShowPopupMessage
plman.PlaylistItemCount plman.GetPlaylistItemCount
utils.Chardet utils.DetectCharset
utils.GetAlbumArtAsync IMetadbHandle GetAlbumArtAsync
utils.GetAlbumArtEmbedded IMetadbHandle GetAlbumArtEmbedded
utils.GetAlbumArtV2 IMetadbHandle GetAlbumArt
utils.GetRequestAsync, utils.PostRequestAsync utils.HTTPRequestAsync
window.InstanceType window.IsDefaultUI Now returns a boolean value
IMetadbHandleList Add IMetadbHandleList AddItem
IMetadbHandleList AddRange IMetadbHandleList AddItems
IMetadbHandleList Insert IMetadbHandleList InsertItem
IMetadbHandleList InsertRange IMetadbHandleList InsertItems
IMetadbHandleList Item IMetadbHandleList GetItem, IMetadbHandleList ReplaceItem
IMetadbHandleList OrderByFormat IMetadbHandleList SortByFormat
IMetadbHandleList OrderByPath IMetadbHandleList SortByPath
IMetadbHandleList OrderByRelativePath IMetadbHandleList SortByRelativePath

Methods with changed behaviour#

Removals with no replacement#

  • plman.AddPlaylistItemToPlaybackQueue
  • plman.EnsurePlaylistItemVisible
  • plman.FlushPlaybackQueue
  • plman.GetPlaybackQueueHandles
  • plman.RemoveItemFromPlaybackQueue
  • plman.RemoveItemsFromPlaybackQueue
  • plman.SetPlaylistFocusItemByHandle
  • utils.MapString
  • utils.PathWildcardMatch
  • window.IsTransparent
  • IMetadbHandleList BSearch