diff options
author | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
---|---|---|
committer | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
commit | 20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch) | |
tree | 12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/Plugins/Library/ml_webdev/resources | |
parent | 537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff) | |
download | winamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz |
Initial community commit
Diffstat (limited to 'Src/Plugins/Library/ml_webdev/resources')
20 files changed, 1330 insertions, 0 deletions
diff --git a/Src/Plugins/Library/ml_webdev/resources/gear.png b/Src/Plugins/Library/ml_webdev/resources/gear.png Binary files differnew file mode 100644 index 00000000..da8a31d9 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/gear.png diff --git a/Src/Plugins/Library/ml_webdev/resources/help.png b/Src/Plugins/Library/ml_webdev/resources/help.png Binary files differnew file mode 100644 index 00000000..b9eab4e1 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/help.png diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/api2.js b/Src/Plugins/Library/ml_webdev/resources/pages/api2.js new file mode 100644 index 00000000..f61eb4bd --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/api2.js @@ -0,0 +1,624 @@ +function startup(){ +} + +function NotImplementedYet(){ + alert("This method has not been implemented yet"); +} + +function tStopClicked(){ + var t_rc = window.external.Transport.Stop(); +} + +function tPlayClicked(){ + var t_rc = window.external.Transport.Play(); +} + +function tPauseClicked(){ + var t_rc = window.external.Transport.Pause(); +} + +function tPrevClicked(){ + var t_rc = window.external.Transport.Prev(); +} + +function tNextClicked(){ + var t_rc = window.external.Transport.Next(); +} + +function tGetMetadataClicked(){ + var metaTag = document.getElementById("t_t_mTag_in").value; + var metadata = window.external.Transport.GetMetadata(metaTag); + document.getElementById("t_t_mTag_Response").value = metadata; +} + +function tGetShuffleClicked(){ + var t_shuffle = window.external.Transport.shuffle; + document.getElementById("t_t_shuffle").value = t_shuffle; +} + +function tSetShuffleClicked(){ + var t_shuffle = document.getElementById("t_t_shuffle_in").value; + if (t_shuffle == "true") window.external.Transport.shuffle = true; + else window.external.Transport.shuffle = false; + tGetShuffleClicked(); +} + +function tGetRepeatClicked(){ + var t_repeat = window.external.Transport.repeat; + document.getElementById("t_t_repeat").value = t_repeat; +} + +function tSetRepeatClicked(){ + var t_repeat = document.getElementById("t_t_repeat_in").value; + if (t_repeat == "true") window.external.Transport.repeat = true; + else window.external.Transport.repeat = false; + tGetRepeatClicked(); +} + +function tGetPositionClicked(){ + var t_position = window.external.Transport.position; + document.getElementById("t_t_position").value = t_position; +} + +function tSetPositionClicked(){ + var t_position = document.getElementById("t_t_position_in").value; + window.external.Transport.position = parseInt(t_position); + tGetPositionClicked(); +} + +function tLengthClicked(){ + var length = window.external.Transport.length; + document.getElementById("t_t_Length").value = length; +} + +function tURLClicked(){ + var url = window.external.Transport.url; + document.getElementById("t_t_URL").value = url; +} + +function tTitleClicked(){ + var title = window.external.Transport.title; + document.getElementById("t_t_Title").value = title; +} + +function tPlayingClicked(){ + var playing = window.external.Transport.playing; + document.getElementById("t_t_Playing").value = playing; +} + +function tPausedClicked(){ + var paused = window.external.Transport.paused; + document.getElementById("t_t_Paused").value = paused; +} + +function pqPlayClicked() { + var myMusic = document.getElementById("pq_t_PlayURL_in").value; + var title = document.getElementById("pq_t_PlayTitle_in").value + var length = document.getElementById("pq_t_PlayLength_in").value; + var ilength = parseInt(length); + if (isNaN(ilength)) {ilength = 0;} + var pq_play = window.external.PlayQueue.Play(myMusic, title, ilength); +} + +function pqEnqueueClicked() { + var myMusic = document.getElementById("pq_t_EnqueueURL_in").value; + var title = document.getElementById("pq_t_EnqueueTitle_in").value + var length = document.getElementById("pq_t_EnqueueLength_in").value; + var ilength = parseInt(length); + if (isNaN(ilength)) {ilength = 0}; + var pq_play = window.external.PlayQueue.Enqueue(myMusic, title, ilength); +} + +function pqInsertClicked() { + var position = document.getElementById("pq_t_InsertPosition_in").value; + var iposition = parseInt(position); + if (isNaN(iposition)) {iposition = 0;} + var myMusic = document.getElementById("pq_t_InsertURL_in").value; + var title = document.getElementById("pq_t_InsertTitle_in").value + var length = document.getElementById("pq_t_InsertLength_in").value; + var ilength = parseInt(length); + if (isNaN(ilength)) {ilength = 0;} + var pq_play = window.external.PlayQueue.Insert(iposition, myMusic, title, ilength); +} + +function pqClearQClicked() { + var pq_rc = window.external.PlayQueue.ClearQueue(); +} + +function pqGetMetadataClicked(){ + var metaPos = document.getElementById("pq_t_MetadataPosition_in").value; + var imetaPos = parseInt(metaPos); + var metaTag = document.getElementById("pq_t_MTag_in").value; + var metadata = window.external.PlayQueue.GetMetadata(imetaPos, metaTag); + document.getElementById("pq_t_MTag_Response").value = metadata; +} + +function pqGetTitleClicked(){ + var position = document.getElementById("pq_t_TitlePosition_in").value; + var iposition = parseInt(position); + var title = window.external.PlayQueue.GetTitle(iposition); + document.getElementById("pq_t_Title").value = title; +} + +function pqGetURLClicked() { + var position = document.getElementById("pq_t_URLPosition_in").value; + var iposition = parseInt(position); + var url = window.external.PlayQueue.GetURL(iposition); + document.getElementById("pq_t_URL").value = url; +} + +function pqGetLengthClicked(){ + var length = window.external.PlayQueue.length; + document.getElementById("pq_t_Length").value = length; +} + +function pqGetCursorClicked(){ + var cursor = window.external.PlayQueue.cursor; + document.getElementById("pq_t_Cursor").value = cursor; +} + +function pqSetCursorClicked(){ + var pq_cursor = document.getElementById("pq_t_Cursor_in").value; + window.external.PlayQueue.cursor = parseInt(pq_cursor); + pqGetCursorClicked(); +} + +var listPlaylists; +function plsGetPlaylists(){ + listPlaylists = window.external.Playlists.GetPlaylists(); + var numPlaylists = listPlaylists.length; + document.getElementById("pls_t_Count").value = numPlaylists; +} + +function plsViewIndexClicked(){ + var view_index = document.getElementById("pls_t_Index_in").value; + var iview_index = parseInt(view_index); + document.getElementById("pls_t_Filename").value = listPlaylists[iview_index].filename; + document.getElementById("pls_t_Title").value = listPlaylists[iview_index].title; + document.getElementById("pls_t_PlaylistId").value = listPlaylists[iview_index].playlistId; + document.getElementById("pls_t_Length").value = listPlaylists[iview_index].length; + document.getElementById("pls_t_NumItems").value = listPlaylists[iview_index].numitems; + document.getElementById("pls_t_OpenPlaylistId_in").value = listPlaylists[iview_index].playlistId; + document.getElementById("pls_t_SavePlaylistId_in").value = listPlaylists[iview_index].playlistId; +} + +var currentPlaylist; +function plsOpenPlaylistClicked(){ + var id = document.getElementById("pls_t_OpenPlaylistId_in").value; + currentPlaylist = window.external.Playlists.OpenPlaylist(id); + document.getElementById("playlist_t_NumItems").value = currentPlaylist.numitems; + plsDisableListMethods(false); + showPlaylist(); +} + +var currentItemIndex = 0; + +function plsDisablePlaylistMethods(disable){ + var playlistSection = document.getElementById("playlistmethods"); + playlistSection.disabled = disable; + for (var i=0; i < playlistSection.childNodes.length; i++){ + if (playlistSection.childNodes[i].nodeType == 1) { + playlistSection.childNodes[i].disabled = disable; + } + } +} + +function plsDisableListMethods(disable){ + var listSection = document.getElementById("listmethods"); + listSection.disabled = disable; + for (var i=0; i < listSection.childNodes.length; i++){ + if (listSection.childNodes[i].nodeType == 1) { + listSection.childNodes[i].disabled = disable; + } + } +} + +function plsPlaylistViewIndexClicked(){ + var view_index = document.getElementById("playlist_t_ItemIndex_in").value; + var iview_index = parseInt(view_index); + currentItemIndex = iview_index; + document.getElementById("playlist_t_Filename").value = currentPlaylist.GetItemFilename(currentItemIndex); + document.getElementById("playlist_t_Title").value = currentPlaylist.GetItemTitle(currentItemIndex); + document.getElementById("playlist_t_Length").value = currentPlaylist.GetItemLength(currentItemIndex); + plsDisablePlaylistMethods(false); + showPlaylist(); +} + +var playlistwin; +var playlistWinShown = false; +function showPlaylist(){ + var output = ""; + for (var i = 0; i < currentPlaylist.numitems; i++) { + var title = currentPlaylist.GetItemTitle(i); + output += i + ":" + title + "\n"; + } + alert(output); +} + +function plsPlaylistSetItemFilenameClicked(){ + var filename = document.getElementById("playlist_t_SetItemFilename_in").value; + currentPlaylist.SetItemFilename(currentItemIndex, filename); + document.getElementById("playlist_t_Filename").value = filename; +} + +function plsPlaylistSetItemTitleClicked(){ + var title = document.getElementById("playlist_t_SetItemTitle_in").value; + currentPlaylist.SetItemTitle(currentItemIndex, title); + document.getElementById("playlist_t_Title").value = title; +} + +function plsPlaylistSetItemLengthClicked(){ + var length = document.getElementById("playlist_t_SetItemLength_in").value; + var iLength = parseInt(length); + currentPlaylist.SetItemLengthMilliseconds(currentItemIndex, iLength); + document.getElementById("playlist_t_Length").value = length; +} + +function plsPlaylistReverseClicked(){ + currentPlaylist.Reverse(); + showPlaylist(); +} + +function plsPlaylistSwapItemsClicked(){ + var swap1 = document.getElementById("playlist_t_Swap1_in").value; + var swap2 = document.getElementById("playlist_t_Swap2_in").value; + var iswap1 = parseInt(swap1); + var iswap2 = parseInt(swap2); + var rc = currentPlaylist.SwapItems(iswap1, iswap2); + showPlaylist(); +} + +function plsPlaylistRandomizeClicked(){ + currentPlaylist.Randomize(); + showPlaylist(); +} + +function plsPlaylistRemoveClicked(){ + alert("Inside Remove, currentItemIndex=" + currentItemIndex); + currentPlaylist.RemoveItem(currentItemIndex); + showPlaylist(); +} + +function plsPlaylistSortByTitleClicked(){ + currentPlaylist.SortByTitle(); + showPlaylist(); +} + +function plsPlaylistSortByFilenameClicked(){ + currentPlaylist.SortByFilename(); + showPlaylist(); +} + +function plsPlaylistInsertUrlClicked(){ + var url = document.getElementById("playlist_t_InsertUrl_in").value; + var title = document.getElementById("playlist_t_InsertTitle_in").value; + var length = document.getElementById("playlist_t_InsertLength_in").value; + var iLength = parseInt(length); + var rc = currentPlaylist.InsertURL(currentItemIndex, url, title, iLength); + showPlaylist(); +} + +function plsPlaylistAppendUrlClicked(){ + var url = document.getElementById("playlist_t_AppendUrl_in").value; + var title = document.getElementById("playlist_t_AppendTitle_in").value; + var length = document.getElementById("playlist_t_AppendLength_in").value; + var iLength = parseInt(length); + var rc = currentPlaylist.AppendURL(url, title, iLength); + showPlaylist(); +} + +function plsPlaylistClearClicked(){ + var rc = currentPlaylist.Clear(); + showPlaylist(); +} + +function plsSavePlaylistClicked() { + var playlistId = document.getElementById("pls_t_SavePlaylistId_in").value; + var rc = window.external.Playlists.SavePlaylist(playlistId, currentPlaylist); + document.getElementById("playlistmethods").disabled = true; +} + +function BMarkAddClicked(){ + var url = document.getElementById("bmark_t_AddURL_in").value; + var title = document.getElementById("bmark_t_AddTitle_in").value; + var rc = window.external.Bookmarks.Add(url, title); +} + +function PodcastSubscribeClicked(){ + var podcUrl = document.getElementById("podc_t_SubscribeURL_in").value; + var rc = window.external.Podcasts.Subscribe(podcUrl); +} + +function ConfigSetPropertyClicked(){ + var inParam = document.getElementById("config_t_SetPropertyName_in").value; + var inValue = document.getElementById("config_t_SetPropertyValue_in").value; + if (pType[0].checked) { + inValue = "'" + inValue + "'"; + } else if (pType[2].checked){ + if (inValue != "false"){ + inValue = "true"; + } + } + var funcBody = "var rc = window.external.Config." + inParam + "=" + inValue; + var configPropSet = new Function(funcBody); + configPropSet(); +} + +function ConfigGetPropertyClicked(){ + var inParam = document.getElementById("config_t_GetPropertyName_in").value; + var funcBody = "return window.external.Config." + inParam; + var configPropGet = new Function(funcBody); + var propValue = configPropGet(); + document.getElementById("config_t_GetPropertyValue").value = propValue; +} + +function ApplicationLaunchURLClicked(){ + var url = document.getElementById("application_t_URL_in").value; + var forceExternal = document.getElementById("application_t_ForceExternal_in").checked; + var rc = window.external.Application.LaunchURL(url, forceExternal); +} + +function ApplicationNumVersionClicked(){ + var numVer = window.external.Application.version; + document.getElementById("application_t_NumVersion").value = parseInt(numVer); +} + +function ApplicationStringVersionClicked(){ + var stringVer = window.external.Application.versionstring; + document.getElementById("application_t_StringVersion").value = stringVer; +} + +function ApplicationLanguageClicked(){ + var lang = window.external.Application.language; + document.getElementById("application_t_Language").value = lang; +} + +function ApplicationLanguagePackClicked(){ + var langPack = window.external.Application.languagepack; + document.getElementById("application_t_LanguagePack").value = langPack; +} + +function SkinGetClassicColorClicked(){ + var colorNum = document.getElementById("skin_t_ClassicColorNumber_in").value; + var iColorNum = parseInt(colorNum); + var classicColor = window.external.Skin.GetClassicColor(iColorNum); + document.getElementById("skin_t_ClassicColor").value = classicColor; +} + +function SkinGetPlaylistColorClicked(){ + var colorNum = document.getElementById("skin_t_PlaylistColorNumber_in").value; + var iColorNum = parseInt(colorNum); + var playlistColor = window.external.Skin.GetPlaylistColor(iColorNum); + document.getElementById("skin_t_PlaylistColor").value = playlistColor; +} + +function SkinGetSkinColorClicked(){ + var colorName = document.getElementById("skin_t_SkinColorName_in").value; + var skinColor = window.external.Skin.GetSkinColor(colorName); + document.getElementById("skin_t_SkinColor").value = skinColor; +} + +function SkinGetNameClicked(){ + var name = window.external.Skin.name; + document.getElementById("skin_t_Name").value = name; +} + +function SkinSetNameClicked() { + var skinName = document.getElementById("skin_t_Name_in").value; + window.external.Skin.name = skinName; +} + +function SkinGetFontClicked(){ + var font = window.external.Skin.font; + document.getElementById("skin_t_Font").value = font; +} + +function SkinGetFontSizeClicked(){ + var fontsize = window.external.Skin.fontsize; + document.getElementById("skin_t_FontSize").value = fontsize; +} + +function mcGetMetadataClicked(){ + var metaFile = document.getElementById("mc_t_MediaCoreFilename_in").value; + var metaTag = document.getElementById("mc_t_MediaCoreTag_in").value; + var metadata = window.external.MediaCore.GetMetadata(metaFile, metaTag); + document.getElementById("mc_t_MediaCoreMetadata_Response").value = metadata; +} + +function mcIsRegisteredExtensionClicked(){ + var extension = document.getElementById("mc_t_MediaCoreExtension_in").value; + var supported = window.external.MediaCore.IsRegisteredExtension(extension); + document.getElementById("mc_t_MediaCoreRegisteredExtension_Response").value = supported; +} + +function mcAddMetadataHookClicked(){ + var mUrl = document.getElementById("mc_t_AddMetadataHookUrl_in").value; + var mTag = document.getElementById("mc_t_AddMetadataHookTag_in").value; + var mValue = document.getElementById("mc_t_AddMetadataHookValue_in").value; + window.external.MediaCore.AddMetadataHook(mUrl,mTag,mValue); +} + +function mcRemoveMetadataHookClicked(){ + var mUrl = document.getElementById("mc_t_RemoveMetadataHookUrl_in").value; + var mTag = document.getElementById("mc_t_RemoveMetadataHookTag_in").value; + window.external.MediaCore.RemoveMetadataHook(mUrl,mTag); +} + +function teRegisterClicked(){ + var rc = window.external.Transport.RegisterForEvents(onEvents); + document.getElementById("teRegister").disabled = true; + document.getElementById("teUnregister").disabled = false; +} + +function teUnregisterClicked(){ + var rc = window.external.Transport.UnregisterFromEvents(onEvents); + document.getElementById("teRegister").disabled = false; + document.getElementById("teUnregister").disabled = true; +} + +var eventsArray = new Array(); +var eventCount = 0; +function onEvents(event){ + eventsArray[eventCount] = event; + + // populate the select box + var eventSelect = document.getElementById("te_s_Select"); + var newOption = new Option((eventCount + 1) + ":" + event.event, event); + eventSelect.options[eventCount] = newOption; + eventCount++; +} + +function teEventSelected(){ + var sel = document.getElementById("te_s_Select"); + var area = document.getElementById("te_ta_Area"); + var tarea = ""; + var obj = eventsArray[sel.selectedIndex]; + for (var prop in obj){ + tarea += "property:" + prop + " value:" + obj[prop] + "\n\n"; + } + area.value = tarea; +} + +function te_AreaCleared(){ + eventCount = 0; + document.getElementById("te_ta_Area").value = ""; + document.getElementById("te_s_Select").options.length = 0; +} + +function hisQueryClicked(){ + var query = document.getElementById("his_t_Query_in").value; + var respArray = window.external.History.Query(query); + alert(respArray[0].filename); + var textOut = ""; + for (var obj in respArray){ + if (textOut != ""){ + textOut += "\n"; + } + textOut += "=============="; + textOut += "\nTitle: " + respArray[obj].title; + textOut += "\nLastPlay: " + respArray[obj].lastplay; + textOut += "\nPlaycount: " + respArray[obj].playcount; + textOut += "\nFilename: " + respArray[obj].filename; + textOut += "\nLength: " + respArray[obj].length; + } + var textAreaOut = document.getElementById("his_t_Query"); + textAreaOut.value = textOut; +} + +function AsyncDownloadMediaClicked(){ + var url = document.getElementById("asyncdownloader_t_URL_in").value; + var destFile = document.getElementById("asyncdownloader_t_DestinationFile_in").value; + document.getElementById("progressbar").firstChild.nodeValue = ""; + document.getElementById("slider").style.clip = "rect(0px 0px 16px 0px)"; + if (destFile) + var rc = window.external.AsyncDownloader.DownloadMedia(url, destFile); + else + var rc = window.external.AsyncDownloader.DownloadMedia(url); +} + +function AsyncDownloadMediaClicked1(){ + var url = document.getElementById("asyncdownloader_t_URL_in_1").value; + var destFile = document.getElementById("asyncdownloader_t_DestinationFile_in_1").value; + document.getElementById("progressbar1").firstChild.nodeValue = ""; + document.getElementById("slider1").style.clip = "rect(0px 0px 16px 0px)"; + if (destFile) + var rc = window.external.AsyncDownloader.DownloadMedia(url, destFile); + else + var rc = window.external.AsyncDownloader.DownloadMedia(url); +} + +function AsyncDownloadMultipleMediaClicked() { + var multipleUrls = document.getElementById("multiple_urls").value; + var urls = multipleUrls.split(";"); + for(index = 0; index < urls.length; index++){ + if (urls[index].length > 0) { + if (urls[index].indexOf("http://") != -1) urls[index] = urls[index].substr(7); + var rc = window.external.AsyncDownloader.DownloadMedia("http://"+escape(urls[index])); + } + } +} + +function downloaderRegisterClicked(){ + var rc = window.external.AsyncDownloader.RegisterForEvents(onDownloaderEvents); + document.getElementById("downloaderRegister").disabled = true; + document.getElementById("downloaderUnregister").disabled = false; +} + +function downloaderUnregisterClicked(){ + var rc = window.external.AsyncDownloader.UnregisterFromEvents(onDownloaderEvents); + document.getElementById("downloaderRegister").disabled = false; + document.getElementById("downloaderUnregister").disabled = true; +} + +var downloaderEventsArray = new Array(); +var downloaderEventCount = 0; +function downloader_AreaCleared(){ + downloaderEventCount = 0; + document.getElementById("downloader_ta_Area").value = ""; + document.getElementById("downloader_s_Select").options.length = 0; +} + +function onDownloaderEvents(event){ + downloaderEventsArray[downloaderEventCount] = event; + + // populate the select box + var eventSelect = document.getElementById("downloader_s_Select"); + var newOption = new Option((downloaderEventCount + 1) + ":" + event.event, event); + eventSelect.options[downloaderEventCount] = newOption; + downloaderEventCount++; + + var progress, slider; + if (event.url == document.getElementById("asyncdownloader_t_URL_in").value) + { + progress = document.getElementById("progressbar"); + slider = document.getElementById("slider"); + } + if (event.url == document.getElementById("asyncdownloader_t_URL_in_1").value) + { + progress = document.getElementById("progressbar1"); + slider = document.getElementById("slider1"); + } + + if (progress && slider) + { + if (event.event == 'OnInit') + { + progress.firstChild.nodeValue = 'Progress: Start downloading ...'; + } + if (event.event == 'OnData') + { + progress.firstChild.nodeValue = 'Progress: Downloading ...'; + var factor = event.downloadedlen/event.totallen; + slider.firstChild.nodeValue = Math.ceil(factor * 100) + '%'; + slider.style.clip = "rect(0px " + parseInt(factor * 417) + "px 16px 0px)"; + } + if (event.event == 'OnFinish') + { + progress.firstChild.nodeValue = 'Progress: Downloading Succeed'; + slider.firstChild.nodeValue = '100%'; + } + if (event.event == 'OnError' || event.event == 'OnCancel') + { + progress.firstChild.nodeValue = 'Progress: Downloading Failed'; + } + } +} + +function downloaderEventSelected(){ + var sel = document.getElementById("downloader_s_Select"); + var area = document.getElementById("downloader_ta_Area"); + var tarea = ""; + var obj = downloaderEventsArray[sel.selectedIndex]; + if (obj.url) + tarea += "property:url value:" + obj.url + "\n\n"; + if (obj.event == 'OnData') + { + tarea += "property:downloadedlen value:" + obj.downloadedlen + "\n\n"; + tarea += "property:totallen value:" + obj.totallen + "\n\n"; + } + if (obj.event == 'OnFinish') + tarea += "property:destfilename value:" + obj.destfilename + "\n\n"; + if (obj.event == 'OnError') + tarea += "property:error value:" + obj.error + "\n\n"; + area.value = tarea; +}
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/applicationApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/applicationApi.htm new file mode 100644 index 00000000..96bf4137 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/applicationApi.htm @@ -0,0 +1,32 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Application Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Application API</h2> + <h3>Methods:</h3> + <input type="button" value="Launch URL" onclick="ApplicationLaunchURLClicked();"> + <br> + URL:<input type="text" size="20" id="application_t_URL_in" value="http://dev.winamp.com"> + <br> + Force External Browser:<input type="checkbox" checked="unchecked" id="application_t_ForceExternal_in"> + <h3>Properties:</h3> + <input type="button" value="Get number version" onclick="ApplicationNumVersionClicked();"> + <input type="text" readonly size="20" id="application_t_NumVersion"> + <br> + <br> + <input type="button" value="Get string version" onclick="ApplicationStringVersionClicked();"> + <input type="text" readonly size="20" id="application_t_StringVersion"> + <br> + <br> + <input type="button" value="Get language" onclick="ApplicationLanguageClicked();"> + <input type="text" readonly size="20" id="application_t_Language"> + <br> + <br> + <input type="button" value="Get languagepack" onclick="ApplicationLanguagePackClicked();"> + <input type="text" readonly size="20" id="application_t_LanguagePack"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/asyncDownloaderApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/asyncDownloaderApi.htm new file mode 100644 index 00000000..4aab77d1 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/asyncDownloaderApi.htm @@ -0,0 +1,42 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::AsyncDownloader Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <style type="text/css"> + #slider{position:absolute; left:20px; top:180px; width:420px; height:15px; clip:rect(0px 0px 15px 0px); background-color:#666699; text-align:left; color:#ffffff; font-size:12px;} + #slider1{position:absolute; left:20px; top:280px; width:420px; height:15px; clip:rect(0px 0px 15px 0px); background-color:#666699; text-align:left; color:#ffffff; font-size:12px;} + </style> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>AsyncDownloader API</h2> + <h3>Methods:</h3> + <input type="button" value="Download Media" onclick="AsyncDownloadMediaClicked();"> URL: <input type="text" size="40" id="asyncdownloader_t_URL_in"> Destination File: <input type="text" size="20" id="asyncdownloader_t_DestinationFile_in"> + <div id="progressbardiv"><h5 id="progressbar">Progress: </h5> + <br> + <div id="slider">0%</div> + </div> + <input type="button" value="Download Media" onclick="AsyncDownloadMediaClicked1();"> URL: <input type="text" size="40" id="asyncdownloader_t_URL_in_1"> Destination File: <input type="text" size="20" id="asyncdownloader_t_DestinationFile_in_1"> + <div id="progressbardiv1"><h5 id="progressbar1">Progress: </h5> + <br> + <div id="slider1">0%</div> + </div> + <input type="button" value="Download Multiple Medias" onclick="AsyncDownloadMultipleMediaClicked();"><br> URLs: <textarea cols="60" rows="10" id="multiple_urls"></textarea> + <br> + <h3>Events:</h3> + <input type="button" value="Register For Downloader Events" id="downloaderRegister" onclick="downloaderRegisterClicked();"> + <input type="button" value="Unregister From Downloader Events" id="downloaderUnregister" onclick="downloaderUnregisterClicked();"> + <br> + Callback function: <input readonly type="text" id="downloader_t_Callback" value="OnDownloaderEvents"> + <br><br> + <b>Events Received</b> + + <a href="javascript:downloader_AreaCleared();"><small>clear</small></a> + <br> + <select size="10" id="downloader_s_Select" style="width: 100px" onchange="downloaderEventSelected();"> + <option>No Events</option> + </select> + <textarea rows="10" cols="40" id="downloader_ta_Area"></textarea> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/bookmarkApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/bookmarkApi.htm new file mode 100644 index 00000000..c31bacb5 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/bookmarkApi.htm @@ -0,0 +1,17 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Bookmarks Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Bookmarks API</h2> + <h3>Methods:</h3> + <input type="button" value="Add Bookmark" onclick="BMarkAddClicked();"> + <br> + URL:<input type="text" size="20" id="bmark_t_AddURL_in"> + <br> + Title:<input type="text" size="20" id="bmark_t_AddTitle_in"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/configApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/configApi.htm new file mode 100644 index 00000000..a114144e --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/configApi.htm @@ -0,0 +1,28 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Config Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Config API</h2> + <h3>Methods:</h3> + <input type="button" value="Set Property" onclick="ConfigSetPropertyClicked();"> + <br> + Property Name:<input type="text" size="20" id="config_t_SetPropertyName_in" value="myProperty"> + <br> + Property Type: + <input type="radio" name="pType" id="config_t_SetPropertyType_in" checked>string</input> + <input type="radio" name="pType" id="config_t_SetPropertyType_in">number</input> + <input type="radio" name="pType" id="config_t_SetPropertyType_in">boolean</input> + <br> + Property Value:<input type="text" size="20" id="config_t_SetPropertyValue_in" value="myPropertyValue"> + <br><br> + <input type="button" value="Get Property" onclick="ConfigGetPropertyClicked();"> + <br> + Property Value:<input type="text" readonly size="20" id="config_t_GetPropertyValue"> + <br> + Property Name:<input type="text" size="20" id="config_t_GetPropertyName_in" value="myProperty"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/historyApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/historyApi.htm new file mode 100644 index 00000000..b7732c01 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/historyApi.htm @@ -0,0 +1,18 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::History Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>History API</h2> + <h3>Methods:</h3> + <input type="button" value="Query" onClick="hisQueryClicked();"> + <br> + <input type="text" size="80" value="LASTPLAY<[now]" id="his_t_Query_in"> + <br> + <textarea rows="24" cols="50" id="his_t_Query"> + </textarea> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/mediaCoreApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/mediaCoreApi.htm new file mode 100644 index 00000000..3daee11f --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/mediaCoreApi.htm @@ -0,0 +1,37 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::MediaCore Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>MediaCore API</h2> + <h3>Methods:</h3> + <input type="button" value="Get Metadata" onclick="mcGetMetadataClicked();"> + <input type="text" readonly size="40" id="mc_t_MediaCoreMetadata_Response"> + <br> + Filename: <input type="text" value="C:\Program Files\Winamp\demoedit.aac" id="mc_t_MediaCoreFilename_in"> + <br> + Metadata Tag: <input type="text" value="artist" id="mc_t_MediaCoreTag_in"> + <br><br> + <input type="button" value="Is Registered Extension" onclick="mcIsRegisteredExtensionClicked();"> + <input type="text" readonly size="40" id="mc_t_MediaCoreRegisteredExtension_Response"> + <br> + Extension: <input type="text" value=".mp3" id="mc_t_MediaCoreExtension_in"> + <br><br> + <input type="button" value="AddMetadataHook" onclick="mcAddMetadataHookClicked();"> + <br> + URL: <input type="text" size="50" id="mc_t_AddMetadataHookURL_in"> + <br> + Metadata Tag: <input type="text" id="mc_t_AddMetadataHookTag_in"> + <br> + Metadata Value: <input type="text" id="mc_t_AddMetadataHookValue_in"> + <br><br> + <input type="button" value="RemoveMetadataHook" onclick="mcRemoveMetadataHookClicked();"> + <br> + URL: <input type="text" size="50" id="mc_t_RemoveMetadataHookURL_in"> + <br> + Metadata Tag: <input type="text" id="mc_t_RemoveMetadataHookTag_in"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/playQueueApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/playQueueApi.htm new file mode 100644 index 00000000..6fc63c82 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/playQueueApi.htm @@ -0,0 +1,74 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::PlayQueue Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>PlayQueue API</h2> + <h3>Methods:</h3> + <input type="button" value="Play" onclick="pqPlayClicked();"> + <br> + URL: <input type="text" id="pq_t_PlayURL_in" value="c:\Documents and Settings\smontgo444\My Documents\My Music\Winamp\01 - Hello City.mp3"> + <br> + title: <input type="text" id="pq_t_PlayTitle_in"> + <br> + length: <input type="text" id="pq_t_PlayLength_in"> + <br> + <br> + <input type="button" value="Enqueue" onclick="pqEnqueueClicked();"> + <br> + URL: <input type="text" id="pq_t_EnqueueURL_in" value="c:\Documents and Settings\smontgo444\My Documents\My Music\Winamp\01 - Hello City.mp3"> + <br> + title: <input type="text" id="pq_t_EnqueueTitle_in"> + <br> + length: <input type="text" id="pq_t_EnqueueLength_in"> + <br> + <br> + <input type="button" value="Insert" onclick="pqInsertClicked();"> + <br> + position: <input type="text" id="pq_t_InsertPosition_in" value="0"> + <br> + URL: <input type="text" id="pq_t_InsertURL_in" value="c:\Documents and Settings\smontgo444\My Documents\My Music\Winamp\08 - The King Of Bedside Manor.mp3"> + <br> + title: <input type="text" id="pq_t_InsertTitle_in"> + <br> + length: <input type="text" id="pq_t_InsertLength_in"> + <br> + <br> + <input type="button" value="Clear Queue" onclick="pqClearQClicked();"> + <br> + <br> + <input type="button" value="Get Metadata" onclick="pqGetMetadataClicked();"> + <input type="text" readonly size="40" id="pq_t_MTag_Response"> + <br> + position: <input type="text" value="0" id="pq_t_MetadataPosition_in"> + <br> + Metadata Tag: <input type="text" value="artist" id="pq_t_MTag_in"> + <br> + <br> + <input type="button" value="Get Title" onclick="pqGetTitleClicked();"> + <input type="text" readonly size="20" id="pq_t_Title"> + <br> + position: <input type="text" value="0" id="pq_t_TitlePosition_in"> + <br> + <br> + <input type="button" value="Get URL" onclick="pqGetURLClicked();"> + <input type="text" readonly size="20" id="pq_t_URL"> + <br> + position: <input type="text" value="0" id="pq_t_URLPosition_in"> + <br> + <br> + <h2>Properties</h2> + <input type="button" value="Get length" onclick="pqGetLengthClicked();"> + <input type="text" readonly size="20" id="pq_t_Length"> + <br> + <br> + <input type="button" value="Get cursor" onclick="pqGetCursorClicked();"> + <input type="text" readonly size="20" id="pq_t_Cursor"> + <br> + <input type="button" value="Set cursor" onclick="pqSetCursorClicked();"> + <input type="text" size="20" id="pq_t_Cursor_in"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/playlistApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/playlistApi.htm new file mode 100644 index 00000000..1553e875 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/playlistApi.htm @@ -0,0 +1,118 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Playlists Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body onload="plsDisablePlaylistMethods(true);plsDisableListMethods(true);" style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Playlists API</h2> + <p><small>Since it is hard to obtain a playlist ID to use in the OpenPlaylist and SavePlaylist methods, click "Get Playlists" to get all the playlists and then "Set Index" to choose one of the playlists. This will pre-populate the playlist IDs for the OpenPlaylist and SavePlaylist buttons.</small> + <h3>Methods:</h3> + <input type="button" value="Get Playlists" onclick="plsGetPlaylists();"> + <br> + Count (of playlists):<input type="text" readonly size="20" id="pls_t_Count"> + <br> + <input type="button" value="Set Playlist Index" onclick="plsViewIndexClicked();"> + <input type="text" size="10" value="0" id="pls_t_Index_in"> + <br> + <br> + Playlist Summary Info: + <br> + Playlist ID: <input type="text" readonly size="60" id="pls_t_PlaylistId"> + <br> + Playlist Num Items: <input type="text" readonly size="20" id="pls_t_NumItems"> + <small>(cached, may not be current)</small> + <br> + Playlist Filename: <input type="text" size="80" id="pls_t_Filename"> + <br> + Playlist Title: <input type="text" size="80" id="pls_t_Title"> + <br> + Playlist (total) Length: <input type="text" readonly size="20" id="pls_t_Length"> + <small>(cached, may not be current)</small> + <br> + <br> + <input type="button" value="OpenPlaylist" onclick="plsOpenPlaylistClicked();"> + <small>(will also display the playlist)</small> + <br> + Count (of items in playlist):<input type="text" readonly size="20" id="playlist_t_NumItems"> + <br> + Playlist ID: <input type="text" size="60" id="pls_t_OpenPlaylistId_in"> + <br> + <input type="button" value="Set Item Index" onclick="plsPlaylistViewIndexClicked()"> + <input type="text" size="10" value="0" id="playlist_t_ItemIndex_in"> + <br> + <br> + <div id="playlistmethods"> + Get Item Filename: <input type="text" size="80" id="playlist_t_Filename"> + <br> + Get Item Title: <input type="text" size="80" id="playlist_t_Title"> + <br> + Get Item Length: <input type="text" readonly size="20" id="playlist_t_Length"> + <br> + <br> + <input type="button" value="Set Item Filename" onclick="plsPlaylistSetItemFilenameClicked();"> + <br> + Item Filename: <input type="text" size="80" id="playlist_t_SetItemFilename_in"> + <br> + <input type="button" value="Set Item Title" onclick="plsPlaylistSetItemTitleClicked();"> + <br> + Item Title: <input type="text" size="80" id="playlist_t_SetItemTitle_in"> + <br> + <input type="button" value="Set Item Length" onclick="plsPlaylistSetItemLengthClicked();"> + <br> + Item Length: <input type="text" id="playlist_t_SetItemLength_in"> + <br> + <br> + <input type="button" value="Remove" onclick="plsPlaylistRemoveClicked();"> + <br> + <br> + <input type="button" value="Insert URL" onclick="plsPlaylistInsertUrlClicked();"> + <small>(before the currently selected index)</small> + <br> + URL: <input type="text" size="80" id="playlist_t_InsertURL_in"> + <br> + title: <input type="text" size="80" id="playlist_t_InsertTitle_in"> + <br> + length: <input type="text" size="20" id="playlist_t_InsertLength_in"> + <br> + </div> + <div id="listmethods"> + <br> + <input type="button" value="Append URL" onclick="plsPlaylistAppendUrlClicked();"> + <br> + URL: <input type="text" size="80" id="playlist_t_AppendURL_in"> + <br> + title: <input type="text" size="80" id="playlist_t_AppendTitle_in"> + <br> + length: <input type="text" size="20" id="playlist_t_AppendLength_in"> + <br> + <br> + <input type="button" value="Reverse" onclick="plsPlaylistReverseClicked();"> + <br> + <br> + <input type="button" value="Swap Items" onclick="plsPlaylistSwapItemsClicked();"> + <br> + Index #1: <input type="text" value="0" id="playlist_t_Swap1_in"> + <br> + Index #2: <input type="text" value="1" id="playlist_t_Swap2_in"> + <br> + <br> + <input type="button" value="Randomize" onclick="plsPlaylistRandomizeClicked();"> + <br> + <br> + <input type="button" value="Sort By Title" onclick="plsPlaylistSortByTitleClicked();"> + <br> + <br> + <input type="button" value="Sort By Filename" onclick="plsPlaylistSortByFilenameClicked();"> + <br> + <br> + <input type="button" value="Clear" onclick="plsPlaylistClearClicked();"> + </div> + <br> + <br> + <input type="button" value="SavePlaylist" onclick="plsSavePlaylistClicked();"> + <br> + Playlist ID: <input type="text" size="80" id="pls_t_SavePlaylistId_in"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/podcastApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/podcastApi.htm new file mode 100644 index 00000000..5008aba7 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/podcastApi.htm @@ -0,0 +1,15 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Podcast Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Podcasts API</h2> + <h3>Methods:</h3> + <input type="button" value="Subscribe URL" onclick="PodcastSubscribeClicked();"> + <br> + URL:<input type="text" size="20" id="podc_t_SubscribeURL_in" value="http://services.winamp.com/rss/news"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/securityApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/securityApi.htm new file mode 100644 index 00000000..72850262 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/securityApi.htm @@ -0,0 +1,17 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Security Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Security API</h2> + <h3>TBD</h3> + <!-- <h2>Methods:</h2> + <input type="button" value="Get Action Authorization" onclick="SecurityGetAuthorizationClicked();"> + <br> + URL:<input type="text" readonly size="20" id="security_t_Authorization"> + --> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/serviceEditor.htm b/Src/Plugins/Library/ml_webdev/resources/pages/serviceEditor.htm new file mode 100644 index 00000000..c23c73a2 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/serviceEditor.htm @@ -0,0 +1,31 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>Online Services Editor</title> + <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema"/> + <meta content="True" name="vs_snapToGrid"/> + <meta content="False" name="vs_showGrid"/> + <meta http-equiv="content-type" content="text/html;charset=utf-8"/> + <script src="webdev.js" type="text/javascript"></script> + <style type="text/css">#Checkbox1 {width: 321px; top: 160px; left: 64px;}</style> +</head> +<body style="overflow-y: auto; overflow-x: auto; overflow: visible; FONT-FAMILY: MS Shell Dlg 2;" onload="WebDevEditor_Init();"> + <h2 align="center">Online Services Editor</h2> + <div align="left" nowrap> + <div id="DIV1" style="border: 1px solid gray; clear: both; DISPLAY: block; left: 50%; float: none; visibility: visible; margin-left: -204px; overflow: visible; width: 408px; color: black; position: absolute; height: 217px; background-color: dimgray; top: 126px;" align="center" nowrap ms_positioning="GridLayout"> + <div style="z-index: 110; left: 16px; position: absolute; top: 14px">Id:</div> + <input id="scvedt_edt_id" style="z-index: 101; left: 64px; position: absolute; top: 14px" readonly maxlength="16" size="9" tabindex="1"/> + <div style="z-index: 102; left: 16px; position: absolute; top: 46px">Name:</div> + <input id="scvedt_edt_name" style="z-index: 103; left: 64px; position: absolute; top: 46px; width: 322px;" maxlength="512" size="48" tabindex="2"/> + <div style="z-index: 104; left: 16px; position: absolute; top: 78px">Url:</div> + <input id="scvedt_edt_url" style="z-index: 105; left: 64px; position: absolute; top: 78px; width: 321px;" maxlength="2048" size="48" name="Text1" tabindex="3"/> + <div style="z-index: 106; left: 16px; position: absolute; top: 110px">Icon:</div> + <input id="scvedt_edt_icon" style="z-index: 107; left: 64px; position: absolute; top: 110px; width: 321px;" maxlength="512" size="48" name="Text2" tabindex="4"/> + <div align = "left" style="z-index: 108; position: absolute; width: 320px; top: 143px; left: 60px;" > + <input id="svcedt_chk_bypass" name="Checkbox1" tabindex="5" title="Preauthorized service" type="checkbox" value="bypass"/>Preauthorized service</div> + <input id="svcedt_btn_save" style="z-index: 109; left: 200px; width: 88px; position: absolute; top: 180px; height: 24px; right: 118px;" onclick="WebDevEditor_Save();" type="submit" value="Save" name="buttonOk" tabindex="6"/> + <input id="svcedt_btn_close" style="z-index: 110; left: 297px; width: 88px; position: absolute; top: 180px; height: 24px" onclick="WebDevEditor_Close();" type="button" value="Cancel" name="buttonCancel" tabindex="7"/> + </div> + </div> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/skinApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/skinApi.htm new file mode 100644 index 00000000..425c3217 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/skinApi.htm @@ -0,0 +1,40 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Skin Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Skin API</h2> + <h3>Methods:</h3> + <input type="button" value="Get Classic Color" onclick="SkinGetClassicColorClicked();"> + <input type="text" size="20" id="skin_t_ClassicColor"> + <br> + color number:<input type="text" size="20" id="skin_t_ClassicColorNumber_in" value="1"> + <br><br> + <input type="button" value="Get Playlist Color" onclick="SkinGetPlaylistColorClicked();"> + <input type="text" readonly size="20" id="skin_t_PlaylistColor"> + <br> + color number:<input type="text" size="20" id="skin_t_PlaylistColorNumber_in" value="1"> + <br><br> + <input type="button" value="Get Skin Color" onclick="SkinGetSkinColorClicked();"> + <input type="text" readonly size="20" id="skin_t_SkinColor"> + <br> + color name:<input type="text" size="20" id="skin_t_SkinColorName_in" value="wasabi.text.color"> + <br> + <h3>Properties:</h3> + <input type="button" value="Get name" onclick="SkinGetNameClicked();"> + <input type="text" readonly size="20" id="skin_t_Name"> + <br> + <input type="button" value="Set name" onclick="NotImplementedYet();"> + <!-- <input type="button" value="Set name" onclick="SkinSetNameClicked();"> --> + <input type="text" size="20" id="skin_t_Name_in" value="Bento"> + <br><br> + <input type="button" value="Get font" onclick="SkinGetFontClicked();"> + <input type="text" readonly size="20" id="skin_t_Font"> + <br><br> + <input type="button" value="Get fontsize" onclick="SkinGetFontSizeClicked();"> + <input type="text" readonline size="20" id="skin_t_FontSize"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/transportApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/transportApi.htm new file mode 100644 index 00000000..c2f9d70d --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/transportApi.htm @@ -0,0 +1,64 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Transport Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Transport API</h2> + <h3>Methods:</h3> + <input type="button" value="Prev" onclick="tPrevClicked();"> + <input type="button" value="Play" onclick="tPlayClicked();"> + <input type="button" value="Pause" onclick="tPauseClicked();"> + <input type="button" value="Stop" onclick="tStopClicked();"> + <input type="button" value="Next" onclick="tNextClicked();"> + <br> + <br> + <input type="button" value="Get Metadata" onclick="tGetMetadataClicked();"> + <input type="text" readonline size="40" id="t_t_mTag_Response"> + <br> + Metadata Tag: <input type="text" value="artist" id="t_t_mTag_in"> + <br> + <h3>Properties</h3> + <input type="button" value="Get shuffle" onclick="tGetShuffleClicked();"> + <input type="text" readonline size="20" id="t_t_shuffle"> + <br> + <input type="button" value="Set shuffle" onclick="tSetShuffleClicked();"> + <input type="text" size="20" id="t_t_shuffle_in"> + <br> + <br> + <input type="button" value="Get repeat" onclick="tGetRepeatClicked();"> + <input type="text" readonly size="20" id="t_t_repeat"> + <br> + <input type="button" value="Set repeat" onclick="tSetRepeatClicked();"> + <input type="text" size="20" id="t_t_repeat_in"> + <br> + <br> + <input type="button" value="Get position" onclick="tGetPositionClicked();"> + <input type="text" readonly size="20" id="t_t_position"> + <br> + <input type="button" value="Set position" onclick="tSetPositionClicked();"> + <input type="text" size="20" id="t_t_position_in"> + <br> + <br> + <input type="button" value="Get length" id="b_t_length" onclick="tLengthClicked();"> + <input type="text" readonly size="20" id="t_t_Length"> + <br> + <br> + <input type="button" value="Get url" id="b_t_url" onclick="tURLClicked();"> + <input type="text" size="95" id="t_t_URL"> + <br> + <br> + <input type="button" value="Get title" id="b_t_title" onclick="tTitleClicked();"> + <input type="text" size="95" id="t_t_Title"> + <br> + <br> + <input type="button" value="Get playing" id="b_t_playing" onclick="tPlayingClicked();"> + <input type="text" readonly size="20" id="t_t_Playing"> + <br> + <br> + <input type="button" value="Get paused" id="b_t_paused" onclick="tPausedClicked();"> + <input type="text" readonly size="20" id="t_t_Paused"> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/transportEventsApi.htm b/Src/Plugins/Library/ml_webdev/resources/pages/transportEventsApi.htm new file mode 100644 index 00000000..61d91e2b --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/transportEventsApi.htm @@ -0,0 +1,25 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Transport Events Api</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> +</head> +<body onload="teUnregisterClicked();" onunload="teUnregisterClicked();" style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Transport Events API</h2> + <h3>Methods:</h3> + <input type="button" value="Register For Events" id="teRegister" onclick="teRegisterClicked();"> + <input type="button" value="Unregister From Events" id="teUnregister" onclick="teUnregisterClicked();"> + <br><br> + Callback function: <input readonly type="text" id="te_t_Callback" value="OnEvents"> + <br><br><br> + <b>Events Received</b> + + <a href="javascript:te_AreaCleared();"><small>clear</small></a> + <br><br> + <select size="10" id="te_s_Select" style="width: 100px" onchange="teEventSelected();"> + <option>No Events</option> + </select> + <textarea rows="10" cols="40" id="te_ta_Area"></textarea> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/webdev.htm b/Src/Plugins/Library/ml_webdev/resources/pages/webdev.htm new file mode 100644 index 00000000..b48a8515 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/webdev.htm @@ -0,0 +1,29 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>JSAPI2::Main Page</title> + <meta http-equiv="content-type" content="text/html;charset=utf-8"> + <script type="text/javascript" src="api2.js"></script> + <script type="text/javascript" src="webdev.js"></script> +</head> +<body style="FONT-FAMILY: MS Shell Dlg 2;"> + <h2>Winamp Online Services API - Test Web Page</h2> + <small> + <p>This page is to help with testing the different API methods of the Winamp Javascript API. In order to point Winamp to your own online service, click <a href="javascript:void(0);" onclick="WebDev_CreateService(); return false;">here</a> and set the URL to the URL of the main page of your service when prompted.</p> + <p>Check the <a target="_blank" href="http://dev.winamp.com/wiki/Complete_JavaScript_API_technology_framework">Winamp Javascript API</a> for more info on the API methods used on these test web pages.</p> + <a href="transportApi.htm">Transport API</a><br><br> + <a href="transportEventsApi.htm">Transport Events</a><br><br> + <a href="playQueueApi.htm">Playqueue API</a><br><br> + <a href="playlistApi.htm">Playlists API</a><br><br> + <a href="bookmarkApi.htm">Bookmarks API</a><br><br> + <a href="podcastApi.htm">Podcasts API</a><br><br> + <a href="historyApi.htm">History API</a><br><br> + <a href="configApi.htm">Config API</a><br><br> + <a href="applicationApi.htm">Application API</a><br><br> + <a href="securityApi.htm">Security API</a><br><br> + <a href="skinApi.htm">Skins API</a><br><br> + <a href="mediaCoreApi.htm">MediaCore API</a><br><br> + <a href="asyncDownloaderApi.htm">AsyncDownloader API</a> + </small> +</body> +</html>
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/webdev.js b/Src/Plugins/Library/ml_webdev/resources/pages/webdev.js new file mode 100644 index 00000000..14f5d199 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/webdev.js @@ -0,0 +1,97 @@ +function GetUrlParam(name) +{ + name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]"); + var regexS = "[\\?&]"+name+"=([^&#]*)"; + var regex = new RegExp( regexS ); + var results = regex.exec( window.location.href ); + if( results == null ) + return ""; + else + return results[1]; +} + +function WebDev_OpenService(serviceId, forceUrl) +{ + if (typeof(window.external.WebDev) == "undefined") + alert("Cannot access Webdev Api"); + else if (false == window.external.WebDev.serviceOpen(serviceId, forceUrl)) + alert("Unable to open service"); +} +function WebDev_OpenDocumentation() +{ + WebDev_OpenService(701, null); +} + +function WebDev_OpenJSAPI2Test() +{ + WebDev_OpenService(702, null); +} + +function WebDev_CreateService() +{ + if (typeof(window.external.WebDev) == "undefined") + alert("Cannot access Webdev Api"); + else if (false == window.external.WebDev.serviceCreate()) + alert("Unable to create service"); +} + +function WebDevEditor_Init(url) +{ + var serviceId = parseInt(GetUrlParam("serviceId"), 10); + + if (typeof(window.external.WebDev) == "undefined") + alert("Cannot access Webdev Api"); + else + { + var info = window.external.WebDev.serviceGetInfo(serviceId); + if (null == info) + { + alert("Unable to get service information"); + } + else + { + document.getElementById("scvedt_edt_id").value = info.id; + document.getElementById("scvedt_edt_name").value = info.name; + document.getElementById("scvedt_edt_url").value = info.url; + document.getElementById("scvedt_edt_icon").value = info.icon; + document.getElementById("svcedt_chk_bypass").checked = (true == info.preauthorized) ? "checked" : null; + } + } +} + +function WebDevEditor_Save() +{ + if (typeof(window.external.WebDev) == "undefined") + alert("Cannot access Webdev Api"); + else + { + var serviceId = parseInt(document.getElementById("scvedt_edt_id").value, 10); + if (0 != serviceId) + { + var serviceName = document.getElementById("scvedt_edt_name").value; + var serviceUrl = document.getElementById("scvedt_edt_url").value; + var serviceIcon = document.getElementById("scvedt_edt_icon").value; + var serviceAuth = document.getElementById("svcedt_chk_bypass").checked; + if (false == window.external.WebDev.serviceSetInfo(serviceId, serviceName, serviceIcon, serviceUrl, serviceAuth)) + { + alert("Unable to set service info"); + } + if (false == window.external.WebDev.serviceOpen(serviceId, 1)) + { + alert("Unable to navigate"); + } + } + } +} + +function WebDevEditor_Close() +{ + if (typeof(window.external.WebDev) == "undefined") + alert("Cannot access Webdev Api"); + else + { + var serviceId = parseInt(document.getElementById("scvedt_edt_id").value, 10); + if (0 == serviceId || false == window.external.WebDev.serviceOpen(serviceId, 1)) + alert("Unable to navigate"); + } +}
\ No newline at end of file diff --git a/Src/Plugins/Library/ml_webdev/resources/pages/welcome.htm b/Src/Plugins/Library/ml_webdev/resources/pages/welcome.htm new file mode 100644 index 00000000..a89bc2c5 --- /dev/null +++ b/Src/Plugins/Library/ml_webdev/resources/pages/welcome.htm @@ -0,0 +1,22 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>WebDev Home Page</title> + <meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5"> + <meta name="vs_snapToGrid" content="True"> + <meta name="vs_showGrid" content="True"> + <meta content="text/html;charset=utf-8" http-equiv="content-type"> + <script type="text/javascript" src="webdev.js"></script> +</head> +<body style="OVERFLOW-Y: auto; OVERFLOW-X: auto; OVERFLOW: visible; FONT-FAMILY: MS Shell Dlg 2;"> + <div align="left"> + <div style="DISPLAY: inline; FONT-WEIGHT: bold; FONT-SIZE: x-large; LEFT: 50%; MARGIN-LEFT: -216px; WIDTH: 432px; POSITION: absolute" id="DIV4" ms_positioning="FlowLayout" language="javascript" onclick="return DIV2_onclick()" align="center">Welcome to WebDev</DIV> + <div style="DISPLAY: inline; FONT-SIZE: 9pt; LEFT: 50%; MARGIN-LEFT: -212px; WIDTH: 424px; POSITION: absolute; TOP: 96px; HEIGHT: 248px" ms_positioning="FlowLayout" align="justify" id='DIV1"'> + <p>The Webdev plug-in is designed to help with the process of creating Online Services for Winamp. The plug-in uses the same browser engine as the Online Media plug-in in the Media Library and also has access to JSAPI2, making it perfect for you to work with.</p> + <p>If you have any questions about how to write an Online Service or just want to share knowledge with others - the <a href="javascript:void(0);" onclick="WebDev_OpenDocumentation(); return false;">Online Documentation</a> is your best friend.</p> + <p>New to JSAPI? Want to know what it is capable of and see the client web interaction with your own eyes? Then visit the <a href="javascript:void(0);" onclick="WebDev_OpenJSAPI2Test(); return false;">JSAPI2 Test Page</a>.</p> + <p>Having your own service is always better than using another, so if you feel like it is time to change the world - <a href="javascript:void(0);" onclick="WebDev_CreateService(); return false;">Create Your Own Service</a> and make the world a better place!</p> + </div> + </div> +</body> +</html>
\ No newline at end of file |