Menu

#108 wxAUI pane focus

open
None
5
2009-02-26
2009-02-20
Salvo Isaja
No

Greetings,
not really sure if this is a bug of wxPropertyGrid. With wxPG 1.4.4 on wxMSW 2.8.9, create a frame, attach it a wxAuiManager, create two or more AUI panes (I've used wxFormBuilder for that):
pane 1: wxPanel containing wxBoxSizer containing a wxPropertyGrid;
pane 2: wxPanel containing wxBoxSizer containing, for example, a wxListCtrl;
like this:

MyFrame::MyFrame(wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style)
wxFrame(parent, id, title, pos, size, style),
auiManager(this, wxAUI_MGR_DEFAULT | wxAUI_MGR_ALLOW_ACTIVE_PANE)
{
auiManager.AddPane(pane1, wxAuiPaneInfo().Name(wxT("pane1")).Caption(_("Pane 1")).CenterPane());
auiManager.AddPane(pane2, wxAuiPaneInfo().CloseButton(false). Name(wxT("pane2")).Caption(_("Pane 2")).Left());
auiManager.Update();
}

The problem:
switching between panes does not mark the pane heading as focused (blue bar instead of gray bar) if jumping to/from the property grid.
Hope this is clear.
Thanks,
Salvo

Discussion

  • Jaakko Salli

    Jaakko Salli - 2009-02-26

    I'm quite busy right now, so if you want to see this and any other of your bugs resolved quickly, please add a minimal, single-file sample app that reproduces the issue.

    TIA,
    Jaakko

     
  • Jaakko Salli

    Jaakko Salli - 2009-02-26
    • assigned_to: nobody --> jmsalli
     
  • Salvo Isaja

    Salvo Isaja - 2009-02-27

    I see. I've finally managed to prepare a minimal sample for this, too (attached). Try clicking on the property grids and on the list controls. You will see that the pane title is marked as active (blue) only when switching between the list controls.
    The very same sample shows bug 2629969.
    Thanks,
    Salvo
    File Added: minimal.cpp.bz2

     
  • Salvo Isaja

    Salvo Isaja - 2009-02-27
     
  • Jaakko Salli

    Jaakko Salli - 2009-03-03

    Thanks for the sample, I've found the cause. Problem is that I can't fix this until following wxWidgets bug is resolved:

    http://trac.wxwidgets.org/ticket/4840

    If you want to see the problem in action do the following: I've attached an alternate version of your minimal sample - use it. I've added lots of properties in the top-left propgrid. In src/propgrid.cpp, in void wxPropertyGrid::OnChildFocusEvent( wxChildFocusEvent& event ), add event.Skip() call, or remove the conditions surrounding the existing call. You will now see that the pane focus will work, but there will be erratic auto-scrolling when you click on properties when grid is in scrolled position.

     
  • Jaakko Salli

    Jaakko Salli - 2009-03-03
     

Log in to post a comment.