mIRC Home    About    Download    Register    News    Help

Topic Options
#249586 - 05/12/14 08:40 PM mIRC not in foreground: `window -g3` doesnt update
Zarthus Offline
Pikka bird

Registered: 16/08/14
Posts: 12
Hello!

I have the following mIRC script:
Code:

; Stop query windows from flashing after 20 seconds by setting them to an 'event' state.
ON *:OPEN:?: { 
  .timer 1 20 setQueryColourToEvent $nick
}

ON *:TEXT:*:?: {
  .timer 1 20 setQueryColourToEvent $nick
}

alias setQueryColourToEvent {
  if ($window($$1).sbcolor != $null && $window($$1).sbcolor != event) { 
    window -g3 $$1
  }
}



The code itself works when mIRC is in the foreground, when I am actively chatting, etc.

However, when in the background (for example, when playing a game, on dual monitors) - this does not work fully as expected. It will change colours (in my case, from flashing red to flashing cyan. The issue here is that it is still flashing, and it will keep flashing until I turn mIRC back into the foreground. I should note that this is within the treebar that I have positioned on the left, with no foldering structure.

I'm not sure if this will be an easy fix, or lies perhaps within the mIRC core itself. But it is quite annoying to have to switch mIRC to the foreground to stop it from flashing, as that is what I initially wanted to disable.

If there are better ways to make it stop flashing, I'm open to suggestions.

This is (tested) on mIRC versions 7.36 and 7.38

In short, reproduction steps:

  • Load the above script or write a test script that uses `window -g3 $nick' somewhere.
  • Let someone open a new query with you, and ensure mIRC is not on the foreground.
  • Wait for the script to trigger, and move your eyes to be focused on the part where the query is.
  • The query icon will still be flashing.
  • Put mIRC to the foreground (by simply clicking on it), the flashing will stop.


Should this issue not be entirely clear to you, perhaps this image will make it clearer, where *status is still flashing:


Thanks!
- Zarthus.


Edited by Zarthus (05/12/14 08:42 PM)

Top
#249587 - 05/12/14 09:31 PM Re: mIRC not in foreground: `window -g3` doesnt update [Re: Zarthus]
Loki12583 Offline
Hoopy frood

Registered: 22/01/04
Posts: 1268
/window -g is not meant to control flashing.

You may want to disable this in the options:
IRC > Options > 'Flash on message'

Then change your open event to /flash -r20 $nick

Top
#249595 - 06/12/14 11:54 AM Re: mIRC not in foreground: `window -g3` doesnt update [Re: Zarthus]
Zarthus Offline
Pikka bird

Registered: 16/08/14
Posts: 12
Thank you, that solved my problem. :-)

Code:
; Stop query windows from flashing after 20 seconds by setting them to an 'event' state.
; Ensure Options -> IRC -> Flash On Message (Query) is turned off.
ON *:OPEN:?: { 
  flash -r20 $nick
  .timer 1 20 setQueryColourToEvent $nick
}

ON *:TEXT:*:?: {
  flash -r20 $nick
  .timer 1 20 setQueryColourToEvent $nick
}

alias setQueryColourToEvent {
  if ($window($$1).sbcolor != $null && $window($$1).sbcolor != event) { 
    window -g3 $$1
  }
}

Top