Old 29th June 2006, 18:02   #1
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Minibrowser API Support for Winamp 5.22+

Since winamp 5.22, the minibrowser API is "gone for good"..

I don't like this, so I made a plugin for minibrowser API support!

With this plugin, your plugin with minibrowser should work fine.

Source code included.

If you have any comment, please reply this thread.. though
I don't ensure I will answer..
Attached Files
File Type: rar gen_mbapi.rar (43.2 KB, 792 views)
whoami is offline   Reply With Quote
Old 29th June 2006, 18:24   #2
DrO
 
Join Date: Sep 2003
Posts: 27,873
the plugin needs to be multi-user compatible (have a look below some example code) otherwise i've not had a chance to give it a look over since i see you've also submitted it to the winamp.com site. btw the future of the minibrowser apis is still somewhat unclear (the reason it doesn't working in 5.22+ is because it was all stripped out when things were split up in gen_ml for the 5.22 release) but may/may not be re-implemented natively (though if this works well then it could save the devs time having to reimplement and just let other authors rebundle this with their plugins as needed could be an option).

anyway example code for getting winamp.ini correctly for all winamp versions is...
code:
** void GetIniFilePath(HWND hwnd){
** if(SendMessage(hwnd_winamp,WM_WA_IPC,0,IPC_GETVERSION) >= 0x2900){
** // this gets the string of the full ini file path
** lstrcpyn(ini_path,(char*)SendMessage(hwnd_winamp,WM_WA_IPC,0,IPC_GETINIFILE),sizeof(ini_path));
** }
** else{
** char* p = ini_path;
** p += GetModuleFileName(0,ini_path,sizeof(ini_path)) - 1;
** while(p && *p != '.'){p--;}
** lstrcpyn(p+1,"ini",sizeof(ini_path));
** }
** }

-daz
DrO is offline   Reply With Quote
Old 30th June 2006, 03:01   #3
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Minibrowser API Support 0.2 for Winamp 5.22+

Thanks for DrO, I added multi-user support to the plugin.

Also, there is a problem on 0.1 that winamp does not quit successfully.. Sorry about this.

It is fixed (kinda) with 0.2 with ExitProcess().. but if anybody knows a better solution, please let me know.


(ps)
But.. yeah, this plugin is for winamp 5.22+... it is not necessory (or, 99.9% happens side-effect, I think) under 5.21.. Should I care for winamp 5.21 (and less) users?
Attached Files
File Type: rar gen_mbapi_0.2.rar (43.0 KB, 440 views)

Last edited by whoami; 30th June 2006 at 03:28.
whoami is offline   Reply With Quote
Old 30th June 2006, 08:28   #4
DrO
 
Join Date: Sep 2003
Posts: 27,873
using ExitProcess(..) is really not a good idea to be doing since you're blasting the winamp process space out of memory so something has got to be messed up if it's not closing correctly for you. i'll try to have a look at this later today (unless i'm beaten to it) to see if i can help out. also with regards to handling for 5.21 and below, a version check on startup for 0x5021 and below to then return the opposite of the normal return code so Winamp then won't load it. you could add in a messagebox or something to indicate that this was the case.

-daz
DrO is offline   Reply With Quote
Old 30th June 2006, 22:02   #5
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Looks like whoami is doing great work here!

One thing missing is a way for other plugins to find
out if gen_mbapi is alreay loaded.

Or can this already be done with that
"extern winampGeneralPurposePlugin *gen_plugins[256];"
thing in gen.h? I never understood this or how to use it.
Can anybody explain to me?

Otherwise maybe an extra message for mbapi-are-you-there
would a good idea.

Any news on that ExitProcess() trouble?
 
dllmain is offline   Reply With Quote
Old 30th June 2006, 22:31   #6
DrO
 
Join Date: Sep 2003
Posts: 27,873
need to replace
code:
if (mbapi.lpWinampProc)
SetWindowLong(plugin.hwndParent,GWL_WNDPROC,(LONG)mbapi.lpWinampProc);

with
code:
if(GetWindowLong(plugin.hwndParent,GWL_WNDPROC) == (LONG)WinampSubclassProc){
SetWindowLong(plugin.hwndParent,GWL_WNDPROC,(LONG)mbapi.lpWinampProc);
mbapi.lpWinampProc = NULL;
}

that fixes issues with the unsubclassing of the subclass chain. as for the bit about identifying itself, i guess you could either use an api registration message like with how the gen_hotkeys does or just check for the message return values or something (i've not had a chance to check things over fully still so i'm not sure on the best way to advise things)

-daz
DrO is offline   Reply With Quote
Old 30th June 2006, 23:35   #7
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
No. not this way...

Quote:
Originally posted by DrO
need to replace
code:
if (mbapi.lpWinampProc)
SetWindowLong(plugin.hwndParent,GWL_WNDPROC,(LONG)mbapi.lpWinampProc);

with
code:
if(GetWindowLong(plugin.hwndParent,GWL_WNDPROC) == (LONG)WinampSubclassProc){
SetWindowLong(plugin.hwndParent,GWL_WNDPROC,(LONG)mbapi.lpWinampProc);
mbapi.lpWinampProc = NULL;
}

that fixes issues with the unsubclassing of the subclass chain. as for the bit about identifying itself, i guess you could either use an api registration message like with how the gen_hotkeys does or just check for the message return values or something (i've not had a chance to check things over fully still so i'm not sure on the best way to advise things)

-daz
I tried this, but the code does not work at all.

The problem is, at quit(), the hwndParent (Winamp windows handle) is already invalid.. therefore SetWindowLong() always fails, giving always NULL. I think I should restore lpWinampProc earlier than that, which means gen_tray source of wa_sdk is buggy..

Does anybody have any better idea? Come to think of it, I guess ExitProcess() doesn't do much harm to Winamp because it is already in the middle of closing when quit()... but of course, doing job with assuming could be critical.

For identifying gen_mbapi, returning some id code (lets say, 1) on an ipc call (lets say, IPC_MBBLOCK) with an invalid value (maybe -1 or something) may be okay.. how's this idea?

(ps) - oh what ps lover I am!..
I will (not now) try hooking instead of subclassing, if that subclassing is the cause..
whoami is offline   Reply With Quote
Old 30th June 2006, 23:58   #8
DrO
 
Join Date: Sep 2003
Posts: 27,873
well that code is the same as i use in all of my plugins, in the updated gen_tray 2.0 source code and i think the devs use it as well (i know benski thought it good ages ago) and using it i didn't have any crash issue on exit whereas with what's in your 0.2 code i could get a crash on close if the ExitProcess(..) wasn't there.

hmm, just tried and the window handle is invalid at that stage and i don't think that should be the case. all i know is that the devs are happy with the code i pasted otherwise they'd have pulled it out of the gen_tray 2.0 source after it had been vetted.

ExitProcess(..) is not a solution and it shouldn't be used since you have no idea where in the subclass/plugin load order that you are and if you call that function you're blowing Winamp out of the system memory so anyother plugins and winamp itself can't save any other settings.

with the settings thing why not leave the apis alone so that they mirror the original code (as would be expected) and do something like
code:
gen_mbapi_ipc=SendMessage(plugin.hwndParent,WM_WA_IPC,(WPARAM)&"GenMBAPIExists",IPC_REGISTER_WINAMP_IPCMESSAGE);
if(!SendMessage(winampWindow,WM_WA_IPC,0,gen_mbapi_ipc)){
// gen_mbapi.dll seems to be installed
// note: may need to delay the check of this such as a PostMessage
// into the calling plugin's WinampProceedure so that gen_mbapi.dll can be loaded so it can respond
}

// in your WinampSubclassProc you'd need to do something like this..

if(message == WM_WA_IPC && lParam == gen_mbapi_ipc){
// return 0 since Winamp returns 1 for unhandled messages as would be the case if this wasn't present
return 0;
}

did you get the installer version of the sdk since that should have the fixed gen_tray source code in it

