AutoHotkey Community

It is currently May 27th, 2012, 1:40 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: January 13th, 2010, 6:41 pm 
Offline

Joined: February 6th, 2005, 10:40 pm
Posts: 26
I have set windows taskbar to autohide. which means the taskbar only pops up when the win key is pressed OR the mouse is positioned at the bottom of the screen.
if the title bar of a window is removed using this code:
Code:
#b::WinSet, Style, ^0xC00000, A

then the taskbar does not show up as it should. Sometimes. positioning the mouse at the bottom has no effect..

any solutions for this ?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 14th, 2010, 8:56 am 
Offline

Joined: December 30th, 2005, 5:01 pm
Posts: 448
Maybe you're sometimes changing the style of the taskbar? Try:
Code:
#IfWinNotActive ahk_class Shell_TrayWnd   ; taskbar is not active window
   #b::WinSet, Style, ^0xC00000, A
#IfWinNotActive


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 14th, 2010, 9:15 am 
Offline

Joined: February 6th, 2005, 10:40 pm
Posts: 26
nope that didn't help :(


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 14th, 2010, 9:55 am 
Offline

Joined: December 30th, 2005, 5:01 pm
Posts: 448
chessonly wrote:
Sometimes. positioning the mouse at the bottom has no effect.
I've did some tests. It gives always problems with maximized windows.
I think Windows doesn't do what it promises in the setting "Keep the taskbar on top of other windows".
Maybe still a solution possible. I will look again when I've got some more time.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 14th, 2010, 10:15 am 
Offline

Joined: February 6th, 2005, 10:40 pm
Posts: 26
k, thanksq


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 14th, 2010, 12:37 pm 
Offline

Joined: December 30th, 2005, 5:01 pm
Posts: 448
That damn auto-hide taskbar is quite difficult to tame.
Maybe code can be more fine-tuned, but I tried several things, and at the end always some problem came up again.
I did some testing, and this seems to work, but not 100% guarantee:
Code:
WinGet, taskbarID, id, ahk_class Shell_TrayWnd
#IfWinNotActive ahk_class Shell_TrayWnd   ; taskbar is not active window
   #b::
      WinGet, activeID, id, A
      WinSet, Style, ^0xC00000, ahk_id %activeID%
      WinGet, winStyle, style, ahk_id  %activeID%
      if !(winStyle & 0xC00000){
         sleep 1500   ; delay seems necessary, I don't know exactly why though
         DllCall("SetWindowPos", "uint", taskbarID, "uint",0, "int",0, "int",0, "int",0, "int", 0, "uint", 0x253)
         ; 0x253: SWP_NOACTIVATE= 0x10  SWP_NOOWNERZORDER= 0x200
         ;        SWP_SHOWWINDOW= 0x40  SWP_NOMOVE= 2 & SWP_NOSIZE= 1 (->all coord. can = 0)
         WinGetPos, X, Y, Width, winH, ahk_id %activeID%
         WinMove, ahk_id %activeID%, , , , , % winH - 6  ; necessary? after a Win-key
         WinSet, AlwaysOnTop, off, ahk_class Shell_TrayWnd
         WinSet, AlwaysOnTop, on, ahk_class Shell_TrayWnd
         tooltip taskbar recovered    ; for testing
      }
      else
         tooltip
   return
#IfWinNotActive


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 14th, 2010, 12:57 pm 
Offline

Joined: February 6th, 2005, 10:40 pm
Posts: 26
, as complicated as it is, yes that does seem to work! :)
thanks a lot
edit: i spoke too soon :(


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: bobbysoon, iDrug, JSLover, Tipsy3000, Yahoo [Bot] and 20 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group