Assert in Symbol Properties (lp:#1817965)

[Original report](https://bugs.launchpad.net/bugs/1817965) created by **Seth Hillbrand (sethh)**
```
When editing the Symbol Properties from Eeschema, if you click and drag in
the grid twice, you get the following assertion in GTK (2 and 3).

After this, the dialog cannot be closed using the mouse.  It can only be
closed using the keyboard (shift + Enter) but Eeschema will segfault when
closing.  The assertion immediately before the segfault is (Destroying
window with mouse capture).  I'll add the second assertion in the next
message.

#0  0x00007ffff63a857b in raise (sig=5) at
../sysdeps/unix/sysv/linux/raise.c:50
#1  0x00007ffff7868e2d in wxGUIAppTraits::ShowAssertDialog(wxString const&)
() at /usr/lib/x86_64-linux-gnu/libwx_gtk2u_core-3.0.so.0
#2  0x00007ffff7346ab2 in  () at /usr/lib/x86_64-linux-
gnu/libwx_baseu-3.0.so.0
#3  0x00007ffff73489b0 in wxAppConsoleBase::OnAssertFailure(wchar_t const*,
int, wchar_t const*, wchar_t const*, wchar_t const*) ()
    at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#4  0x00007ffff78383b0 in wxApp::OnAssertFailure(wchar_t const*, int,
wchar_t const*, wchar_t const*, wchar_t const*) ()
    at /usr/lib/x86_64-linux-gnu/libwx_gtk2u_core-3.0.so.0
#5  0x00007ffff7348c68 in  () at /usr/lib/x86_64-linux-
gnu/libwx_baseu-3.0.so.0
#6  0x00007ffff7344b16 in wxOnAssert(char const*, int, char const*, char
const*, char const*) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#7  0x00007ffff7e026f7 in wxGrid::DoGridDragEvent(wxMouseEvent&,
wxGridCellCoords const&) () at /usr/lib/x86_64-linux-
gnu/libwx_gtk2u_adv-3.0.so.0
#8  0x00007ffff7e02b9e in wxGrid::ProcessGridCellMouseEvent(wxMouseEvent&)
() at /usr/lib/x86_64-linux-gnu/libwx_gtk2u_adv-3.0.so.0
#9  0x00007ffff74a97ae in
wxEvtHandler::ProcessEventIfMatchesId(wxEventTableEntryBase const&,
wxEvtHandler*, wxEvent&) ()
    at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#10 0x00007ffff74a98b3 in wxEventHashTable::HandleEvent(wxEvent&,
wxEvtHandler*) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#11 0x00007ffff74a9bec in wxEvtHandler::TryHereOnly(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#12 0x00007ffff74a9c73 in wxEvtHandler::ProcessEventLocally(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#13 0x00007ffff74a9d11 in wxEvtHandler::ProcessEvent(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#14 0x00007ffff74a9ab7 in wxEvtHandler::SafelyProcessEvent(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#15 0x00007ffff7871585 in  () at /usr/lib/x86_64-linux-
gnu/libwx_gtk2u_core-3.0.so.0
#16 0x00007ffff5ec11eb in  () at /usr/lib/x86_64-linux-
gnu/libgtk-x11-2.0.so.0
#17 0x00007ffff5c90c7d in g_closure_invoke () at /usr/lib/x86_64-linux-
gnu/libgobject-2.0.so.0
#18 0x00007ffff5ca4345 in  () at /usr/lib/x86_64-linux-
gnu/libgobject-2.0.so.0
#19 0x00007ffff5cac94b in g_signal_emit_valist () at /usr/lib/x86_64-linux-
gnu/libgobject-2.0.so.0
#20 0x00007ffff5cad91f in g_signal_emit () at /usr/lib/x86_64-linux-
gnu/libgobject-2.0.so.0
#21 0x00007ffff5fd7cac in  () at /usr/lib/x86_64-linux-
gnu/libgtk-x11-2.0.so.0
#22 0x00007ffff5ebf48c in gtk_propagate_event () at /usr/lib/x86_64-linux-
gnu/libgtk-x11-2.0.so.0
#23 0x00007ffff5ebf87b in gtk_main_do_event () at /usr/lib/x86_64-linux-
gnu/libgtk-x11-2.0.so.0
#24 0x00007ffff5d32bac in  () at /usr/lib/x86_64-linux-
gnu/libgdk-x11-2.0.so.0
#25 0x00007ffff59fcf2e in g_main_context_dispatch () at
/usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#26 0x00007ffff59fd1c8 in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
--Type <RET> for more, q to quit, c to continue without paging--
#27 0x00007ffff59fd4c2 in g_main_loop_run () at /usr/lib/x86_64-linux-
gnu/libglib-2.0.so.0
#28 0x00007ffff5ebe8e7 in gtk_main () at /usr/lib/x86_64-linux-
gnu/libgtk-x11-2.0.so.0
#29 0x00007ffff7851845 in wxGUIEventLoop::DoRun() () at
/usr/lib/x86_64-linux-gnu/libwx_gtk2u_core-3.0.so.0
#30 0x00007ffff737f48d in wxEventLoopBase::Run() () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#31 0x00007ffff12b94dc in DIALOG_SHIM::ShowQuasiModal()
(this=0x7fffffffd1d0) at /home/seth/code/kicad/kicad-
launchpad/common/dialog_shim.cpp:382
#32 0x00007ffff10f184f in SCH_EDIT_FRAME::EditComponent(SCH_COMPONENT*)
(this=0x55555692ce20, aComponent=0x555557c516d0)
    at /home/seth/code/kicad/kicad-
launchpad/eeschema/edit_component_in_schematic.cpp:132
#33 0x00007ffff114d432 in SCH_EDIT_FRAME::OnLeftDClick(wxDC*, wxPoint
const&) (this=0x55555692ce20, aDC=0x0, aPosition=...)
    at /home/seth/code/kicad/kicad-launchpad/eeschema/onleftclick.cpp:416
#34 0x00007ffff1163f00 in SCH_DRAW_PANEL::OnMouseEvent(wxMouseEvent&)
(this=0x555556c4a260, event=...)
    at /home/seth/code/kicad/kicad-
launchpad/eeschema/sch_draw_panel.cpp:352
#35 0x00007ffff74a97ae in
wxEvtHandler::ProcessEventIfMatchesId(wxEventTableEntryBase const&,
wxEvtHandler*, wxEvent&) ()
    at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#36 0x00007ffff74a9b2a in wxEvtHandler::SearchDynamicEventTable(wxEvent&)
() at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#37 0x00007ffff74a9bc0 in wxEvtHandler::TryHereOnly(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#38 0x00007ffff74a9c73 in wxEvtHandler::ProcessEventLocally(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#39 0x00007ffff74a9d11 in wxEvtHandler::ProcessEvent(wxEvent&) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#40 0x00007ffff74aa6b4 in wxEvtHandler::ProcessPendingEvents() () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#41 0x00007ffff734787f in wxAppConsoleBase::ProcessPendingEvents() () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#42 0x00007ffff7834649 in wxApp::DoIdle() () at /usr/lib/x86_64-linux-
gnu/libwx_gtk2u_core-3.0.so.0
#43 0x00007ffff7834743 in  () at /usr/lib/x86_64-linux-
gnu/libwx_gtk2u_core-3.0.so.0
#44 0x00007ffff59fcdd8 in g_main_context_dispatch () at
/usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#45 0x00007ffff59fd1c8 in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#46 0x00007ffff59fd4c2 in g_main_loop_run () at /usr/lib/x86_64-linux-
gnu/libglib-2.0.so.0
#47 0x00007ffff5ebe8e7 in gtk_main () at /usr/lib/x86_64-linux-
gnu/libgtk-x11-2.0.so.0
#48 0x00007ffff7851845 in wxGUIEventLoop::DoRun() () at
/usr/lib/x86_64-linux-gnu/libwx_gtk2u_core-3.0.so.0
#49 0x00007ffff737f48d in wxEventLoopBase::Run() () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#50 0x00007ffff7348616 in wxAppConsoleBase::MainLoop() () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#51 0x000055555559a2ab in APP_SINGLE_TOP::OnRun() (this=0x5555556adfd0) at
/home/seth/code/kicad/kicad-launchpad/common/single_top.cpp:197
#52 0x00007ffff73c9cf9 in wxEntry(int&, wchar_t**) () at
/usr/lib/x86_64-linux-gnu/libwx_baseu-3.0.so.0
#53 0x0000555555595e06 in main(int, char**) (argc=1, argv=0x7fffffffe0f8)
at /home/seth/code/kicad/kicad-launchpad/common/single_top.cpp:271


Application: kicad
Version: (5.1.0-rc2-10-g13249b723b), release build
Libraries:
    wxWidgets 3.0.4
    libcurl/7.64.0 OpenSSL/1.1.1a zlib/1.2.11 libidn2/2.0.5 libpsl/0.20.2
(+libidn2/2.0.5) libssh2/1.8.0 nghttp2/1.36.0 librtmp/2.3
Platform: Linux 4.19.0-2-amd64 x86_64, 64 bit, Little endian, wxGTK
Build Info:
    wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.24
    Boost: 1.67.0
    OpenCASCADE Community Edition: 6.9.1
    Curl: 7.64.0
    Compiler: Clang 7.0.1 with C++ ABI 1002

Build settings:
    USE_WX_GRAPHICS_CONTEXT=OFF
    USE_WX_OVERLAY=ON
    KICAD_SCRIPTING=ON
    KICAD_SCRIPTING_MODULES=ON
    KICAD_SCRIPTING_PYTHON3=ON
    KICAD_SCRIPTING_WXPYTHON=ON
    KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
    KICAD_SCRIPTING_ACTION_MENU=ON
    BUILD_GITHUB_PLUGIN=ON
    KICAD_USE_OCE=ON
    KICAD_USE_OCC=OFF
    KICAD_SPICE=ON
```

Story points: 8.0