WAInfo Plugin



1. INTRODUCTION

WAInfo plugin for NSIS provides a variety of functions that allow you to get basic information about Winamp Media Player. This plugin may be very useful for developers of Winamp add-ons. You can get all information about Winamp to be able to install Winamp components (plugins / skins / icon packs / color themes / language packs / etc) in the appropriate directory or even change them.

Winamp is an audio player made by Nullsoft. It is the most popular media player all over the world. It has been developed for many years and it can do a lot. It plays audio and video files, and thanks to the advanced plug-in system it has the possibility of practically unlimited extension of possibilities. Having Winamp installed on your computer and on your mobile device, you will have full ability to manage your media.

Current version of WAInfo plugin allows you to get the most important information about Winamp. First of all, you can get basic information about Winamp directories and configuration files (so you can install files to the appropriate location and read/write data in configuration files). Another useful feature is reading information about the Winamp version (you can check if the component you are installing is compatible with the current Winamp version or simply display this data).

WAInfo plugin also allows you to detect and get basic information about the default (current) Winamp plugins (output plugin, visualization plugin, and DSP/Effects plugin). You can get the default Winamp components in the same way. You can detect the name of the current Winamp language pack, the name of the current Winamp skin, and the name of the current Winamp Icon Pack Icon Library, or the name of the Notification Area control plugin Icon Pack (gen_tray).

WAInfo plugin allows you to not only get information about Winamp components but also set selected components as default Winamp components. You can set Winamp plugins (output, visualization and DSP/Effect) as default (current) Winamp plugin, you can set new Winamp language (Language Pack), you can set new Winamp Skin and new default Icon Pack Icon Library or Notification Area Icon Pack.

When installing or modifying Winamp components, you need to make sure that Winamp is not running in background (and if it is, you can safely close it). You can do this by using WAInfo functions to detect and close running Winamp instances (from the target Winamp installation directory).

This document allows you to find all functions supported by the plugin, together with a description and an example of use. More information about the WAInfo plugin can be found in "WAInfoDemo.nsi" which is attached to the plugin archive file.




2. FUNCTIONALITY AND USAGE


WAInfo plugin provides many functions that allow you to get a lot of information about Winamp. Using any function is very simple. According to the NSIS function calling convention, you have to pass the name of the function (after the plug-in name with a double colon) and appropriate parameters. The result is returned in a variable (it can be a predefined NSIS variable or a user defined variable).



2.1. BASIC INFORMATION ABOUT WINAMP

WAInfo plugin allows you to get basic information about Winamp. You can get information about the most important directories and configuration files that are used by Winamp.

USAGE

	WAInfo::GetWinampInformation "PARAM1" "PARAM2"
	Pop $0

	- PARAM1: First parameter of function have to be passed as:
		• empty string (default Winamp Installation Directory),
		• full path to Non-standard (or portable) Winamp Installation Directory

	- PARAM2: Second parameter of function that specify the type of retrieved information have to be passed as:
		• InstallDir  - Winamp Installation DirectoryExePath  - Winamp Executable File Full PathPathsINI  - Winamp Configuration File (paths.ini)ConfigDir  - Winamp Configuration Files and Settings DirectoryConfigINI  - Main Winamp Configuration File (winamp.ini)PluginsDir  - Winamp Plugins DirectorySkinsDir  - Winamp Skins DirectoryVISDir  - Winamp Visualisation Plugins DirectoryDSPDir  - Winamp DSP/Effects Plugins DirectoryComponentsDir  - Winamp Component Files DirectorySystemDir  - Winamp System Files DirectorySharedDir  - Winamp Shared Files DirectoryLangPackDir  - Winamp Language Packs DirectoryIconPackDir  - Winamp Icon Packs DirectoryTrayIconPackDir  - Winamp Notification Area Plugin Icon Pack DirectoryColorThemesDir  - Winamp Color Themes DirectoryInstType  - Winamp Installation TypeInstMode  - Winamp Installation Mode

	Function returns the following values:
		• Full path to Winamp Directory or Winamp Configuration File
		• 0 or 1 (type and mode of Winamp installation)
		• "error" (error getting data)
	

EXAMPLES

Click the + sign to expand example code or click to collapse it.

WINAMP INSTALLATION DIRECTORY

  ; This function allows you to get default Winamp Installation Directory (installed on computer).
  ; You can get infromation about non-standard Winamp Installation Directory (other or portable).
  ; All you need to do is enter the full path to the Winamp directory whose information you want to get.
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "InstallDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Installation Directory: $0"
WINAMP EXECUTABLE FILE FULL PATH

  ; This function allows you to get full path to Winamp executable file (winamp.exe)
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ExePath" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Executable File Full Path: $0"
WINAMP CONFIGURATION FILE (PATHS.INI)

  ; This function allows you to get full path to Winamp paths.ini Configuration File
  ; The paths.ini configuration file provides support for Winamp Multi User Profiles (5.11+). It allows you to define:
  ; - Winamp configuration files directory,
  ; - Winamp configuration file path,
  ; - Winamp playlists directory,
  ; - Winamp window class
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "PathsINI" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Configuration File (paths.ini): $0"
WINAMP CONFIGURATION FILES AND SETTINGS DIRECTORY

  ; This function allows you to get Winamp Configuration Files and Settings Directory
  ; This directory stores all Winamp configuration files and plugin settings
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ConfigDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Configuration Files and Settings Directory: $0"
MAIN WINAMP CONFIGURATION FILE (WINAMP.INI)

  ; This function allows you to get full path to Winamp Configuration File (winamp.ini)
  ; This file is the main Winamp configuration file that stores all the most important settings
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ConfigINI" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Main Winamp Configuration File (winamp.ini): $0"
WINAMP PLUGINS DIRECTORY

  ; This function allows you to get Winamp Plugins Directory (this directory stores all Winamp plugins)
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "PluginsDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Plugins Directory: $0"
WINAMP SKINS DIRECTORY

  ; This function allows you to get Winamp Skins Directory (this directory stores all Winamp skins)
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "SkinsDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Skins Directory: $0"
WINAMP VISUALISATION PLUGINS DIRECTORY

  ; This function allows you to get Winamp Visualisation Plugins Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VISDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Visualisation Plugins Directory: $0"
WINAMP DSP/EFFECTS PLUGINS DIRECTORY

  ; This function allows you to get Winamp DSP/Effects Plugins Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSPDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp DSP/Effects Plugins Directory: $0"
WINAMP COMPONENT FILES DIRECTORY

  ; This function allows you to get Winamp Component Files Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ComponentsDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Component Files Directory: $0"
WINAMP SYSTEM FILES DIRECTORY

  ; This function allows you to get Winamp System Files Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "SystemDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp System Files Directory: $0"
WINAMP SHARED FILES DIRECTORY

  ; This function allows you to get Winamp Shared Files Directory (Winampa 5.8+)
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "SharedDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Shared Files Directory: $0"
WINAMP LANGUAGE PACKS DIRECTORY

  ; This function allows you to get Winamp Language Packs Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "LangPackDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Language Packs Directory: $0"
WINAMP ICON PACKS DIRECTORY

  ; This function allows you to get Winamp Icon Packs Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "IconPackDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Icon Packs Directory: $0"
WINAMP NOTIFICATION AREA PLUGIN ICON PACK DIRECTORY

  ; This function allows you to get Winamp Notification Area Plugin (gen_tray) Icon Pack Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "TrayIconPackDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Notification Area Plugin Icon Pack Directory: $0"
WINAMP COLOR THEMES DIRECTORY

  ; This function allows you to get Winamp Color Themes Directory
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ColorThemesDir" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Color Themes Directory: $0"
WINAMP INSTALLATION TYPE

  ; This function allows you to specify Winamp Installation Type
  ;    - 0 means Winamp installation
  ;    - 1 means WACUP installation
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "InstType" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Installation Type: $0"
WINAMP INSTALLATION MODE

  ; This function allows you to specify Winamp Installation Mode
  ;    - 0 means normal installation
  ;    - 1 means portable installation
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "InstMode" ; Predefined Type of Information
  WAInfo::GetWinampInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Installation Mode: $0"


2.2. WINAMP VERSION INFORMATION

WAInfo plugin allows you to get Winamp version information. You can get all standard information. Winamp version number information can be very useful when installing a Winamp component that only works with a specific edition.

USAGE

	WAInfo::GetWinampVersionInfo "PARAM1" "PARAM2"
	Pop $0

	- PARAM1: First parameter of function have to be passed as:
		• empty string (default Winamp Installation Directory),
		• full path to Non-standard (or portable) Winamp Installation Directory

	- PARAM2: Second parameter of function that specify the type of retrieved information have to be passed as:
		• Comments - CommentsCompanyName - Company NameFileDescription - File DescriptionFileVersion - File VersionInternalName - Internal NameLegalCopyright - Legal CopyrightLegalTrademarks - Legal TrademarksOriginalFilename - Original FilenamePrivateBuild - Private BuildProductName - Product NameProductVersion - Product VersionSpecialBuild - Special BuildVersion - Full VersionVersionMajor - Version MajorVersionMinor - Version MinorVersionRevision - Version RevisionVersionBuild - Version Build

	Function returns the following values:
		• Winamp Version Information
		• "error" (error getting data)
	

EXAMPLES

Click the + sign to expand example code or click to collapse it.

WINAMP VERSION (COMMENTS)

  ; This string describes additional information that should be displayed for diagnostic purposes.
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "Comments" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Comments): $0"
WINAMP VERSION (COMPANY NAME)

  ; This string describes Company that produced the file
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "CompanyName" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Company Name): $0"
WINAMP VERSION (FILE DESCRIPTION)

  ; This string describes File description to be presented to users
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "FileDescription" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (File Description): $0"
WINAMP VERSION (FILE VERSION)

  ; This string describes Version number of the file
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "FileVersion" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (File Version): $0"
WINAMP VERSION (INTERNAL NAME)

  ; This string describes Internal name of the file
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "InternalName" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Internal Name): $0"
WINAMP VERSION (LEGAL COPYRIGHT)

  ; This string describes Copyright notices that apply to the file (full text of all notices, legal symbols, copyright dates, and so on)
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "LegalCopyright" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Legal Copyright): $0"
WINAMP VERSION (LEGAL TRADEMARKS)

  ; This string describes Trademarks and registered trademarks that apply to the file
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "LegalTrademarks" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Legal Trademarks): $0"
WINAMP VERSION (ORIGINAL FILENAME)

  ; This string describes Original name of the file (determine whether a file has been renamed by a user)
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OriginalFilename" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Original Filename): $0"
WINAMP VERSION (PRIVATE BUILD)

  ; This string describes information about a private version of the file
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "PrivateBuild" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Private Build): $0"
WINAMP VERSION (PRODUCT NAME)

  ; This string describes name of the product with which the file is distributed
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ProductName" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Product Name): $0"
WINAMP VERSION (PRODUCT VERSION)

  ; This string describes Version of the product with which the file is distributed
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "ProductVersion" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Product Version): $0"
WINAMP VERSION (SPECIAL BUILD)

  ; This string describes text that specifies how this version of the file differs from the standard version
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "SpecialBuild" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Special Build): $0"
WINAMP FULL VERSION

  ; This string describes identyfikuje wersję programu Winamp
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "Version" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Full Version): $0"
WINAMP VERSION (VERSION MAJOR)

  ; This string describes identyfikuje numer główny wersji programu Winamp
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VersionMajor" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Version Major): $0"
WINAMP VERSION (VERSION MINOR)

  ; This string describes identyfikuje numer poboczny wersji programu Winamp
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VersionMinor" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Version Minor): $0"
WINAMP VERSION (VERSION REVISION)

  ; This string describes identyfikuje numer rewizji wersji programu Winamp
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VersionRevision" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Version Revision): $0"
WINAMP VERSION (VERSION BUILD)

  ; This string describes identyfikuje numer kompilacji wersji programu Winamp
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VersionBuild" ; Predefined Type of Information
  WAInfo::GetWinampVersionInfo "$R1" "$R2"
  Pop $0
  DetailPrint "Winamp Version (Version Build): $0"


