Well, when segosa created this thread he pointed to it on IRC, I was also on IRC atm and I tried some stuff with a sniffer. And indeed some strange things happened or rather: didn't happen at all.
eg:
When you double click on a contact in the contact list, there is always, and I mean always some stuff send. You know, protocol and such...
But when you double click on a floating contact this only happens for the first time! After you closed the convo again and double click again on that particular floating contact, nothing seems to be send. I also had the perception (but this is only a rough perception, I didn't looked into detail or counted or whatever) that when stuff is send by double clicking on a floating contact, it is far less stuff than when you double click on a contact list contact... It is as if the chat window and even connection never closed (although it was).
I had a guess that when you double click on the contact list contact, MSN Messenger itself does more than simply opening the chat window. It first initiates a connection and all, only then opens the window, so to speak. And then the code of the window kicks in.
When you open a conversation programmatically (aka floating contacts), msn messenger doesn't do the stuff it would do otherwise. Only the code from when the chat window is actually openend is executed.
But this guess is far from solid though, it also doesn't explain why there is nothing send after you double click on the floating contact again (after closing the convo window); which does happen when you double click on a contact list contact....
So...
quote:
Originally posted by Stigmata
he must do it the same way
im pretty sure he would use the instantmessage function in the messenger api
what other way is there?
My guess is that there is more code behind opening a chat window than only this instantmessage function. Code which is only executed by MSN Messenger itself when you double click on the contactlist. And thus not only the code from the instantmessage function (aka opening chat window module) which you otherwise execute _only_ when doing it programmatically.
Thus:
double click contact list:
-
some code
- this instantmessage function
- create and open the window
- some code
a programmatically call to:
- this instantmessage function
- create and open the window
- some code
Blah... all this is for the protocol junkies anyways
But I too am very curious about this after trying this out...