-daz
DrO is offline   Reply With Quote
Old 1st July 2006, 00:32   #9
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Quote:
did you get the installer version of the sdk since that should have the fixed gen_tray source code in it
Well, I am using "winamp 5.04 sdk" which is sticky on this board... http://forums.winamp.com/showthread....hreadid=188069

Anyway, in my system (win xp sp2 Korean version) winamp stops silently with its process still live in the memory... not crashing. That's why I did not notice the flaw on 0.1.

I have to go out shortly, so I cannot test any code.. I will try anything when I have time to do so.

Oh, Thanks for your help always.
whoami is offline   Reply With Quote
Old 1st July 2006, 01:10   #10
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
I am sure the subclassing alone cannot be the problem.
Btw ExitProcess() does harm here - some plugins do not
save their config anymore.
dllmain is offline   Reply With Quote
Old 1st July 2006, 05:40   #11
Benski
Ben Allison
Former Winamp Developer
 
Benski's Avatar
 
Join Date: Jan 2005
Location: Brooklyn, NY
Posts: 1,057
@dllmain:
in_wm crashes on close in 5.23/5.24. Might be worth disabling it while you're debugging.

One easy way to identify your presence is to use IPC_REGISTER_WINAMP_IPCMESSAGE, and handle the corresponding WM_WA_IPC in your window procedure. Winamp returns 1 from WM_WA_IPC if it doesn't understand the LPARAM. If you return 0, then other plugins can call IPC_REGISTER_WINAMP_IPCMESSAGE and then call that IPC and see if it returns 0.

e.g.

code:

bool MinibrowserPluginPresent()
{
LPARAM mbPresenceCheck = (LPARAM)SendMessage(plugin.hwndParent, WM_WA_IPC, (WPARAM)"MinibrowserAPI", IPC_REGISTER_WINAMP_IPCMESSAGE);
if (SendMessage(plugin.hwndParent, WM_WA_IPC, 0, mbPresenceCheck) == 0)
return true;
else
return false;
}



extern winampGeneralPurposePlugin *gen_plugins[256];
is used inside of Winamp. It doesn't really belong there (and the next SDK release won't have it)
Benski is offline   Reply With Quote
Old 1st July 2006, 09:07   #12
DrO
 
Join Date: Sep 2003
Posts: 27,873
dunno why i posted what i did with benski repeating what i'd said, heh

-daz
DrO is offline   Reply With Quote
Old 1st July 2006, 14:01   #13
Benski
Ben Allison
Former Winamp Developer
 
Benski's Avatar
 
Join Date: Jan 2005
Location: Brooklyn, NY
Posts: 1,057
Quote:
Originally posted by DrO
dunno why i posted what i did with benski repeating what i'd said, heh

-daz
Note to self: don't reply to forum posts at 2AM (or at least be awake enough to read the other posts first)
Benski is offline   Reply With Quote
Old 1st July 2006, 14:13   #14
DrO
 
Join Date: Sep 2003
Posts: 27,873
i've been trying to tell myself that for years

-daz
DrO is offline   Reply With Quote
Old 1st July 2006, 14:19   #15
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Minibrowser API Support 0.3 for Winamp 5.22+

Finally fixed "winamp does not quit correctly" problem!

Well, actually it was my bad. on the article I referred already contained the fix.

code:

// This function is from MS article 249232, "How To Get IHTMLDocument2 from a HWND"
CComPtr<IHTMLDocument2> GetIHTMLDocument2(HWND hwndIES)
{
....
if (SUCCEEDED(hr))
{
CComPtr<IDispatch> spDisp;
CComQIPtr<IHTMLWindow2> spWin;
spDoc->get_Script( &spDisp );
spWin = spDisp;
spWin->get_document( &spDoc.p );
}
....
}


This code is NEEDED to get IHTMLDocument2 safely, but I ignored it because I already had IHTMLDocument2 on ObjectFromLresult was called. I thought this code is just a part of example code.