2.3. INFORMATION ABOUT WINAMP DEFAULT PLUGINS

The WAInfo plugin allows you to get information about Winamp default plugins. You can set the name of the current plugin (output, visualization or DSP/Effects) and all other related information.

USAGE

	WAInfo::GetWinampPluginInformation "PARAM1" "PARAM2" "PARAM3"
	Pop $0

	- PARAM1: First parameter of function have to be passed as:
		• empty string (default Winamp Installation Directory),
		• full path to Non-standard (or portable) Winamp Installation Directory

	- PARAM2: Second parameter of function that specify the type of plugin have to be passed as:
		• OUT - Winamp Output PluginVIS - Winamp Visualisation PluginDSP - Winamp DSP/Effects Plugin

	- PARAM3: Third parameter of function that specify the type of retrieved information  have to be passed as:
		• FileName - Current (default) Plugin NameFriendlyName - Friendly Plugin NameFullName - Full Plugin NameComments - CommentsCompanyName - Company NameFileDescription - File DescriptionFileVersion - File VersionInternalName - Internal NameLegalCopyright - Legal CopyrightLegalTrademarks - Legal TrademarksOriginalFilename - Original FilenameProductName - Product NameProductVersion - Product Version

	Function returns the following values:
		• Plugin Version Information
		• "error" (error getting data)
	

EXAMPLES

Click the + sign to expand example code or click to collapse it.


