Merge glass-per-display-windows: per-display cockpit windows (Cyd, BT_GLASS_PANELS)
One window per pod display (Heat/Engineering/Comm/Weapons x2/radar + Flight Controls), each carrying its surface with its RIO button bank arranged pod-faithfully; CPU-expanded surfaces, buttons under the imagery. Runtime gate BT_GLASS_PANELS (=0 = the legacy single panel). Merged on top of today's landed fix pile (audio-crash, experience, parallax); the L4PADRIO overlap with the gait-detent commit resolved preserving BOTH (his window refactor + our at-rest band snap). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> # Conflicts: # context/glass-cockpit.md
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
|
||||
#include "l4padrio.h"
|
||||
#include "l4padpanel.h"
|
||||
#include "l4glasswin.h"
|
||||
#include "l4ctrl.h"
|
||||
|
||||
#include <windows.h>
|
||||
@@ -168,10 +169,16 @@ PadRIO::PadRIO():
|
||||
<< "live on focus; L4PADFLIP=" << flipStickAxes << ")\n" << std::flush;
|
||||
|
||||
//
|
||||
// The on-screen cockpit button panel (step 2d) rides the device: the
|
||||
// glass preset sets BT_PAD_PANEL=1.
|
||||
// The on-screen cockpit buttons ride the device. BT_GLASS_PANELS (the
|
||||
// glass preset default) breaks each secondary display into its own window
|
||||
// with its RIO bank around it; otherwise the single combined pad panel
|
||||
// (BT_PAD_PANEL=1) is used.
|
||||
//
|
||||
if (getenv("BT_PAD_PANEL") != NULL && *getenv("BT_PAD_PANEL") != '0')
|
||||
if (BTGlassPanelsActive())
|
||||
{
|
||||
BTGlassPanels_Create();
|
||||
}
|
||||
else if (getenv("BT_PAD_PANEL") != NULL && *getenv("BT_PAD_PANEL") != '0')
|
||||
{
|
||||
BTPadPanel_Create();
|
||||
}
|
||||
@@ -179,6 +186,7 @@ PadRIO::PadRIO():
|
||||
|
||||
PadRIO::~PadRIO()
|
||||
{
|
||||
BTGlassPanels_Destroy(); // safe no-op if the glass windows were never created
|
||||
BTPadPanel_Destroy();
|
||||
if (activeInstance == this)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user