And, well. I added ipc message for "Hey, gen_mbapi, are you there?" . I chose "gen_mbapi" for check string, for it is that simple string.. see readme.txt for details.

For un-subclassing issue.. I followed DrO's solution, but I still get IsWindow(plugin.hwndParent) == FALSE. The plugin is working fine, though.

If we (you all and I) cannot find any other issue, I will re-submit this plugin to winamp plug-in section. Would you mind looking for issue(s) for me?
Attached Files
File Type: rar gen_mbapi_0.3.rar (45.0 KB, 461 views)
whoami is offline   Reply With Quote
Old 1st July 2006, 14:22   #16
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Quote:
Originally posted by Benski
Note to self: don't reply to forum posts at 2AM (or at least be awake enough to read the other posts first)
I totally agree with you! and additionally, don't make any code if one is not awaken completely..
whoami is offline   Reply With Quote
Old 5th July 2006, 18:45   #17
JW
Senior Member
 
Join Date: Nov 2004
Location: Valencia, CA
Posts: 304
I just upgraded to 5.24, and the HTML Viewer plugin stopped working. I used this to get it back. Nice work!
JW is offline   Reply With Quote
Old 6th July 2006, 00:48   #18
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
JW:
Why, thanks for using this plugin!

And.. about your private message.. I think the message is not so "private".. and I usually do not check private messages. To not forget your request, I just post it here:

Quote:
One thing that would make this really slick, and that the MB should have done in the first place - could it be programmed to remember the last URL opened, and reopen it when Winamp is restarted?

"JW"
In the short answer, yes, it is possible.
Long answer (well, I could not resist to say this! ), it is possible but I can't remember minibrowser did that under winamp 5.21-...

In any case, I will review my plugin and try to add the feature.. as soon as I have time to do so.
whoami is offline   Reply With Quote
Old 6th July 2006, 09:01   #19
Maxim
Senior Member
 