CURRENT WINAMP OUTPUT PLUGIN
CURRENT (DEFAULT) WINAMP OUTPUT PLUGIN NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current (default) Winamp Output Plugin Name: $0"
WINAMP OUTPUT PLUGIN FRIENDLY NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FriendlyName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Winamp Output Plugin Friendly Name: $0"
WINAMP OUTPUT PLUGIN FULL NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FullName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Winamp Output Plugin Full Name: $0"
CURRENT WINAMP OUTPUT PLUGIN [COMMENTS]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "Comments" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Comments): $0"
CURRENT WINAMP OUTPUT PLUGIN [COMPANY NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "CompanyName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Company Name): $0"
CURRENT WINAMP OUTPUT PLUGIN [FILE DESCRIPTION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileDescription" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (File Description): $0"
CURRENT WINAMP OUTPUT PLUGIN [FILE VERSION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileVersion" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (File Version): $0"
CURRENT WINAMP OUTPUT PLUGIN [INTERNAL NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "InternalName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Internal Name): $0"
CURRENT WINAMP OUTPUT PLUGIN [LEGAL COPYRIGHT]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "LegalCopyright" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Legal Copyright): $0"
CURRENT WINAMP OUTPUT PLUGIN [LEGAL TRADEMARKS]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "LegalTrademarks" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Legal Trademarks): $0"
CURRENT WINAMP OUTPUT PLUGIN [ORIGINAL FILE NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "OriginalFileName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Original File Name): $0"
CURRENT WINAMP OUTPUT PLUGIN [PRODUCT NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "ProductName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Product Name): $0"
CURRENT WINAMP OUTPUT PLUGIN [PRODUCT VERSION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OUT" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "ProductVersion" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Output Plugin (Product Version): $0"


CURRENT WINAMP VISUALISATION PLUGIN
CURRENT (DEFAULT) WINAMP VISUALISATION PLUGIN NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current (default) Winamp Visualisation Plugin Name: $0"
WINAMP VISUALISATION PLUGIN FRIENDLY NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FriendlyName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Winamp Visualisation Plugin Friendly Name: $0"
WINAMP VISUALISATION PLUGIN FULL NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FullName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Winamp Visualisation Plugin Full Name: $0"
CURRENT WINAMP VISUALISATION PLUGIN [COMMENTS]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "Comments" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Comments): $0"
CURRENT WINAMP VISUALISATION PLUGIN [COMPANY NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "CompanyName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Company Name): $0"
CURRENT WINAMP VISUALISATION PLUGIN [FILE DESCRIPTION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileDescription" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (File Description): $0"
CURRENT WINAMP VISUALISATION PLUGIN [FILE VERSION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileVersion" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (File Version): $0"
CURRENT WINAMP VISUALISATION PLUGIN [INTERNAL NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "InternalName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Internal Name): $0"
CURRENT WINAMP VISUALISATION PLUGIN [LEGAL COPYRIGHT]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "LegalCopyright" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Legal Copyright): $0"
CURRENT WINAMP VISUALISATION PLUGIN [LEGAL TRADEMARKS]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "LegalTrademarks" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Legal Trademarks): $0"
CURRENT WINAMP VISUALISATION PLUGIN [ORIGINAL FILE NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "OriginalFileName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Original File Name): $0"
CURRENT WINAMP VISUALISATION PLUGIN [PRODUCT NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "ProductName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Product Name): $0"
CURRENT WINAMP VISUALISATION PLUGIN [PRODUCT VERSION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VIS" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "ProductVersion" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp Visualisation Plugin (Product Version): $0"


CURRENT WINAMP DSP/EFFECTS PLUGIN
CURRENT (DEFAULT) WINAMP DSP/EFFECTS PLUGIN NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current (default) Winamp DSP/Effects Plugin Name: $0"
WINAMP DSP/EFFECTS PLUGIN FRIENDLY NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FriendlyName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Winamp DSP/Effects Plugin Friendly Name: $0"
WINAMP DSP/EFFECTS PLUGIN FULL NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FullName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Winamp DSP/Effects Plugin Full Name: $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [COMMENTS]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "Comments" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Comments): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [COMPANY NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "CompanyName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Company Name): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [FILE DESCRIPTION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileDescription" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (File Description): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [FILE VERSION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "FileVersion" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (File Version): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [INTERNAL NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "InternalName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Internal Name): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [LEGAL COPYRIGHT]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "LegalCopyright" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Legal Copyright): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [LEGAL TRADEMARKS]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "LegalTrademarks" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Legal Trademarks): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [ORIGINAL FILE NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "OriginalFileName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Original File Name): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [PRODUCT NAME]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "ProductName" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Product Name): $0"
CURRENT WINAMP DSP/EFFECTS PLUGIN [PRODUCT VERSION]

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSP" ; Predefined Winamp Plugin Type
  StrCpy "$R3" "ProductVersion" ; Predefined Type of Information
  WAInfo::GetWinampPluginInformation "$R1" "$R2" "$R3"
  Pop $0
  DetailPrint "Current Winamp DSP/Effects Plugin (Product Version): $0"


2.4. INFORMATION ABOUT WINAMP DEFAULT COMPONENTS

The WAInfo plugin allows you to get information about the default Winamp components. You can find the name of the current Winamp language pack, the name of the current Winamp skin, the name of the current icon pack, etc.

USAGE

	WAInfo::GetWinampComponentInformation "PARAM1" "PARAM2"
	Pop $0

	- PARAM1: First parameter of function have to be passed as:
		• empty string (default Winamp Installation Directory),
		• full path to Non-standard (or portable) Winamp Installation Directory

	- PARAM2: Second parameter of function that specify the type of retrieved information have to be passed as:
		• LangPack - Winamp Language PackSkin - Winamp SkinIconPack - Winamp Icon PackTrayIconPack - Winamp Notification Area Control Plugin Icon Pack (gen_tray)

	Function returns the following values:
		• Winamp Component Information
		• "error" (error getting data)
	

EXAMPLES

Click the + sign to expand example code or click to collapse it.

CURRENT WINAMP LANGUAGE PACK NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "LangPack" ; Predefined Type of Information
  WAInfo::GetWinampComponentInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Current Winamp Language Pack Name: $0" ; Empty String = English Language (Default)
CURRENT WINAMP SKIN NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "Skin" ; Predefined Type of Information
  WAInfo::GetWinampComponentInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Current Winamp Skin Name: $0" ; Empty String = Classic Skin (default)
CURRENT WINAMP ICON PACK NAME

  ; Jump To File Extra (JTFE) Plugin Required!
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "IconPack" ; Predefined Type of Information
  WAInfo::GetWinampComponentInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Current Winamp Icon Pack name $0"
CURRENT WINAMP NOTIFICATION AREA PLUGIN ICON PACK NAME

  ; Nullsoft Notification Area Control (gen_tray.dll) Plugin Required!
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "TrayIconPack" ; Predefined Type of Information
  WAInfo::GetWinampComponentInformation "$R1" "$R2"
  Pop $0
  DetailPrint "Current Winamp Notification Area plugin (gen_tray) Icon Pack name: $0"


2.5. SETTING NEW DEFAULT WINAMP COMPONENTS

The WAInfo plugin also allows you to change the default Winamp components. You can set a new default Winamp plugin (output, visualization or DSP/Effects), you can set a new Winamp interface language, or you can set a new Winamp skin. If you want, you can also set a new default Winamp Icon Pack Library or Nullsoft Notification Area Control (gen_tray.dll) Plugin Icons.

USAGE

	WAInfo::SetWinampDefaultComponentName "PARAM1" "PARAM2" "PARAM3"
	Pop $0

	- PARAM1: First parameter of function have to be passed as:
		• empty string (default Winamp Installation Directory),
		• full path to Non-standard (or portable) Winamp Installation Directory

	- PARAM2: Second parameter of function that specify the type of retrieved information have to be passed as:
		• OutPlugin - Winamp Output PluginVISPlugin - Winamp Visualisation PluginDSPPlugin - Winamp DSP/Effects PluginLangPack - Winamp Language PackSkin - Winamp SkinIconPack - Winamp Icon PackTrayIconPack - Winamp Notification Area Control Plugin Icon Pack (gen_tray)

	- PARAM3: Third parameter of function have to be passed as type of plugin

	Function returns the following values:
		• 0 or 1 (failure or success)
		• "error" (error getting data)
	

EXAMPLES

Click the + sign to expand example code or click to collapse it.

NEW DEFAULT WINAMP OUTPUT PLUGIN

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "OutPlugin" ; Predefined Winamp Component Type
  StrCpy "$R3" "out_wasapi.dll" ; Winamp Output Plugin Name (with extension)
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
      DetailPrint "Action Completed Successfully: $0"
      DetailPrint "New default Winamp Output Plugin: $R3"
  ${Else}
      DetailPrint "Failed to set new default Winamp Output Plugin!: $0"
  ${EndIf}
NEW DEFAULT WINAMP VISUALISATION PLUGIN

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "VISPlugin" ; Predefined Winamp Component Type
  StrCpy "$R3" "vis_milk2.dll" ; Winamp Visualisation Plugin Name (with extension)
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
      DetailPrint "Action Completed Successfully: $0"
      DetailPrint "New default Winamp Visualisation Plugin: $R3"
  ${Else}
      DetailPrint "Failed to set new default Winamp Visualisation Plugin!: $0"
  ${EndIf}
NEW DEFAULT WINAMP DSP/EFFECTS PLUGIN

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "DSPPlugin" ; Predefined Winamp Component Type
  StrCpy "$R3" "dsp_sps.dll" ; Winamp DSP/Effects Plugin Name (with extension)
  ; StrCpy "$R3" "" ; PLugin reset (none)
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
      DetailPrint "Action Completed Successfully: $0"
      DetailPrint "New default Winamp DSp/Effects Plugin: $R3"
  ${Else}
      DetailPrint "Failed to set new default Winamp DSp/Effects Plugin!: $0"
  ${EndIf}
NEW WINAMP LANGUAGE PACK NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "LangPack" ; Predefined Winamp Component Type
  StrCpy "$R3" "Winamp-pl-pl.wlz" ; Winamp Language Pack Name (WLZ)
  ; StrCpy "$R3" "Winamp-pl-pl" ; Winamp Language Pack (Folder)
  ; StrCpy "$R3" "" ; Default English Language
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
      DetailPrint "Action Completed Successfully: $0"
      DetailPrint "New default Winamp Language Pack: $R3"
  ${Else}
      DetailPrint "Failed to set new default Winamp Language Pack!: $0"
  ${EndIf}
NEW WINAMP SKIN NAME

  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "Skin" ; Predefined Winamp Component Type
  StrCpy "$R3" "Bento" ; Winamp Skin in Folder
  ; StrCpy "$R3" "Matrix_Neo.wsz" ; Winamp Classic Skin (.wsz)
  ; StrCpy "$R3" "Quinto Black.wal" ; Winamp Modern Skin (.wal)
  ; StrCpy "$R3" "SilverXP.zip" ; Winamp Other Skin (.zip)
  ; StrCpy "$R3" "" ; Classic Skin (default)
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
      DetailPrint "Action Completed Successfully: $0"
      DetailPrint "New default Winamp Skin: $R3"
  ${Else}
      DetailPrint "Failed to set new default Winamp Skin!: $0"
  ${EndIf}
NEW WINAMP ICON PACK LIBRARY

  ; Wymagana jest wtyczka Jump To File Extra (JTFE)!
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "IconPack" ; Predefined Winamp Component Type
  StrCpy "$R3" "WinampIconLibrary_MikeTheLlama.dll" ; Winamp Icon Pack Library (*.dll)
  ; StrCpy "$R3" "" ; Reset (default Winamp Icons)
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
	  DetailPrint "Action Completed Successfully: $0"
	  DetailPrint "New Winamp Icon Pack Library: $R3"
  ${Else}
	  DetailPrint "Failed to set new default Winamp Icon Pack Library!: $0"
  ${EndIf}
NEW NULLSOFT NOTIFICATION AREA CONTROL PLUGIN ICON PACK

  ; Nullsoft Notification Area Control (gen_tray.dll) Plugin Required!
  ; Default Icon Packs Directory: \Plugins\Tray_Control
  ; Na przykład: C:\Program Files (x86)\Winamp\Plugins\Tray_Control\Winamp Classic\Winamp Classic.icp
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  StrCpy "$R2" "TrayIconPack" ; Predefined Winamp Component Type
  StrCpy "$R3" "Winamp Classic.icp" ; Installed Notification Area Control Plugin Icon Pack (*.icp)
  ; StrCpy "$R3" "G:\GenTrayPack\GenTrayPack.icp" ; Non-Standard Notification Area Control Plugin Icon Pack (*.icp)
  ; StrCpy "$R3" "" ; Default Notification Area Control Plugin Icons
  ; StrCpy "$R3" "-" ; Disable Plugin Functionality
  WAInfo::SetWinampDefaultComponentName "$R1" "$R2" "$R3"
  Pop $0

  ${If} $0 == "0"
      DetailPrint "Action Completed Successfully: $0"
      ${If} $R3 == ""
          DetailPrint "Using default Notification Area Control Plugin Icons"
      ${ElseIf} "$R3" == "-"
            DetailPrint "Notification Area Control Plugin Functionality Disabled"
      ${Else}
            DetailPrint "New Notification Area Control Plugin Icon Pack: $R3"
      ${EndIf}
  ${Else}
          DetailPrint "Failed to set new Notification Area Control Plugin Icon Pack!: $0"
  ${EndIf}


2.6. DETECTING AND CLOSING RUNNING WINAMP INSTANCES

The WAInfo plugin allows you also to detect any running Winamp instances. When installing or modifying Winamp components, you need to make sure that Winamp is not running in the background (and if it is, you can safely close it). The following functions allows you to do this (detect and close running Winamp instances from target Winamp installation directory).

USAGE

	WAInfo::LocateWinampRunningProcess "PARAM1"
	WAInfo::CloseWinampRunningProcess "PARAM1"
	Pop $0

	- PARAM1: First parameter of function have to be passed as:
		• empty string (default Winamp Installation Directory),
		• full path to Non-standard (or portable) Winamp Installation Directory

	Function returns the following values:
		- Search for running Winamp instances
			•     0 = Winamp is not running in background
			•     1 = Winamp is running in background!
		- Close all running Winamp instances
			•     0 = Action finished successfully
			•     1 = Action failed!
	

EXAMPLES

Click the + sign to expand example code or click to collapse it.

  ; Searching for running Winamp Process (from Installation Directory)...
  StrCpy "$R1" "" ; Default Winamp Installation Directory
  WAInfo::LocateWinampRunningProcess "$R1"
  Pop $0 ; 0-None, 1-Found

  ${If} $0 == "1"
      ; Ask user what to do (Winamp is running in background!)
      DetailPrint "Winamp IS running in background [Search Action]: $0"

      ${If} ${Cmd} `MessageBox MB_YESNO "It seems that Winamp Media Player is running in backgroud. 
          You have to close all running Winamp instances before continue installation of $(^Name)...
          $\r$\n$\r$\nWould you like to close all running Winamp instances now?$\r$\n$\r$\n
          Please, press 'Yes' button to close all running Winamp instances now and continue installation,
          or press 'No' button to abort." /SD IDYES IDYES`

          ; Closing running Winamp instances
          WAInfo::CloseWinampRunningProcess "$R1"
          Pop $0 ; 0-Success, 1-Failed

          ${If} $0 == "1"
              DetailPrint "Winamp Running Process [Closing Action]: $0"
              MessageBox MB_OK|MB_ICONSTOP "Failed to close running Winamp instances! Aborting..."
              Abort
          ${Else}
              ; Winamp is not running! Continue Installation...
              DetailPrint "Winamp is not running in background [Closing Action]: $0"
              Sleep 500
          ${EndIf}
      ${Else}
          ; Winamp is still running in backgroud! Continue or Abort Installation!
          DetailPrint "Winamp is still running in background! Installation aborted..."
          Abort
      ${EndUnless}
  ${Else}
      ; Continue Installation (Winamp is not running)
      DetailPrint "Winamp is NOT running in background [Search Action]: $0"
      DetailPrint "Continue Installation..."
  ${EndIf}



3. DOWNLOAD



NSIS WAINFO PLUGIN
Winamp Media Player Information - NSIS WAInfo 2.1 Plugin (32/64-Bit UNICODE)


NSIS WAInfo Plugin (32/64-Bit Unicode)


Release Date: November 4, 2022 (Downloaded: 199 times)
Version: 2.1.0.0
Architecture: Windows (NSIS 32/64-Bit Unicode)
License: Freeware
Copyright: Copyright © 2004 - 2024 Paweł Porwisz
File Size: 843 KB (863885 bytes)
Hash (SHA256): 438616137a6b9a0556d47a204bca4372092bdd6f21dd20799278197c87357703





4. LICENSE

NSIS WAInfo Plugin

Copyright © 2004 - 2024 Paweł Porwisz
All rights reserved


INSTALLATION OR USE OF THE NSIS PLUGIN INDICATES YOUR ASSENT TO THE FOLLOWING LICENSE AGREEMENT.


THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.