[Git][wxwidgets/wxwidgets][master] 3 commits: Fix positioning of wxMessageBox with iconized parent in wxMSW

2 views
Skip to first unread message

Vadim Zeitlin (@_VZ_)

unread,
Mar 4, 2026, 3:49:19 PM (5 days ago) Mar 4
to wx-commi...@googlegroups.com

Vadim Zeitlin pushed to branch master at wxWidgets / wxWidgets

Commits:

  • 29bdfb3f
    by Vadim Zeitlin at 2026-03-04T20:04:57+01:00
    Fix positioning of wxMessageBox with iconized parent in wxMSW
    
    It was shown in the top left corner which was unexpected, so avoid using
    TDF_POSITION_RELATIVE_TO_WINDOW (whose implementation is arguably buggy)
    in this case to show it in the center of the screen instead.
    
    Closes #26262.
    
  • d42e21f3
    by Vadim Zeitlin at 2026-03-04T20:06:42+01:00
    Remove confusing comment in wxMSW task dialog code
    
    No real changes, just remove a comment which didn't make sense.
    
  • 56366aa8
    by Vadim Zeitlin at 2026-03-04T21:15:26+01:00
    Fix installation of 3.3.3 under macOS
    
    The pattern "libx*3.3" matched not just the desired symlinks, but also
    the actual libraries due to "3.3" matching at the end of "3.3.3".
    
    Fix this by making the pattern more restrictive.
    

3 changed files:

Changes:

  • configure
    No preview for this file type
  • configure.ac
    ... ... @@ -3730,7 +3730,7 @@ destdir=\$1
    3730 3730
     libdir=\$2
    
    3731 3731
     bindir=\$3
    
    3732 3732
     build_libdir=\$4
    
    3733
    -libnames=\$(cd \${build_libdir}; printf '%s\n' libwx*${WX_RELEASE}.dylib)
    
    3733
    +libnames=\$(cd \${build_libdir}; printf '%s\n' libwx*-${WX_RELEASE}.dylib)
    
    3734 3734
     changes=''
    
    3735 3735
     for libname in \${libnames} ; do
    
    3736 3736
         target=\$(readlink \${build_libdir}/\$(readlink \${build_libdir}/\${libname}))
    

  • src/msw/msgdlg.cpp
    ... ... @@ -646,14 +646,19 @@ void wxMSWTaskDialogConfig::MSWCommonTaskDialogInit(TASKDIALOGCONFIG &tdc)
    646 646
         // fully shown for reasonably-sized words whereas without it using almost
    
    647 647
         // any file system path in a message box would result in truncation.
    
    648 648
         tdc.dwFlags = TDF_EXPAND_FOOTER_AREA |
    
    649
    -                  TDF_POSITION_RELATIVE_TO_WINDOW |
    
    650 649
                       TDF_SIZE_TO_CONTENT;
    
    651 650
         tdc.hInstance = wxGetInstance();
    
    652 651
         tdc.pszWindowTitle = caption.t_str();
    
    653 652
     
    
    654
    -    // use the top level window as parent if none specified
    
    655 653
         tdc.hwndParent = parent ? GetHwndOf(parent) : nullptr;
    
    656 654
     
    
    655
    +    // Don't use this flag if our parent window is minimized because this
    
    656
    +    // results in the task dialog being shown in the top left corner of the
    
    657
    +    // screen, which is completely unexpected, so prefer the default behaviour
    
    658
    +    // of centering the dialog on the screen in this case.
    
    659
    +    if ( parent && !::IsIconic(tdc.hwndParent) )
    
    660
    +        tdc.dwFlags |= TDF_POSITION_RELATIVE_TO_WINDOW;
    
    661
    +
    
    657 662
         if ( wxApp::MSWGetDefaultLayout(parent) == wxLayout_RightToLeft )
    
    658 663
             tdc.dwFlags |= TDF_RTL_LAYOUT;
    
    659 664
     
    

Reply all
Reply to author
Forward
0 new messages