Adjust Windows tooltip display time

While most platforms keep the tooltips if the mouse doesn't move, MSW
will hide the tooltip after 5 seconds (by default).  This bumps that up
to 10s for all tooltips in the program.

Fixes https://gitlab.com/kicad/code/kicad/issues/6836
This commit is contained in:
Seth Hillbrand 2021-01-08 10:07:45 -08:00
parent 6ffb72159a
commit c5b6cf722d
1 changed files with 6 additions and 0 deletions

View File

@ -39,6 +39,7 @@
#include <wx/sysopt.h>
#include <wx/richmsgdlg.h>
#include <wx/filedlg.h>
#include <wx/tooltip.h>
#include <build_version.h>
#include <config_params.h>
@ -453,6 +454,11 @@ bool PGM_BASE::InitPgm()
// Need to create a project early for now (it can have an empty path for the moment)
GetSettingsManager().LoadProject( "" );
// TODO: Move tooltips into KIPLATFORM
// This sets the maximum tooltip display duration to 10s (up from 5) but only affects
// Windows as other platforms display tooltips while the mouse is not moving
wxToolTip::SetAutoPop( 1000 );
return true;
}