IPB

Welcome Guest ( Log In | Register )

130 Pages V  « < 100 101 102 103 104 > »   
Reply to this topicStart new topic
WSH Panel Mod script discussion/help
ExtremeHunter
post Aug 8 2013, 23:06
Post #2526





Group: Members
Posts: 133
Joined: 5-October 08
From: Estonia
Member No.: 59398



add this function to your wsh panel script

function on_mouse_rbtn_up(x, y) {
return true;
}
Go to the top of the page
+Quote Post
drm200
post Aug 9 2013, 05:45
Post #2527





Group: Members
Posts: 10
Joined: 8-February 11
Member No.: 88007



thanks. adding that fixed the problem ... I'm not sure how I could have figured that out on my own ...
Go to the top of the page
+Quote Post
mire777
post Aug 9 2013, 16:49
Post #2528





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



QUOTE (phool @ Aug 8 2013, 19:57) *
Hi ExtremeHunter, last time I tried your spinning disk script (for the current version of wsh panel mod, the rotation wan't as smooth as I expected. Is it possible to simulate the effect on this website: http://fanart.tv/artist/477b8c0c-c5fc-4ad2...uuren-van-armin (scroll down to the CDART section)?



I don't see problem in animation. You can simulate that smooth efect from website..
I got the same speed and smooth like in website..

Go to script and set ''angle += 1''
, and ''var rotationInterval = 15;'' .

Set rotationInterval speed how you like..
Hope that helps..

This post has been edited by mire777: Aug 9 2013, 16:55
Go to the top of the page
+Quote Post
mire777
post Aug 10 2013, 10:53
Post #2529





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



I made a modified xch4nge menu, which allows you to easily add as much panel and WSH scripts in CUI, as you want: http://mire777.deviantart.com/art/xch4nge-...oobar-359868460
But I noticed that when you starting foobar, if you have a lot of WSH panel, it parsing all WSH script together at startup.. Even if you don't have all that panel active, it start all WSH, and thus slows down the rising time.
Is there a way to make something, which would specify to raise only selected WSH scripts in selected panel at startup, and others to be inactive?
Or to specify that in each script separately ?
I'm trying to find a way to disable-enable installed WSH script at startup...

This post has been edited by mire777: Aug 10 2013, 11:02
Go to the top of the page
+Quote Post
marc2003
post Aug 10 2013, 11:37
Post #2530





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



you can try the delay load checkbox in the editor. but having numerous scripts really shouldn't affect startup time much at all. i guess it depends on what your script does. i have 17 scripts in my layout and it adds 0.2 seconds to the startup time compared to without. that's nothing in the grand scheme of things.
Go to the top of the page
+Quote Post
mire777
post Aug 10 2013, 13:20
Post #2531





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



QUOTE (marc2003 @ Aug 10 2013, 12:37) *
you can try the delay load checkbox in the editor. but having numerous scripts really shouldn't affect startup time much at all. i guess it depends on what your script does. i have 17 scripts in my layout and it adds 0.2 seconds to the startup time compared to without. that's nothing in the grand scheme of things.

Well i have 12 scripts, and startup time is 0.04 sec. It's nothing, but it would be good to add something, that would (disable-enable) script that I don't use that often.
Maybe some WSH client, with dropdown menu, then i can choose, what script i want to use in that panel..
But I don't know if it would help at all..
Go to the top of the page
+Quote Post
mire777
post Aug 13 2013, 10:38
Post #2532





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



Marc, i edited your script to show 'album art' on my WSH 1.4.2. , and it works beautifuly. There's no better script anywhere. No image distortion at all, like in other script i try.
But i have small problem, when i click on button in xch4nge to enlarge panel, image for a short shaking, then stop.
It happens especially when the image is large..
Do you know what causes this? And can you help me to fix this?

Here is script: http://pastebin.com/pCTpyvDD
Go to the top of the page
+Quote Post
marc2003
post Aug 13 2013, 12:31
Post #2533





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



QUOTE (mire777 @ Aug 13 2013, 10:38) *
But i have small problem, when i click on button in xch4nge to enlarge panel, image for a short shaking, then stop.


i have no idea what you mean by this. all i know is that my script behaves just like any other panel when resized normally in a standard default UI or columns UI layout. i'm certainly not downloading the theme to test it.

perhaps the issue is with the panel stack splitter code used to resize panels? have you tried other panels in its place?
Go to the top of the page
+Quote Post
mire777
post Aug 13 2013, 13:45
Post #2534





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



QUOTE (marc2003 @ Aug 13 2013, 13:31) *
QUOTE (mire777 @ Aug 13 2013, 10:38) *
But i have small problem, when i click on button in xch4nge to enlarge panel, image for a short shaking, then stop.


i have no idea what you mean by this. all i know is that my script behaves just like any other panel when resized normally in a standard default UI or columns UI layout. i'm certainly not downloading the theme to test it.

perhaps the issue is with the panel stack splitter code used to resize panels? have you tried other panels in its place?



I tested, it behaves normal in DUI, but in xch4nge it has some interaction with WSH panel stack splitter, because it has fast resizing..
Sorry I bothered you with that...
Go to the top of the page
+Quote Post
kjllmeplz
post Aug 19 2013, 10:11
Post #2535





Group: Members
Posts: 30
Joined: 7-January 13
Member No.: 105671



May I ask a question, How to show or hide a Columns UI panel using WSH script ?
Go to the top of the page
+Quote Post
Falstaff
post Aug 19 2013, 19:52
Post #2536





Group: Members
Posts: 2800
Joined: 12-November 06
Member No.: 37463



QUOTE (kjllmeplz @ Aug 19 2013, 11:11) *
May I ask a question, How to show or hide a Columns UI panel using WSH script ?


quick reply on the way to do it but not a full example (not time and no example on the hand ... just how i've done it in my skin TECH for example ==> http://br3tt.deviant.art)

So, the only way i've found (and use) is to use file as parameters, to share/update panel status between a WSH panel (the WSH panel create the file, update its status on action in the WSH panel) and a Panel Stack Splitter in Columns UI (use the $findfile command to read the file created from WSH panel to get the value of the status, 0 panel is to hide (cf. $showpanel ... commands , read Panel Stack Splitter help file for more information)

that's it.

for example, if i want to hide/show a panel like "album list", in the WSH panel, i create in a settings folder (i.e foobar2000/WSH_settings/) the file "albumlist_0"
and in the PSS panel, i get the last character of the filename that begins with "albumlist_" with $right($findfile(albumlist_*),1) and so i retrieve "0" or "1", depending of that value with a $select, i execute a $showpanel_c(...) set to visible or hidden of the album list panel...

tips, when updating the file from WSH, to force Panel Stack Splitter to refresh, you have to code in the WSH panel a Pause & Play foobar2000 command tongue.gif
there is the function i use to do it:
CODE
function RefreshBG() {
    if(fb.IsPlaying||fb.IsPaused) {
        fb.RunMainMenuCommand("Playback/Play or Pause");
        fb.RunMainMenuCommand("Playback/Play or Pause");
    } else {
        fb.RunMainMenuCommand("Playback/Play");
        fb.RunMainMenuCommand("Playback/Stop");
    }
}

HTH


This post has been edited by Falstaff: Aug 19 2013, 19:53


--------------------
http://br3tt.online.fr/
Go to the top of the page
+Quote Post
kjllmeplz
post Aug 20 2013, 06:14
Post #2537





Group: Members
Posts: 30
Joined: 7-January 13
Member No.: 105671



@Falstaff : Thanks you so much! biggrin.gif

This post has been edited by kjllmeplz: Aug 20 2013, 06:14
Go to the top of the page
+Quote Post
hkg196418
post Aug 29 2013, 23:21
Post #2538





Group: Members
Posts: 2
Joined: 29-August 13
Member No.: 109877



I am sorry, May I ask is it possible to drag&drop new songs like below?

for example:

playlist before drag&drop
1. SONG ONE
2. SONG TWO

playlist after drag&drop (I want to drop "SONG THREE" between "SONG ONE" and "SONG TWO")
1. SONG ONE
2. SONG THREE
3. SONG TWO

but not
1. SONG ONE
2. SONG TWO
3. SONG THREE

I am now viewing the old replies on this post, but it's very long, hope anyone can help me.

thank you very much

This post has been edited by hkg196418: Aug 29 2013, 23:28
Go to the top of the page
+Quote Post
Noose6767
post Sep 6 2013, 08:50
Post #2539





Group: Members
Posts: 3
Joined: 30-August 13
Member No.: 109890



Could someone tell me where to download the latest samples from please ?
(I think i'm interested in thumbs.txt and last fm bio etc)

The links I've found here seem to be down

Thanks a lot
Go to the top of the page
+Quote Post
marc2003
post Sep 6 2013, 08:56
Post #2540





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



here: https://dl.dropboxusercontent.com/u/22801321/wsh/samples.zip

make sure to check the readme. also, i saw your other post about reading the contents of a text file. there is a script in here called simple text reader which can do that.
Go to the top of the page
+Quote Post
derty2
post Sep 11 2013, 23:55
Post #2541





Group: Members
Posts: 584
Joined: 5-June 11
Member No.: 91257



ExtremeHunter

I've been playing around again with your Spinning Disc Image Viewer script, version 2013-08-08, which you pasted online here [pastebin.com] .

I've been editing your script for the past few hours, trying to create a context menu having these three items:
------------------------------
Open folder of this disc
Open folder of this panel
Configure...

-------------------------------

The context menu works except for one problem . . . . . Selecting "Open folder of this disc" opens the "Now Playing" folder and the active track is selected in Windows Explorer.
Unfortunately, this is not what I want . . . . . What I want is to open the folder containing the current spinning disc image and the image is selected in Windows Explorer.
Here is the code I have added to your script:
CODE
var WshShell = new ActiveXObject("WScript.Shell");
var fso = new ActiveXObject("Scripting.FileSystemObject");
MF_GRAYED = 0x00000001;
MF_STRING = 0x00000000;

function on_mouse_rbtn_up(x, y) {
    metadb = fb.GetNowPlaying();
    var folder_path_disc = metadb ? metadb.Path : "";    
    var folder_path_panel = fb.ProfilePath + "user-addons\\wsh-spinning-disc-image";
    var _menu = window.CreatePopupMenu();
    var idx = 0;
    _menu.AppendMenuItem(fso.FileExists(folder_path_disc) && metadb ? MF_STRING : MF_GRAYED, 1,  "Open folder of this disc");
    _menu.AppendMenuSeparator();
    _menu.AppendMenuItem(fso.FolderExists(folder_path_panel) && metadb ? MF_STRING : MF_GRAYED, 2,  "Open folder of this panel");
    _menu.AppendMenuSeparator();    
    _menu.AppendMenuItem(MF_STRING, 100, "Configure...");
    idx = _menu.TrackPopupMenu(x, y);
    if (idx == 1) try {
        WshShell.Run("explorer /select," + "\"" + folder_path_disc + "\"");        
        }            
        catch(e) { }
    if (idx == 2) try {
        WshShell.Run("explorer /n," + folder_path_panel);        
        }            
        catch(e) { }        
    if (idx == 100) window.ShowConfigure();
    _menu.Dispose();
    return true;    
}


NOTES:
I use foobar2000 in portable mode.
All default resources used for this panel are contained in one folder: "<fb2k_dir>\user-addons\wsh-spinning-disc-image\"
All disc image targets for the script are placed at the same location as the tracks.

ONE MORE QUESTION:
If I was to add one more context menu item named Help, and if this is selected a Message Box pops up with some text,
does anybody have the code for doing this?

This post has been edited by derty2: Sep 12 2013, 00:03
Go to the top of the page
+Quote Post
marc2003
post Sep 12 2013, 00:19
Post #2542





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



CODE
fb.ShowPopupMessage("Some help text.", "Window title");


you can put in \n if you want line breaks. i'll let Extremehunter answer the rest.

edited: i forgot you can customise the window title as well but it's optional. if you omit it, it will just display WSH Panel Mod.

This post has been edited by marc2003: Sep 12 2013, 00:26
Go to the top of the page
+Quote Post
ExtremeHunter
post Sep 12 2013, 11:36
Post #2543





Group: Members
Posts: 133
Joined: 5-October 08
From: Estonia
Member No.: 59398



derty2

pastebin link

This post has been edited by ExtremeHunter: Sep 12 2013, 11:44
Go to the top of the page
+Quote Post
marc2003
post Sep 12 2013, 12:47
Post #2544





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



i think derty2 was asking for it to work in portable mode. this line of code only works on a standard install.

CODE
var folder_path_panel = WshShell.ExpandEnvironmentStrings("%APPDATA%") + "\\foobar2000\\user-addons\\wsh-spinning-disc-image";


you should use fb.ProfilePath as that caters for both scenarios. it points to %appdata%\foobar2000 when running a standard foobar install. if running a portable install, it points directly at the foobar2000 program folder.
Go to the top of the page
+Quote Post
ExtremeHunter
post Sep 12 2013, 13:17
Post #2545





Group: Members
Posts: 133
Joined: 5-October 08
From: Estonia
Member No.: 59398



I know fb.ProfilePath .

I misunderstood "<fb2k_dir>\user-addons\wsh-spinning-disc-image\"

I tried to access default installation %appdata% <fb2k_user_profile_dir> from portable version tongue.gif


This post has been edited by ExtremeHunter: Sep 12 2013, 13:23
Go to the top of the page
+Quote Post
marc2003
post Sep 12 2013, 13:23
Post #2546





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



QUOTE
<fb2k_dir>


i'd assume that to mean the program folder, not %appdata%\foobar2000.

your code would only work if his portable install was inside his %appdata% folder. why hardcode something when you have the flexibility to let people use whatever mode they like and if using portable mode, they can put their foobar folder anywhere and it will just work.

edit: i see you've edited your post. hopefully it's cleared up now. smile.gif

This post has been edited by marc2003: Sep 12 2013, 13:27
Go to the top of the page
+Quote Post
mire777
post Sep 12 2013, 13:30
Post #2547





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



Sorry for the stupid questions, but i need help.
Which function to call to cycle image. I want to cycle the front, back and icon image, and set time delay for that.
Here is script: http://pastebin.com/jvQ9z6Jc
Go to the top of the page
+Quote Post
marc2003
post Sep 12 2013, 13:41
Post #2548





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



this might work (untested)

CODE
window.SetInterval(function() {
    a.id++;
    if (a.id > 4) a.id = 0;
    a.metadb_changed();
}, 5000);


the 5000 is milliseconds. you can edit that bit.
Go to the top of the page
+Quote Post
mire777
post Sep 12 2013, 13:47
Post #2549





Group: Members
Posts: 387
Joined: 9-June 12
Member No.: 100550



QUOTE (marc2003 @ Sep 12 2013, 14:41) *
this might work (untested)

CODE
window.SetInterval(function() {
    a.id++;
    if (a.id > 4) a.id = 0;
    a.metadb_changed();
}, 5000);


the 5000 is milliseconds. you can edit that bit.


I got error: object doesn't suport that property or metod. i guess that is because i use wsh 1.4.2.
Go to the top of the page
+Quote Post
marc2003
post Sep 12 2013, 14:02
Post #2550





Group: Members
Posts: 4594
Joined: 27-January 05
From: England
Member No.: 19379



CODE
var timer = window.CreateTimerInterval(5000);

function on_timer() {
    a.id++;
    if (a.id > 4) a.id = 0;
    a.metadb_changed();
}
Go to the top of the page
+Quote Post

130 Pages V  « < 100 101 102 103 104 > » 
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 25th October 2014 - 16:23