mIRC Home    About    Download    Register    News    Help

Print Thread
#112845 26/02/05 06:54 PM
Joined: Aug 2004
Posts: 237
L
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Aug 2004
Posts: 237
I'm hoping it is possible to make mIRC refresh the system tray (the thing where windows displays the time), and hoping that someone can script that, in mIRCscript or through a dll.
I need it because I have a program running in tray that I 'kill', I stop it's process through a script, and it's icon stays in tray until I move over it with my mouse pointer. Refreshing the tray after 'killing' it would make it disappear instead of being there afterwards.
Thanx in advance!

EDIT: Or is there a way to 'ask' a program to shutdown the way it is supposed to be, and not kill it's process?

Last edited by LethPhaos; 26/02/05 07:40 PM.
#112846 27/02/05 03:17 AM
Joined: Aug 2003
Posts: 1,831
I
Hoopy frood
Offline
Hoopy frood
I
Joined: Aug 2003
Posts: 1,831
Using mouseevents.dll by fugitive

Mess with the co-ordinates (It's set for a fairly large tray at the lower right), and inc values.

Note: Icon must be visible (Not hidden by Wins "Hide inactive icons")

Code:
alias refresh.tray {
  var %a = $window(-1).w,%b = %a - 256
  ; ^ Screen width and same minus 256
  var %c = $window(-1).h,%d = %c - 48
  ; ^ Screen height and same minus 48
  var %x = $mouse.dx $mouse.dy
  ; Stores current position

  while %b < %a {
    : loop until cursor is at far right of screen
    while %d < %c {
      ; loop until cursor is at bottom of screen
      dll mouseevents.dll movemouse %b %d
      ; ^ moves cursor downwards in 10 pix increment (/inc line below)
      inc %d 10
    }
    %d = %c - 50
    ; Reset height var
    dll mouseevents.dll movemouse %b %d
    ; ^ moves cursor to the right in 10 pix increment (/inc line below)
    inc %b 10
  }
  dll mouseevents.dll movemouse %x
  ; Restores cursor position
}

#112847 27/02/05 10:44 AM
Joined: Aug 2004
Posts: 237
L
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Aug 2004
Posts: 237
This is a perfect solution, which is funny to see happen too laugh.
Thanx a lot!

I was wondering if there was a solution that didn't move the mousecursor?
Is there a way to make a program shutdown willingly without killing it's process? Windows does such thing on system shutdown, there is software to do it too, but I want to do it from within mirc, is this possible in any way?

#112848 27/02/05 03:15 PM
Joined: Feb 2004
Posts: 2,019
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
What program is it?


Gone.
#112849 27/02/05 06:19 PM
Joined: Aug 2004
Posts: 237
L
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Aug 2004
Posts: 237
well, there is telemeter.exe, a prog that checks the status of my upload and download limits, there is heatup, a cpu stress tool, there is coolmon, such things.

#112850 27/02/05 06:20 PM
Joined: Feb 2004
Posts: 2,019
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
I'd need to know the exact program which is not killing its icon, or do you want to remove all of those you just listed?


Gone.
#112851 27/02/05 06:23 PM
Joined: Aug 2004
Posts: 237
L
Fjord artisan
OP Offline
Fjord artisan
L
Joined: Aug 2004
Posts: 237
I'm killing these programs sometimes, and I'm looking for a way to make them shutdown themselves and not killing the process, which would'nt be a good solution in case of software using settings that change sometimes, these settings would'nt be saved and used next startup of the program.
Not very clear, I hope you understand what i mean smile


Link Copied to Clipboard