Print Page | Close Window

Tiling windows on XP fails for CodeJock apps.

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=14713
Printed Date: 05 May 2024 at 3:02am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Tiling windows on XP fails for CodeJock apps.
Posted By: rdhd
Subject: Tiling windows on XP fails for CodeJock apps.
Date Posted: 09 July 2009 at 5:11pm
Using V11.2, build and start the ribbonsample. Then start the ribbon sample and a couple of windows explorers. Then go to the taskbar and right-click and choose the "Tile Windows Vertically" command. Notice that the ribbonsample does not participate in the tiling.
 
Or: Close all windows on the desktop. Start Visual Studio and open the ribbon sample. Then start the sample. Run "Tile Windows Vertically" and notice that Visual Studio is resized to fit the entire desktop (resized, not maximized).
 
A codejock app fails to work with the "Tile Windows Horizontally" command too.
 
Why doesn't CodeJock based applications function correctly with the task bar tile windows commands?
 
Or more importantly, how do I fix this problem?
 
A bit more info ... No problem on Vista (Show windowws stacked/sid by side) with V11.2. Also, the problem exists with V13.0 on XP (new customer problem report just filed on the version of our product that is running with 13.0 on XP). Fix becoming more important as customer complaints come in ...



Replies:
Posted By: Oleg
Date Posted: 10 July 2009 at 5:59am
Hi,
 
yes, Ribbon Frame removes WS_CAPTION style to draw its own caption  and TaskBar doesn't arrange windows without this style :-(
 
If you don't use Ribbon Frame you won't see it.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: znakeeye
Date Posted: 10 July 2009 at 6:24am
Perhaps you could hook this particular command and temporarily disable the ribbon frame?

-------------
PokerMemento - http://www.pokermemento.com/


Posted By: Oleg
Date Posted: 10 July 2009 at 6:31am
Hi,
 
TaskBar doesn't send something to hook :(


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: znakeeye
Date Posted: 10 July 2009 at 9:57am
Word handles this properly :(

-------------
PokerMemento - http://www.pokermemento.com/


Posted By: znakeeye
Date Posted: 10 July 2009 at 10:03am
403 = Cascade
404 = Tile Horizontally
405 = Tile Vertically
 
There you have the IDs. Hook WM_COMMAND + ID + classname, and you are ready to rock.
 
 
Some more info. VB-hack:
http://fisheye1.atlassian.com/browse/~raw,r=1.1/rssbandit/v1.2.0.114/Source/ChildProjects/ShellBasics/ShellBasics/ApplicationDesktopToolbar.cs - http://fisheye1.atlassian.com/browse/~raw,r=1.1/rssbandit/v1.2.0.114/Source/ChildProjects/ShellBasics/ShellBasics/ApplicationDesktopToolbar.cs


-------------
PokerMemento - http://www.pokermemento.com/


Posted By: znakeeye
Date Posted: 10 July 2009 at 10:18am
WM_NOTIFY + ABN_WINDOWARRANGE, I'd guess.
http://msdn.microsoft.com/en-us/library/bb774198%28VS.85%29.aspx - http://msdn.microsoft.com/en-us/library/bb774198(VS.85).aspx
 
It should be possible to hook the taskbar and react to these messages... I wonder how MS word does this!


-------------
PokerMemento - http://www.pokermemento.com/


Posted By: rdhd
Date Posted: 11 July 2009 at 9:52am
Vista must have removed the restriction Oleg mentions since I don't see the problem there. I wonder what happens if I add the style back after the frame is created. Will the CJ ribbon simply overdisplay the other (and will display be fast enough so users don't really see it) or perhaps not display at all. Or is removing the style part of the fix that CJ added to prevent display issues we had in V11 where the original title area of the MFC frame can sometimes end up displayed over the CJ ribbon? I had a solution for that to force the ribbon to redisplay when it needed to but I could see the "flash" of the underlying frame display when it happened.


Posted By: rdhd
Date Posted: 11 July 2009 at 9:59am
Looks like the Word frame window has the WS_CAPTION style and the caption is what one sees displayed. Their "ribbon" overlay window has the style and its caption is "Ribbon", which is not displayed. When I monitor the messages the Word frame window gets, I see the WM_WINDOWPOSCHANGED and other messages I would expect when I run one of the task bar tiling commands.


Posted By: rdhd
Date Posted: 16 July 2009 at 2:31pm
Oleg,
 
What do you mean by the ribbon frame? When I run spy++ and find a window in the CJ V12 ribbon sample, if I place the find icon over the command ribbon, I see the caption is "The Ribbon" and class is "XTPToolBar". That window does not have the WS_CAPTION style. But if I find the frame window, I see that the WS_CAPTION style is set. That frame window class is "XTPMainFrame" and it has the WS_CAPTION style.
 
In V11, the "XTPMainFrame" of the sample does not have the WS_CAPTION style.
 
However, in both cases, the CJ app fails to tile on XP.
 
Also, we have our current released app built on V11.2. I found code in your source that removed the WS_CAPTION style. I set a breakpoint and skip the call. Our app then does indeed participate in the tiling commands. However a regression immediatly shows up. The old underlying MFC (blue) caption bar displays over the top of the CJ command ribbon. In V12, which we are using to build the next version of our app, I don't see any code in CJ that removes the style from the frame. But as I said, we still fail to tile.
 
When I locate my app's frame, the WS_CAPTION style is set on it. We derive our frame class from CXTPMDIFrameWnd. So which of the windows I am locating are you referring to and why doesn't the CJ apps tile with V12 since it appears the WS_CAPTION style is not being removed?



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net