Gets the object as serialized JSON string. Or sets serialized JSON (to fill this object's metadata by the metadata included within the JSON)
Gets/sets comma separated string represented by all items in list.
Total count of items in list.
Set to true after deletion so that 'change' event is called and item is removed from UI lists.
Returns first selected item (if any item is selected). Added in 5.0.4
Index of focused item in the list.
Gets focused item in the list.
Gets integer id of the object
Whether this object can be listened (e.g. for 'change' event)
Is source for status bar informations.
Gets the object type as string
Gets persistent id of the object
Gets/sets separator text used for Text property, default is Line Break
Gets/sets text value represented by all items in list.
Gets the object title
Add list of items to the list.
List to be added
Add list of items to the list and preserve flags from the source list.
List to be added
Copies selection from one list to another. Returns a promise which is fulfilled with the index of the first selected item when it's all done.
Source list to copy selection from.
Unlock object from update state. beginUpdate and endUpdate must be in pair. When endUpdate is called, change event is called.
Returns list with items including the string value. Space is used as OR operator (if not in quotes)
Infix to check
Returns list with items starting with specified string value. Space is used as OR operator (if not in quotes)
Prefix to check
Returns list with items matching the specified search phrase (according to Options -> Search conf.).
Phrase to search
Returns list with items starting with specified string value (within any word). Space is used as OR operator (if not in quotes)
Word prefix to check
Browse all items and send them one by one in defined callback. Note that the items for the callback method are prepared using SharedList.getFastObject, i.e. the performance is good, but you should only use them in the callback method and don't preserve them for later use.
list.forEach(function(item) {
// Process the item
})
Returns a list of all checked items.
Gets copy of the list, preserves flags (selection).
Returns empty list.
Gets fast access to item at specified index. Note that this call always returns the same JS object, just modifies the internals so that properties/methods work on different data. It means, that you shouldn't preserve this object for later use, because it would be modified and the result would be unexpected.
Index of the item
Gets copy of the list with specified range indexes.
Starting index
Ending index
Gets link to a object from specified index. List needs to be locked before use (see SharedBase.locked).
Index of item
Compares two lists for the same content
Inserts list of items to the list at specified position.
List to be added
Merges this list with list in parameter and returns new merged list
to merge
new merged list
SYNCHRONOUSLY sorts the list with the given sorting rule and disables auto-sort.
To specify sort direction, append ' ASC' or ' DESC' to the tag name and separate them by semicolons.
Fields are NOT case sensitive (e.g. 'artist', 'Artist', and 'ArTiSt') are all valid, but sort direction IS case sensitive ('ASC' and 'DESC' are valid; 'asc' and 'desc' are not)
Valid examples:
list.setSortRule('title');
list.setSortRule('artist; title');
list.setSortRule('rating DESC; title ASC');
list.setSortRule('Rating DESC; TITLE;');
Invalid examples:
list.setSortRule('tagThatDoesNotExist');
list.setSortRule('rating desc; title asc');
Add list of items to the list, but clears the old values. i.e. is the same as calling clear+addList
List to be used
Returns a promise which is called when loading is finished. Returns a copy of the list. Loading is finished by calling SharedList.notifyLoaded method.
Event is called before list sort begins
See App.listen
Event is called when object is somehow changed
See App.listen
additional change type (can have values like 'tracklist', 'deleted', 'title' or undefined)
Rest
...additionalArgs: any[]app.listen(object, 'change', (changeType) => { });
Event is called when object is going to destroy
See App.listen
Event is called when focused item is changed
See App.listen
new focused item index
old focused index
Event is called when list is notified as loaded
See App.listen
Event is called when list sort is finished
See App.listen
Event is called when status info of the object is changed
See App.listen
String list class
StringList