Fix automation preview, desktop drag highlight and macOS keyboard startup (by Codex)

This commit is contained in:
Codex committed 2026-10-30 23:13:44 +01:00
1 parent 998b037d3d
commit 184a421512
11 files changed
+231 -5

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
// SPDX-License-Identifier: GPL-3.0-only
#include "app/video_session.hpp"
#include <iostream>
int main()try {
SDL_setenv("SDL_VIDEODRIVER","dummy",1);
{ bmh::app::VideoSession video;
if (!(SDL_WasInit(SDL_INIT_VIDEO) & SDL_INIT_VIDEO)) return 1;
// The initial chooser executes inside this scope, not before it.
}
if (SDL_WasInit(SDL_INIT_VIDEO)) return 1;
SDL_setenv("SDL_VIDEODRIVER","unavailable-openbmh-test-driver",1);
bool rejected=false;
try { bmh::app::VideoSession failed; } catch(const std::exception&) { rejected=true; }
if(!rejected || SDL_WasInit(SDL_INIT_VIDEO))return 1;
std::cout<<"Video lifetime initializes before picker and releases on early return\n";
return 0;
}catch(const std::exception& e){std::cerr<<e.what()<<'\n';return 1;}