Skip to content
This repository has been archived by the owner on May 31, 2023. It is now read-only.

Menu open events clean up #8

Closed
wants to merge 4 commits into from
Closed

Menu open events clean up #8

wants to merge 4 commits into from

Conversation

vadz
Copy link
Collaborator

@vadz vadz commented Mar 24, 2016

This series of patches from November 2014 is related to the problem originally reported here and posted to the list slightly later. The mailing list message provides further information about these patches.

This PR is not the most urgent one as nothing else depends on it but I still think it makes sense to apply it as it's always nice to remove unnecessary code.

Connect Skeleton::UponMenuOpen() only to the menu open events for the main
frame menus instead of indiscriminately handling all the events ending in the
application object.

This ensures that we never use the possibly already destroyed main frame
pointer if another frame (with a menu) comes up during the application
shutdown, as it could happen in the automated GUI tests.
Make the code in Skeleton::UponMenuOpen() marginally more efficient and
slightly more clear and avoid pointer-to-integer coercion by just checking if
more than one child exists instead of counting all of them.
Remove the comment explaining that wxDocMDIChildFrame doesn't have an
explicitly virtual dtor as it is out of date since at least wxWidgets 3.0 (and
possibly earlier) and this dtor itself is completely superfluous, so remove it
too.
This code actually had no effect because the MDI child frame never received
wxEVT_MENU_HIGHLIGHT anyhow and the help was (correctly) displayed in the
parent frame status bar just because this is where all the events went.
@vadz
Copy link
Collaborator Author

vadz commented Mar 30, 2016

Committed as of 436a425

@vadz vadz closed this Mar 30, 2016
@vadz vadz deleted the menu-open-events branch May 6, 2016 17:01
vadz pushed a commit that referenced this pull request Jun 8, 2022
/opt/lmi/src/lmi/fdlibm_expm1.c:243:13: runtime error: left shift of negative value -2
    #0 0x5633bb2b0576 in fdlibm_expm1 /opt/lmi/src/lmi/fdlibm_expm1.c:243
    #1 0x5633bb2f18ba in test_expm1_log1p() /opt/lmi/src/lmi/math_functions_test.cpp:662
    #2 0x5633bb2fb7ea in test_main(int, char**) /opt/lmi/src/lmi/math_functions_test.cpp:804
    #3 0x5633bb2fbd56 in cpp_main(int, char**) /opt/lmi/src/lmi/test_main.cpp:171
[uninteresting #4 - #8 snipped]
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant