Jump to content

Notify Window


GioVit
 Share

Recommended Posts

Sypher, could this be done by setting the Z order of the message windows? I am not entirely sure how to do it myself, yet, but this program looks very cool. I am interested in using this in place of baloon messages. Its more noticeable.

What z-order? I only see X and Y :whistle:

Sorry, I was thinking about multiple Notification Windows, and changes requires a lot of code:

1) Need an array of windows handles

2) Then need a function that check the TimeOut of each Notification Windows (with AdLibEnable()) and Close the window if time Expired

3) When Closing a Notification Window By scrolling It the program must scroll all the other Notification Windows that are shown above or have not expired time yet.

4) When Open a New Notification Window you must use WinSetOnTop() on the Notification Window that you prefer to see.

so is a lot of work and the part 3) is the most dificult to implement.

I will try to Modify it, but it will take some time.

I don't really understand 3).. Is that the way - for example - Messenger works?

Also, i was wondering... Would it be possible to stop the auto-hide if the mouse is hovering on the toast?

Would that be possible somehow?

Either way, i'm still looking forward to a new version.

Link to comment
Share on other sites

  • Replies 40
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

What z-order? I only see X and Y :whistle:

I don't really understand 3).. Is that the way - for example - Messenger works?

Also, i was wondering... Would it be possible to stop the auto-hide if the mouse is hovering on the toast?

Would that be possible somehow?

Either way, i'm still looking forward to a new version.

Just a little modification:

- $Timeout now is set to 0 by default so it will not autohide until you click the message or the exit button

- if $Timeout is greater than 0 then it will hide at the elapsed time ($Timeout value is in milliseconds)

See the first post for the new version.

Give me more time for your other request.

Link to comment
Share on other sites

Nice script!

But i have a problem if it is compiled. The popup comes up and disappears ... till time out ... then it went down.

No chance to read the Iínfo or click on it.

In scite it works fine.

Any idea? :whistle:

CU

Dizzy

Link to comment
Share on other sites

Nice script!

But i have a problem if it is compiled. The popup comes up and disappears ... till time out ... then it went down.

No chance to read the Iínfo or click on it.

In scite it works fine.

Any idea? :whistle:

CU

Dizzy

Try to run/compile it with this parameters

$Ret = _Popup("MyPopup", "You have 3 mails")

it must work

Link to comment
Share on other sites

Hi GioVit,

sorry no success. :P

Have a look a the small avi. Another idea?

I'm working with 3.2.3.0 Beta and 3.2.2.0 Release of AutoIt.

I've tried both compiled versions - same effect.

Update: OK, after playing around with msgboxes i think the problem must be in this area.

In the function "ShowPopup the call "GUIMove($Title, 0, -$iWinHeight)" will be executed and direct after the call the window disappears.

So the problem has to be found in the "GUIMove" section - but i can't find a thing ... :D

Do you, GioVit?

Update2: OK - if i remark the following lines (217, 218)

WinSetTrans($Title, "", $IncTrans*$i)

Else

the effect switches. Now the compiled version works fine, but in scite the window disappeas ... hmmm?

Update3: Solved!

OK - the problem was the transparency of the popup. If it was fully visible, the count was over 255 (260.1) - and thís causes the window to be hidden.

To ways to prevent this:

1.) change the line 218 to

WinSetTrans($Title, "", $IncTrans*$i-5)

OR

2.) change the "255" in line 212 and 220 to a value equal or less than 250.

I take the second option and this works fine for me! :whistle:

CU

Dizzy

Notify.zip

Edited by Dizzy
Link to comment
Share on other sites

Dizzy

I Downloaded your files and you are right when I executed your .exe file it has the same result of the video, but I re- compiled the .au3 in your .zip file and It work fine. So the only thing I can recommend you is to reinstall AutoIt Version 3.2.2.0.

btw Your exe was compiled with Version 3.2.3.0 and has 214KB and I compiled it with 3.2.2.0 and has 208KB.

if it run Ok with old Autoit Version then may be there is a bug in Version 3.2.3.0

Link to comment
Share on other sites

Dizzy

I Downloaded your files and you are right when I executed your .exe file it has the same result of the video, but I re- compiled the .au3 in your .zip file and It work fine. So the only thing I can recommend you is to reinstall AutoIt Version 3.2.2.0.

btw Your exe was compiled with Version 3.2.3.0 and has 214KB and I compiled it with 3.2.2.0 and has 208KB.

if it run Ok with old Autoit Version then may be there is a bug in Version 3.2.3.0

Hi GioVit,

you're right - nearly.

I did 2 tests, both with the release 3.2.2.0. One time just "compile" the other one with "compile with options".

When i "compile with options" i just take a different icon - nothing else and i get my error. If i compile normal - all will be fine.

So there must be a bug in the "compile with options". Can you proof/check this? :whistle:

Dizzy

Link to comment
Share on other sites

Hi GioVit,

you're right - nearly.

I did 2 tests, both with the release 3.2.2.0. One time just "compile" the other one with "compile with options".

When i "compile with options" i just take a different icon - nothing else and i get my error. If i compile normal - all will be fine.

So there must be a bug in the "compile with options". Can you proof/check this? :whistle:

Dizzy

Yes Dizzy, I have the same error when "compile with options", its a bug definitely.

btw nice "exit.jpg" icon I'm looking for some icons to add to my other project called "Command Launcher", where can I find some icons like (that represent) Add, Remove, Edit, etc..?

Sorry If I delay my answers but there are moments that I'm really bussy.

Link to comment
Share on other sites