Join Date: Mar 2001
Location: smspower.org
Posts: 107
Hmm, I seem to have a problem. It is installed and the config works, but nothing ever happens as expected - Now Playing works the same as before.
Maxim is offline   Reply With Quote
Old 6th July 2006, 15:06   #20
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Quote:
Originally posted by Maxim
Hmm, I seem to have a problem. It is installed and the config works, but nothing ever happens as expected - Now Playing works the same as before.
Hmm. First of all, go to config menu and open config dialog of Minibrowser API Support (of course, the Media Library should be opened and show "Now Plugin"). And then, try writing any URL (e.g. http://www.yahoo.com no advertising, though; ) and click "Navigate" button.

Does it work? If yes, that means my plugin has control over the minibrowser. There might be some problem on my plugin, such as fail of subclassing, but in that case, you should receive some warnings..

Try above test and if it works, please notify me your plugin - which is using minibrowser API - name, Winamp version, and your OS. There might be some bugs in my plugin (I always cannot guarantee my program is bug-free), and I will try to fix them IF I can reproduce the symptom.
whoami is offline   Reply With Quote
Old 7th July 2006, 08:21   #21
Maxim
Senior Member
 
Join Date: Mar 2001
Location: smspower.org
Posts: 107
Sometimes I get:
Quote:
---------------------------
Minibrowser API Support 0.3 for Winamp 5.22+
---------------------------
Minibrowser has not been initialized yet.
Please wait a minute and try again.
---------------------------
OK
---------------------------
If I manually switch to Now Playing, the control is instantiated and the plugin config shows. I can then navigate to URLs as you described.

The plugin I am using is one I wrote myself. The code for opening the Minibrowser/Now Playing is:

code:
url = malloc( strlen( TempHTMLFile ) + 9 );
sprintf( url, "file:///%s", TempHTMLFile );
if ( ForceOpen ) SendMessage(mod.hMainWindow,WM_USER,(WPARAM)NULL,IPC_MBOPEN); // open minibrowser
SendMessage(mod.hMainWindow,WM_USER,(WPARAM)url,IPC_MBOPEN); // display file
free(url);


This is exactly the code that worked fine with old versions of Winamp. TempHTMLFilename is a fully qualified file path, eg. "c:\temp\file.htm".

Debugging through your code, it seems you're not handling the case where szUrl==NULL, which is supposed to activate the Now playing window. Filtering out the NULL doesn't help; manually entering any file:/// address in the config window also seems not to work, so maybe you can debug it that way.

I also noticed you aren't implementing some of the internal callback stuff defined in wa_ipc.h, eg. IPC_MBURL. I don't know if any of it is used, or even if you should be catching those callback messages instead of the higher-level ones, or sending them yourself. Some, like IPC_MBGETDESC, aren't used any more anyway.
Maxim is offline   Reply With Quote
Old 7th July 2006, 09:53   #22
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Oh, that.

First of all, my plugin does not work WITH "Now Playing". Actually, there is no information to cooperate with "Now Playing", and I wonder if the author of the plugin adds such a feature. The way my plugin works is, finding ALREADY OPENED "Now Playing"'s browser and control remotely without the help of the plugin.

Therefore, my plugin is designed not to work if it cannot find "Now Playing"'s browser, so it is normal (for now, at least) that SendMessage(..., NULL, IPC_MBOPEN) does not work.

My plugin does not filter any http: or file:. It just send an URL (even it is not a valid one) to the browser via put_url method of IHTMLDocument2. If file: protocol does not work, it is because M$ made it not to work.

Not supporting IPC_MBURL is my bad, because I did not know there were such IPC calls .. I just searched for "minibrowser" and found IPC_MBOPEN(REAL), IPC_MBBLOCK, and IPC_GETMBURL only. You could call me an lazy plugin developer . Thank you for this info.

Okay, Minibrowser API support plugin is actually NOT supporting all of APIs well. I admit it, so what? it is not even version 1.0 , and it is not because there is no support for .lks file and an URL button..


One good news is, I will review this plugin this weekend, and try to add such features.. but I can not ensure. Stay tuned (hey, since when it becomes a radio station?) and wait for some news. If you cannot wait, do it yourself and let us know. This plugin is in public domain, you see.
whoami is offline   Reply With Quote
Old 7th July 2006, 12:26   #23
Maxim
Senior Member
 
Join Date: Mar 2001
Location: smspower.org
Posts: 107
I thought there was an easy way to open the Media Library to a particular view, to allow NULL handling to work, but I can't find it right now.

I can see you're just passing the URL to the HTML control, I just thought maybe you'd say "Ah, file:/// URLs require the MSHTML_ALLOW_FILE_URL flag to be set" or something like that (unfortunately, that flag does not exist), and gave you an easy way to test it.
Maxim is offline   Reply With Quote
Old 8th July 2006, 11:58   #24
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Minibrowser API Support 0.4 for Winamp 5.22+

I feel when I use the program, and Spy++ rocks!
Since the SDK is for 5.04, and many things changed/undocumented on 5.22+.. so I have to spy all things from Winamp program itself.. Woe is me.

Here we go, a new version.

a lot has been added.. thanks to Maxim I learned that there were LOTS of minibrowser features I hadn't noticed, and tried to put them into this version...

So, here is the changelog:
Fixed : This plugin is now add "http://" to URL if no protocol is specified.
Fixed : SendMessage(..., NULL, IPC_MBURL) IPC call now opens "Now Playing" window.
Added : "Visit last URL when Winamp starts" feature
Added : This plugin proceeds following IPC calls :
IPC_MBURL (works the same as IPC_MBOPEN)
IPC_MBGETCURURL (works the same as IPC_GETMBURL)
IPC_MBCMD (without MBCMD_MISC)
IPC_MBREFRESH
IPC_GETWND (with IPC_GETWND_MB, returns the hwnd of Internet Explorer_Server)
IPC_ISWNDVISIBLE (with IPC_GETWND_MB)

and, todos (will it ever do?) are:
- No .lks support
- No URL button on the minibrowser
- Supporting protocols other than "http:"
- Following IPC calls are not proceeded :
IPC_MBGETDESC (no .lks support)
IPC_MBCHECKLOCFILE (no idea what this does)
IPC_MBGETDEFURL (no .lks support)
IPC_MBCMD with MBCMD_MISC (no idea what this does)

I think JW's suggestion and Maxim's complaints are solved mostly, so try this new version and inform me if anything needs to be improved.
Attached Files
File Type: rar gen_mbapi_0.4.rar (43.8 KB, 322 views)
whoami is offline   Reply With Quote
Old 8th July 2006, 20:18   #25
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Version 0.4 behaved a little strange here:

(1) I press "Configure selected plugin" in Winamp's preferences
(2) Plugin asks "The minibrowser has not been opened yet. Do you want to open?"
(3) I choose "Yes"
(4) MiniBrowser opens
(5) Plugin says "Please wait until the minibrowser opens and try opening this config window again."

I could fix this problem for me by modifing window chain find data.
I looked at my local window chain using Winspector and here the
"Winamp Library" does not have the first two parents that
were searched for in 0.4. Does this have to do with modern
skins? I have a classic one here...

Quote:
const FINDWINDOWCHAINSTRUCT aFindWindowChain[] = {
/* TESTFIX
{ NULL, "Media Library" },
{ "BaseWindow_RootWnd", "Winamp Library" },
*/
{ "Winamp Gen", "Winamp Library" },
{ (LPCTSTR)32770, NULL },
{ (LPCTSTR)32770, NULL },
{ "HTMLControl", "HTMLControl" },
{ "Shell Embedding", NULL },
{ "Shell DocObject View", NULL },
{ "Internet Explorer_Server", NULL },
{ NULL, NULL}
};
// TESTFIX #define MBDIALOGCHAIN 4 // the second #32770
#define MBDIALOGCHAIN 2 // the second #32770
Other small modifications I made:
  • Added simple NSIS Installer script
  • Fixed font trouble in config dialog by turning on "Use System font"
  • Converted two sequential ifs to a switch/case (which should be faster, especially in a window procedure)
  • Added Visual Studio 2003 project files (the VC6 files are still there)

Here is the download of my 0.4.1 code.
Base 0.5 on my changes if you like.

>> gen_mbapi_041.zip
&#160;
dllmain is offline   Reply With Quote
Old 9th July 2006, 02:32   #26
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
I just ran the source code analyser AntiC over gen_mbapi.cpp
which revealed a potential operator precedence problem.
It can be fixed easily:

Quote:
gen_mbapi.cpp, line 137
--- (IPC_MBURL <= lParam) && (lParam <= IPC_MBGETDEFURL)
+++ ((IPC_MBURL <= lParam) && (lParam <= IPC_MBGETDEFURL))
dllmain is offline   Reply With Quote
Old 9th July 2006, 08:53   #27
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Ah, yes, yes. As dllmain said, there IS a difference between a classic and a modern skin.. and when mbapi comes to 0.4, I put a little "optimization" code on FindWindowChain() and it just backfired.

code:

if (!hwndChild) // There is no chain. Cancel finding.
return NULL;



Without this code, it just follows the chain regardless FindWindow(Ex) returns NULL or not. Now it stops if it cannot find a chain. However, on a classic skin, a chain starts from "Winamp Gen"-"Winamp Library", not "Media Library". On the code of 0.3, it continues to find the chain so it can find "Winamp Library" eventually, but 0.4, it can not.

About the line 137 of gen_mbapi.cpp, I say "Oops."
Hey, I am just a normal human and I can do such a mistake, don't I? .. Well, sometimes that kind of mistake makes a satellite to fall down anyway.

I will review dllmain's 0.4.1 code and try to fix these issues today night.. I tend to use "if" rather than "switch-case" when the cases are not much (under 3-4), because "switch-case" has more overhead than "if". Of course if the cases increase, the code should be done refactoring. Thanks for your help, dllmain.

Last edited by whoami; 9th July 2006 at 09:08.
whoami is offline   Reply With Quote
Old 9th July 2006, 13:20   #28
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Thanks to dllmain, here goes another new version;
(It is a fast version-ups, don't you think? )

On 0.5 (based on 0.4.1), we got:
- A dumb missing () mistake fixed. (okay, call me a lazy AND careless developer.. )
- Modern skin - Classic skin compatibility issue fixed.
- Did some refactoring..

I have virtually no experience on NSIS script, but I need some option if one want to install the source code.. If anyone knows how to do this, please let me know (best if one fixes .nsi file within this rar-compressed file )

Check this version and inform me if any issue(s) found.
Attached Files
File Type: rar gen_mbapi_0.5.rar (50.7 KB, 295 views)
whoami is offline   Reply With Quote
Old 9th July 2006, 14:19   #29
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
For some reason I still get "The minibrowser has not been opened yet"
the frist time right after the plugin opened the browser itself.

Btw the few "defects" I found do not change the fact that you
are doing a great job here!

[EDIT] (I just re-read the previous post...)

Last edited by dllmain; 9th July 2006 at 14:42.
dllmain is offline   Reply With Quote
Old 9th July 2006, 14:38   #30
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Quote:
For some reason I still get "The minibrowser has not been opened yet"
the frist time right after the plugin opened the browser itself.
I just found out that this trouble was caused by my firewall.
The HTMLControl did not create their children which is why
the plugin could not find them.
dllmain is offline   Reply With Quote
Old 9th July 2006, 15:22   #31
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Quote:
Originally posted by whoami
I have virtually no experience on NSIS script, but I need some option if one want to install the source code.. If anyone knows how to do this, please let me know (best if one fixes .nsi file within this rar-compressed file )
I adopted the script from NxS BigClock so the installer
now can optionally install the source files. I renamed
the readme to gen_mbapi_readme.txt but all other
files should be the very same as before:

>> gen_mbapi_051_pre.zip
&#160;
dllmain is offline   Reply With Quote
Old 10th July 2006, 00:57   #32
JW
Senior Member
 
Join Date: Nov 2004
Location: Valencia, CA
Posts: 304
Perfect! Thanks!!
JW is offline   Reply With Quote
Old 10th July 2006, 11:15   #33
Red Mullet
Banned
 
Red Mullet's Avatar
 
Join Date: Jun 2006
Location: 439 East District, Mount Paozu
Posts: 57
I have winamp 5.22 Lite & I downloaded this plugin in this name (gen mbapi 0 3) in most recent plugin by whoami whoami & Published: Jul. 9, 2006

When I want to configure this plugin in general purpose list category I recieve this message: Minibrowser has not been initialized yet. Please wait a minute and try again.

Should I have full or bundle winamp for seeing this plugin?

I mean just winamp full or bundle have minibrowser? or this message has another reason or meaning?
Red Mullet is offline   Reply With Quote
Old 10th July 2006, 11:20   #34
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
I have no idea but why don't you try again with
a more recent version like gen_mbapi_0.5.rar?
dllmain is offline   Reply With Quote
Old 10th July 2006, 11:31   #35
DrO
 
Join Date: Sep 2003
Posts: 27,873
i thought the media library was required for this to work and the lite version definitely doesn't have that so you're going to need to re-install with a fuller install.

-daz
DrO is offline   Reply With Quote
Old 10th July 2006, 11:58   #36
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
New version, installer with source code included.
Minor improvements mainly.

>> gen_mbapi_052_pre_setup.exe
&#160;
dllmain is offline   Reply With Quote
Old 10th July 2006, 13:50   #37
Red Mullet
Banned
 
Red Mullet's Avatar
 
Join Date: Jun 2006
Location: 439 East District, Mount Paozu
Posts: 57
I test gen_mbapi_0.5.rar but I have same problem & I get this message: The minibrowser has not been opened yet.
Do you want to open? I click yes then I receive this message: Please wait until the minibrowser opens & try opening this config window again. I click ok button but does not happened any thing. Remember I have winamp 5.22 Lite

Is it nessasary to have winamp full or bundle?
I mean winamp Lite has minibrowser or not? or just winamp full or bundle have minibrowser?

I don't know minibrowser what's meaning?
Red Mullet is offline   Reply With Quote
Old 10th July 2006, 14:10   #38
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Quote:
Originally posted by Red Mullet
Is it nessasary to have winamp full or bundle?
I mean winamp Lite has minibrowser or not? or just winamp full or bundle have minibrowser?
No, Winamp Lite is not enough. The minibrowser is part
of a plugin called "Nullsoft Winamp Library" (gen_ml.dll).
If you have that file/plugin from an old installation you
have a minibrowser - if not you need a full install.

Quote:
I test gen_mbapi_0.5.rar but I have same problem & I get this message: The minibrowser has not been opened yet.
Do you want to open? I click yes then I receive this message: Please wait until the minibrowser opens & try opening this config window again. I click ok button but does not happened any thing. Remember I have winamp 5.22 Lite
That's right - clicking okay doesn't do anything further.
But if you have the library installed clicking "configure
selected plugin" one more time will show the config dialog.

Quote:
I don't know minibrowser what's meaning?
Imagine the minibrowser as an instance of the Microsoft
Internet Explorer embedded into the library plugin window.
It can be found under "now playing".

Sorry, if I explained something you already knew.
Just thought a few words more would be the better choice.
dllmain is offline   Reply With Quote
Old 10th July 2006, 14:38   #39
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Minibrowser API Support 0.5.3 for Winamp 5.22+ AND some modification guideline

Yet another version. Sorry about this.

You may call me a LAZY and CARELESS and DUMB developer.. (Gee, I am losing my appetite.. )

I forgot to remove some test code from OnIpcMbCmd().
This version, those code are removed.

I did not do NSIS for this rar-file because the Winamp forum forbids a file over 102400 bytes, and .exe extension. I will update published plugin with NSIS-based .exe file anyway.

And, I think this is the time to announce some modification guideline. Whoa, no, I am not changing its license, public domain.

First of all, please do not set version like 053, because the version can be over 0.10 something and then the version number will be confusing. I suggest we should use 0_5_3 instead.

Then, if you do some modifications, PLEASE REPORT THEM ON CHANGELOG.TXT! With this little rule, it will be easier for peer developers to review your modification.

Lastly, let's settle the source code directory to be "gen_mbapi_source". It seems ridiculous one has series of 'historical' mbapi source directories. I changed the .nsi already to install the source files into "gen_mbapi_source".

Okay? If you have any comment for guideline above, please let me know.

@dllmain:
One thing about the NSIS script: does it need an uninstaller? There is already an uninstall button on Winamp, and one can delete the source code manually if he/she can understand the source code.
Attached Files
File Type: rar gen_mbapi_0_5_3.rar (70.2 KB, 364 views)
whoami is offline   Reply With Quote
Old 10th July 2006, 14:45   #40
whoami
Junior Member
 
Join Date: Jun 2006
Location: Planet Earth, the Solar system.
Posts: 31
Quote:
Originally posted by Red Mullet
I have winamp 5.22 Lite & I downloaded this plugin in this name (gen mbapi 0 3) in most recent plugin by whoami whoami & Published: Jul. 9, 2006

When I want to configure this plugin in general purpose list category I recieve this message: Minibrowser has not been initialized yet. Please wait a minute and try again.

Should I have full or bundle winamp for seeing this plugin?

I mean just winamp full or bundle have minibrowser? or this message has another reason or meaning?
Oh, doesn't the lite version come with the media library? I didn't know it.. Should we put some code to prevent the lite version from running this plugin? (or, notice the user to install a full version?)

(ps) hey,another ps! I love it!
The published gen_mbapi 0.3 is now unavailable because of updating to 0.5.3. To finish updating, the Winamp staffs' review is needed and 0.5.3 is waiting for the review.

Well, I hope (hope?) the version stays until gen_mbapi republished.. but it is one of skyrocketing-version-up plugins.. oh dear.

Last edited by whoami; 10th July 2006 at 15:51.
whoami is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > Winamp Development

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump