Disable flight-related key-bindings in the WaypointList widget for 2.4 release, pending a better solution to PLIB's lack of focus.
This commit is contained in:
parent
529ce6b26e
commit
8e682cb8a4
1 changed files with 9 additions and 0 deletions
|
@ -21,6 +21,11 @@
|
||||||
#include <Navaids/positioned.hxx>
|
#include <Navaids/positioned.hxx>
|
||||||
#include <Autopilot/route_mgr.hxx>
|
#include <Autopilot/route_mgr.hxx>
|
||||||
|
|
||||||
|
// select if the widget grabs keys necessary to fly aircraft from the keyboard,
|
||||||
|
// or not. See http://code.google.com/p/flightgear-bugs/issues/detail?id=338
|
||||||
|
// for discussion about why / what is going on.
|
||||||
|
#define AVOID_FLIGHT_KEYS 1
|
||||||
|
|
||||||
using namespace flightgear;
|
using namespace flightgear;
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
|
@ -659,6 +664,10 @@ int WaypointList::checkKey (int key, int updown )
|
||||||
if ((updown == PU_UP) || !isVisible () || !isActive () || (window != puGetWindow())) {
|
if ((updown == PU_UP) || !isVisible () || !isActive () || (window != puGetWindow())) {
|
||||||
return FALSE ;
|
return FALSE ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef AVOID_FLIGHT_KEYS
|
||||||
|
return FALSE;
|
||||||
|
#endif
|
||||||
|
|
||||||
switch (key)
|
switch (key)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue