curt [Tue, 5 Jun 2001 22:12:28 +0000 (22:12 +0000)]
- replace FGBFI::update with fgUpdateProps
- switched to properties for calculating RPM for model selector
- no longer includes bfi.hxx
- no longer includes keyboard.hxx
curt [Tue, 5 Jun 2001 22:11:16 +0000 (22:11 +0000)]
- moved shift-F1 and shift-F2 (load/save) bindings to XML
- moved shift-F3 (reload panel) bindings to XML
- moved shift-F4 (reload prefs) bindings to XML
- moved shift-F5, shift-F6, shift-F7, and shift-F8 (scroll panel) to
XML
- no longer includes Main/bfi.hxx
- added implementations of GLUTkey, GLUTkeyup, GLUTspecialkey, and
GLUTspecialkeyup
curt [Mon, 4 Jun 2001 21:15:23 +0000 (21:15 +0000)]
- make repeatable for keys and joystick buttons default to false
rather than true; it's too confusing for users if keys and buttons
repeat by default (keys weren't anyway, but they were supposed to)
curt [Mon, 4 Jun 2001 21:08:06 +0000 (21:08 +0000)]
- no longer include Joystick/joystick.hxx
- include Input/input.hxx
- register GLUTkeyup and GLUTspecialkeyup with glut
- comment out call to fgJoystickRead
- comment out call to fgJoystickInit
- add call to FGInput::update to replace fgJoystickRead
curt [Mon, 4 Jun 2001 21:07:02 +0000 (21:07 +0000)]
- added FG_MOD_UP to use key-up or button-up as a command modifier;
this way, keyboard buttons can work the same way as joystick buttons
- added declaration for FGBinding::fire(double); this adds a setting
property to the arguments passed to the command, so that it can use
the current axis position as part of its calculations
- added data structures from joystick.cxx
curt [Mon, 4 Jun 2001 21:06:48 +0000 (21:06 +0000)]
- added FGBinding::fire(double) - added support for "mod-up" property
- go back to using index as key code (otherwise, we'll get nasty
surprises when users try to override bindings)
- XML config file now nests bindings inside modifiers
- allow user to specify whether key is repeatable
- removed hard-coded bindings for 'b', ',', and '.'
- added code from joystick.cxx, with the following major changes:
- changed from js0, axis0, button0 to js[0], axis[0], button[0], etc.
- removed factor, offset, etc. since they will be args to command in
binding
- allow multiple bindings, as with key mappings
- allow access to keyboard modifier keys for bindings
- include infrastructure for modifiers (only FG_MOD_UP is used so far)
- removed unused 'saturation' property
- temporarily removed capture property and trim code; it will have to
be rewritten to be more generic
- allow modifiers for joystick buttons
curt [Fri, 1 Jun 2001 17:51:09 +0000 (17:51 +0000)]
- refactored and simplified FGBinding class to use the new command
manager; removed unused getters and setters; track original
command name for use in debugging messages
- removed unused action methods from FGInput
curt [Fri, 1 Jun 2001 17:50:59 +0000 (17:50 +0000)]
- renamed property binding/action to binding/command; most commands now
want binding/property rather than binding/control
- removed hard-coded bindings for F3 (screenshot), Ctrl-S
(autothrottle), v (cycle view) and all of the keypad view-direction
keys; these are now defined in $FG_ROOT/keyboard.xml
- removed unused action method
curt [Wed, 30 May 2001 18:21:03 +0000 (18:21 +0000)]
Fixed a bug in the tile pager / caching / management system that caused
a crash when relocating to a new airport. Pending work from the old
area is now just completed as normal, rather than trying to empty the various
queues in their various stages when can lead to many problems in a threaded
environment.
curt [Tue, 29 May 2001 22:31:04 +0000 (22:31 +0000)]
1. Fixed FGInput bug preventing same key from being bound separately
with different modifiers (the format of the key bindings has changed
again slightly, adding a <code>..</code> element; see keyboard.xml for
details).
2. Modified FGInput to try default modifiers for ctrl, shift, and alt
when the initial bindings fail (i.e. you don't have to specify
mod-shift explicitly for upper-case 'P' any more).
3. Fixed problems with properties and panel reloading reported by
Martin Dressler and John Check.
4. Updated preferences.xml to get rid of obsolete references to
/controls/brakes/left and /controls/brakes/right (as reported by John
Check).
There were also two non-bugs reported by John Check:
(a) Differential braking doesn't work (John was using the obsolete
properties from #4 above).
(b) Duplicates show up in the property tree using the telnet interface
(the property tree doesn't show indices, and John was seeing separate
entries for each possible engine, etc.).
curt [Tue, 29 May 2001 22:06:14 +0000 (22:06 +0000)]
Win32 fixes.
Fixed a few glitches in the autopilot keys
Added a #define to be able to make a compile time decision to revert to
older GPS like autopiolt behavior this define SHOULD become a property
so that it is run time switchable.
curt [Wed, 23 May 2001 23:01:15 +0000 (23:01 +0000)]
I'm attaching diffs to add a new FGInput module to FlightGear
(src/Input). So far, FGInput replaces most of src/Main/keyboard.cxx
(I've left a tiny stub); in the very near future, it will also take
over control of the joystick, mouse (Norm permitting), and panel
instrument interactions, so that there is a single mechanism for
configuring all input devices.
The new format should be (close to) self-explanatory by looking at the
new base-package file keyboard.xml, which is now included by
preferences.xml (I'll do the same thing for the joystick when I have a
chance). I have not managed to move all keybindings into this file
yet, but I've made a good start. I'm including Tony in the recipient
list so that he can see how bindings can use an external XML file.
This patch also adds support for multiple bindings for a single key,
special keys (i.e. keypad and function keys), and key modifiers
(shift/alt/ctrl); special keys use the PUI convention of adding 256 to
the Glut key code.
Unfortunately, everything comes with a price; in this case, I have not
yet found a general mechanism for the old (hard-coded) modal bindings,
which behaved differently depending on the autopilot state (i.e. left
rudder or move AP heading left); with my patches, this functionality
disappears, but you can still adjust the autopilot using the panel or
the GUI input dialogs.
curt [Sun, 20 May 2001 06:49:06 +0000 (06:49 +0000)]
We can't remove ssg branches in the threaded tile page because if we happen
to have attached an ssg loaded object to this branch, then plib will remove
it and all it's states (and textures) which will call opengl api commands
which will crash the program if run from a separate thread from the main render
thread.