Professional UI Solutions
Site Map   /  Register


Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » Hidden Page navigator Collapse All
Subject Author Date
Sergio Buonanno Nov 28, 2006 - 9:21 AM

The Page Navigator controls ignores any call to CExtPageNavigatorWnd::ITEM_PANE_INFO::HeightSet(h) when the control is contained in a CExtControlBar and the control bar is docked and hidden. It doesn’t set the height until its parent CExtControlBar object is pinned (Prof-UIS 2.54). IN this situation my application cannot manage a Favotites pane like Outlook if the user choose to set the parent control’s style to auto-hide.

Sergio Buonanno Nov 29, 2006 - 4:52 AM

I’m sorry I misunderstood the problem. When the parent control bar is hidden, the method CExtPageNavigatorWnd::ITEM_PANE_INFO::ItemRectGet() returns always the original rect (the rectangle set when the Page Navigator was created) not taking into account that the user could have modified the main window size and consequently the Page Navigator height (when it will show itself). I would need a function that can return the size that the pane will have when it will be shown by the user. Is there a function like that ?

Technical Support Nov 29, 2006 - 1:15 PM

Sergio, we already discussed this problem in May, 2006. We asked you to download the latest Prof-UIS version in which this bug had been fixed. Did you upgrade to the latest library version? What the version you are using now?

Sergio Buonanno Nov 30, 2006 - 12:56 AM

The problem discussed in May is fixed. The situation now is slightly different. The page Navigator is hidden when I set panes’ size. CExtPageNavigatorWnd::ITEM_PANE_INFO::ItemRectGet() returns the original rect (RECT set when the control was created) and it doesn’t take into account the height that the Page Navigator will have when it will be shown by the user; for example, when the main window of the application is resized by the user CExtPageNavigatorWnd::ITEM_PANE_INFO::ItemRectGet() doesn’t update the top and bottom values of the rectangle to adjust control’s height to the new parent window height, those values are updated only after the control bar is displayed and pinned. In other words I have no way to understand which height will have every pane until I don’t pin the parent control bar. If the parent control bar will remain with the auto-hide property set the rectangle returned by CExtPageNavigatorWnd::ITEM_PANE_INFO::ItemRectGet() won’t be updated after a resize of the application main window.

My application uses a Favorite pane that contains a tree view control in the upper area of the page and another pane with a different tree view control in a lower pane, I set the upper pane’s height at application startup to 23 pixels and the lower pane’s height to -1 (to let it lake the remaining free area) but when the user resize the main window I try to recalculate the panes’ height so that the upper one will never have more than half the available height of the page client rectangle, the same is for the lower pane, but this work only when the Page Navigator is displayed (control bar’s auto-hide property set to false), when the parent control bar is hidden I have no way to get the new height the page will have when it will be displayed by the user. I need a way to calculate that height when auto-hide is on, maybe it’s my mistake.

Technical Support Dec 1, 2006 - 8:11 AM

You should perform all the layout calculations at the end of the CMainFrame::OnCreate() method after the state of control bars has been loaded or all the bars have been docked initially. At this step the frame window is invisible and will be displayed without changing the window size because the code for loading the UI state also restores the window position and size. If the state was not loaded successfully and you are displaying the main frame window initially maximized, then please ensure the CMainFrame::PreCreateWindow() method specifies the WS_MAXIMIZE window style. All these issues should guarantee the main frame window will have the needed size to perform the layout calculations at the end of the CMainFrame::OnCreate() method.