Yes Dizzy, I have the same error when "compile with options", its a bug definitely.

btw nice "exit.jpg" icon I'm looking for some icons to add to my other project called "Command Launcher", where can I find some icons like (that represent) Add, Remove, Edit, etc..?

Sorry If I delay my answers but there are moments that I'm really bussy.

No problem for the delay :whistle:

Who has to be informed about the bug? Maybe there are other functions which will generate false output.

CU

Dizzy

Link to comment
Share on other sites

  • 2 weeks later...

hehe. I guess it was an easy task to get the window always on top.

goto guimessage.au3 line 135:

change this:

$handle = GUICreate($Title, $iWinWidth, $iWinHeight, $Xpos, $Ypos, $WS_POPUPWINDOW,$WS_EX_TOOLWINDOW);$WS_SIZEBOX + $WS_POPUPWINDOW)

to this:

$handle = GUICreate($Title, $iWinWidth, $iWinHeight, $Xpos, $Ypos, $WS_POPUPWINDOW,$WS_EX_TOOLWINDOW+$WS_EX_TOPMOST);$WS_SIZEBOX + $WS_POPUPWINDOW)

cheers

Edited by thor918
Link to comment
Share on other sites

For the problem with AutoIt 3.2.3.5, I found that the probleme became of this function :

Func GUIMove($Title, $Dx=0, $Dy=0, $Time=700, $Showing = True)
Dim $Incx, $Incy, $IncTime, $Offsetx, $Offsety
    $Incx = $Dx/($Time/15)
    $Incy = $Dy/($Time/15)
    $IncTrans = 255/($Time/15)
    $Pxy = WinGetPos($Title)
    $i = 1
    While 1
        if $Showing Then
            WinSetTrans($Title, "", $IncTrans*$i)
        Else
            WinSetTrans($Title, "", 255 - $IncTrans*$i)
        EndIf 
    
        WinMove($Title,"", $Pxy[0]+$Incx*$i, $Pxy[1]+$Incy*$i)
        Sleep(15)
        if abs($Incx*$i) >= Abs($Dx) and Abs($Incy*$i) >= Abs($Dy) then ExitLoop
        $i += 1
        
    WEnd
EndFunc

In particular, when this : $Pxy[1]+$Incy*$i have a particular value (In relation with systray (Probably outside of the systray)).

Don't know how for the moment, but it's the direction.

I think we must modify this line :

if abs($Incx*$i) >= Abs($Dx) and Abs($Incy*$i) >= Abs($Dy) then ExitLoop

I will continue search ...

Sorry for my bad English.

I hope that you understand what I'm explain !!!

Edited by Tlem

Best Regards.Thierry

Link to comment
Share on other sites

Like this, all is working fine with the compiled script !!!

Even if I modifie the size of the systray, and if I put it on Up, Left, right or down of the screen :shocked: .

Func GUIMove($Title, $Dx=0, $Dy=0, $Time=700, $Showing = True)
Dim $Incx, $Incy, $IncTime, $Offsetx, $Offsety
    $Incx = $Dx/($Time/15)
    $Incy = $Dy/($Time/15)
    $IncTrans = 255/($Time/15)
    $Pxy = WinGetPos($Title)
    $i = 1
    While 1
        if $Showing Then
            WinSetTrans($Title, "", $IncTrans*$i)
        Else
            WinSetTrans($Title, "", 255 - $IncTrans*$i)
        EndIf 
        
        WinMove($Title,"", $Pxy[0]+$Incx*$i, $Pxy[1]+$Incy*$i)
        Sleep(15)
        if abs($Incx*$i) >= Abs($Dx)-5 and Abs($Incy*$i) >= Abs($Dy)-5 then ExitLoop
        $i += 1
        
    WEnd
EndFunc
Edited by Tlem

Best Regards.Thierry

Link to comment
Share on other sites

  • 1 month later...

I really like this and I use this within my Player but I have one problem that I cannot solve myself...

The Popup always takes Focus.

And thats pretty sad because while you're writing and a new song begins your text goes to the popup.

I tried many things but I can't get the popup just work like MSN's popup.

Anyone has an idea?

greetings

Pascal

Link to comment
Share on other sites

  • 4 weeks later...
  • 2 months later...

Hi all,

I had problems getting AutoIt to do a popup the way I wanted, so I had someone write a C++ popup that's pretty flexible, ready to use in an AutoIt application I'm giving away in order to build a mailing list of people who might be interested in my other software releases.

I'm making the "toast popup" part available for other people to use in their own applications, but it's not free. It cost me $200 to get the code written, so I'm looking to recoup some of that by selling my executable for a low fee.

If you're interested, you can see more at http://automateyourbusiness.com/toast_popup.php

Regards,

Andy

(NB: My host has had a few issues today, so if you can't get to the site, I apologise. Please try again later).

Link to comment
Share on other sites

  • 8 months later...

I don't know why I can't see more posts in this thread but in the archive of this thread I found the solution to the following problem:

i can see the window when it moves onto the desktop and off (after the timeout) ... but it seems invisible when its not moving oO

The solution by JD2066:

The toast script in post #9 and above worked for me in version 3.2.2.0

When I installed version 3.2.10.0, I got the same problem.

I found it worked when I editing the code:

From: Func GUIMove($guiHandle, $Dx=0, $Dy=0, $Time=700, $Showing = True)

To: Func GUIMove($guiHandle, $Dx=0, $Dy=0, $Time=900, $Showing = True)

Not sure why.

Justin

Link to archive: http://www.autoitscript.com/forum/lofivers....php?t4343.html
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...