Author Topic: open message window, when contact goes on-line  (Read 4888 times)

0 Members and 1 Guest are viewing this topic.

Offline popej

  • Newbie
  • *
  • Posts: 6
  • Country: pl
    • GMapTool
open message window, when contact goes on-line
« on: 21 03 2015, 15:48:33 »
Hi,

I'm new to Miranda. I'm moving form pidgin. I have successfully configured most features but there is one problem, that I can't solve. I would like Miranda to open message window automatically, when my contact goes on-line. Is there any option or plugin to get this behavior?
--
popej
 

Offline AnrDaemon

Re: open message window, when contact goes on-line
« Reply #1 on: 23 03 2015, 03:05:38 »
And if your contact get a trippy connection and goes "online" every few minutes… how quick you will get annoyed by a message window popping up and interfering with your work?
 

Offline Robyer

Re: open message window, when contact goes on-line
« Reply #2 on: 23 03 2015, 07:24:33 »
Maybe you can set it with ActMan plugin.
I was developing mainly Facebook, Omegle, Steam, Dummy and MobileState plugins. Now I'm retired. Goodbye, everyone. ~ You can still find me on Facebook.
 

Offline popej

  • Newbie
  • *
  • Posts: 6
  • Country: pl
    • GMapTool
Re: open message window, when contact goes on-line
« Reply #3 on: 23 03 2015, 11:13:38 »
Thanks for advices.

I have locked at ActMan but I haven't found anything related to message window or contact status change. Any suggestions how to configure ActMan plugin?
--
popej
 

Offline Robyer

Re: open message window, when contact goes on-line
« Reply #4 on: 24 03 2015, 09:52:32 »
I'm not using ActMan and I'm not sure if he is capable of this, but from logic of your problem you need to do this:

1) You need to hook event which is value change in Database. Key name is "Status" and it's in <proto> branch of contact settings.
2) Then check if that value is of status you want to see (offlien - 40071, online - 40072, away - 40073, ...)
3) Then start action - open message window
I was developing mainly Facebook, Omegle, Steam, Dummy and MobileState plugins. Now I'm retired. Goodbye, everyone. ~ You can still find me on Facebook.
 

Offline popej

  • Newbie
  • *
  • Posts: 6
  • Country: pl
    • GMapTool
Re: open message window, when contact goes on-line
« Reply #5 on: 24 03 2015, 11:41:48 »
I can see only limited set of hooks:
Actions/Changed - probably internal hooks of ActMan
CList/DobuleClicked
CList/PreBuildContactMenu
DB/Contact/Added
DB/Contact/Deleted

There is nothing like "Database" or "Status". Looks like a dead end for me.

This is what I'm using:
Miranda NG Version: 0.95.3 build #11706 x64 Build time: 1 Jan 2015 14:27:34
Actman.dll v.0.3.0.1 [1 Jan 2015 15:28:02] - Action manager
--
popej
 

Offline Awkward

  • Developer
  • *****
  • Posts: 23
  • Jabber: Jabber ID
Re: open message window, when contact goes on-line
« Reply #6 on: 24 03 2015, 12:20:43 »
popej, if you see limited amount of hooks in list, it not mean what you can't add there yourself, just need to check miranda API headers for what you need. events in list are just some examples in service.ini file in plugins folder.
 

Offline popej

  • Newbie
  • *
  • Posts: 6
  • Country: pl
    • GMapTool
Re: open message window, when contact goes on-line
« Reply #7 on: 24 03 2015, 17:02:11 »
Thanks Awkward, I will investigate further. I haven't noticed, that I can insert other values at this field.
--
popej
 

Offline popej

  • Newbie
  • *
  • Posts: 6
  • Country: pl
    • GMapTool
Re: open message window, when contact goes on-line
« Reply #8 on: 25 03 2015, 16:00:39 »
I have tried to configure ActMan.
First I have added a service to services.ini, which opens message window:
Code: [Select]
[Service:CList/ContactDoubleClicked]
alias=MS_CLIST_CONTACTDOUBLECLICKED
wparam=hContact
lparam=0
return=int 0, if successful
descr=Double clicking a contact

Then I have defined following hook:
Code: [Select]
[Event:Miranda/StatusChange/ContactStatusChanged]
alias=ME_STATUSCHANGE_CONTACTSTATUSCHANGED
plugin=xStatus notify
descr='Contact status changed'
wparam=hContact
lparam=parameter

I have defined an action with 2 elements. First is a "Jump" with following condition:
Code: [Select]
Condition: Math: parameter and $63770000
Operation: Break
This is a rude attempt to check if higher part of parameters contains ID_STATUS_ONLINE.

Second element is service CList/ContactDoubleClicked with "current contact" as wParam.

The result is that Miranda hangs, when contact goes on-linine. Since I mostly have guessed how to configure ActMan, this result is not unexpected. I would appreciate any help in configuring it correctly.

--
popej
 

Offline Awkward

  • Developer
  • *****
  • Posts: 23
  • Jabber: Jabber ID
Re: open message window, when contact goes on-line
« Reply #9 on: 25 03 2015, 18:17:09 »
Slightly uncomfortable to check it for me right now. if crashlog presents, can you show it to me?
 


Offline popej

  • Newbie
  • *
  • Posts: 6
  • Country: pl
    • GMapTool
Odp: open message window, when contact goes on-line
« Reply #11 on: 25 03 2015, 23:52:48 »
Miranda hangs, I kill it with process manager but I don't get crush log. This is stack window from Process Explorer:

Code: [Select]
ntdll.dll!NtWaitForSingleObject+0xa
KERNELBASE.dll!WaitForSingleObjectEx+0x9c
actman.dll!MirandaPluginInfoEx+0x1eb0
actman.dll!MirandaPluginInfoEx+0x218e

Miranda NG Version: 0.95.3 build #11706 x64 Build time: 1 Jan 2015 14:27:34
Actman.dll v.0.3.0.1 [1 Jan 2015 15:28:02] - Action manager
--
popej
 

Offline Awkward

  • Developer
  • *****
  • Posts: 23
  • Jabber: Jabber ID
Re: open message window, when contact goes on-line
« Reply #12 on: 26 03 2015, 05:54:31 »
Looks like memory allocation problem somewhere. but can't recognize place, so, will need to check (idk how yet) by myself

BTW, i published some memory fixes not so long time ago, so, maybe it was fixed already in nightly builds