screentinker/tizen/config.xml
ScreenTinker e2ff8f47b7 Tizen player: real Samsung B2B fleet control (#125), folding in #126
#123 already shipped a placeholder device:command handler (#121/#122): screen_off
was a black overlay, reboot/shutdown a toast, update a "re-install" toast. This
replaces that with the real control surface from #125, reconciled into the single
handler #123 introduced (rather than landing a second, competing handler).

- NEW tizen/js/device-control.js: window.STDeviceControl = { run, capabilities,
  backend }. Feature-detects webapis.systemcontrol.* (Tizen 6.5/7, sync/throws) then
  b2bapis.b2bcontrol.* (SSSP/Tizen 4, async), normalises both to Promises, re-probes
  each call. run() never rejects; resolves { ok, supported, action, note, reload }.
  Panel power: setPanelMute (mute ON = backlight OFF) -> setDisplayPanel/setPanelStatus
  fallback. reboot -> rebootDevice(); shutdown mutes the panel and notes SSSP has no
  true power-off; update/reload -> reload:true.
- tizen/js/app.js: device:command now calls STDeviceControl.run and reports the
  outcome via reportCmd (device:log tag=command -> dashboard:device-log, plus a
  structured device:command-result), reloading ~1.2s later on result.reload. screen_off
  falls back to the existing black overlay (showScreenOff) when no B2B surface exists;
  screen_on/launch still clear the overlay + keepAwake. Dropped the now-dead
  tryPowerControl. reportCapabilities() runs on device:registered so the dashboard sees
  the backend ("none" on web/URL-Launcher/consumer TV).
- tizen/config.xml: partner-level b2bcontrol + systemcontrol privileges (ignored, not
  fatal, on unsigned/URL-Launcher/web/consumer builds).
- tizen/index.html: load $WEBAPIS/webapis.js + $B2BAPIS/b2bapis.js before the app
  scripts (404 harmlessly off-hardware) and device-control.js before app.js.
- tizen/README.md: rewrote the remote-control table for real B2B control + a
  partner-signing caveat; added device-control.js to the file list.

Supersedes PR #126 (feat/tizen-device-command-125), which targeted main unaware that
this branch already had a device:command handler.

Verified: node --check on both JS files; config.xml well-formed (xmllint). Not yet
validated on a real SSSP panel — the control surface only takes effect on a
partner-signed .wgt (backend reports "none" on the dev/URL-Launcher build).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 13:28:08 -05:00

37 lines
2 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns="http://www.w3.org/ns/widgets" xmlns:tizen="http://tizen.org/ns/widgets"
id="http://screentinker.com/player" version="1.9.1" viewmodes="maximized">
<tizen:application id="ScrnTinkr1.ScreenTinker" package="ScrnTinkr1" required_version="2.4"/>
<tizen:profile name="tv"/>
<name>ScreenTinker</name>
<author email="support@screentinker.net">ScreenTinker</author>
<description>ScreenTinker digital signage player</description>
<icon src="icon.png"/>
<content src="index.html"/>
<!-- Landscape signage, no context menu, allow background, keep app full-screen -->
<tizen:setting screen-orientation="landscape" context-menu="disable"
background-support="enable" encryption="disable"
install-location="auto" hwkey-event="enable"/>
<feature name="http://tizen.org/feature/screen.size.all"/>
<!-- Allow the player to reach any signage server + load remote media / YouTube -->
<access origin="*" subdomains="true"/>
<tizen:allow-navigation>*</tizen:allow-navigation>
<tizen:privilege name="http://tizen.org/privilege/internet"/>
<tizen:privilege name="http://tizen.org/privilege/application.launch"/>
<tizen:privilege name="http://tizen.org/privilege/display"/>
<tizen:privilege name="http://developer.samsung.com/privilege/network.public"/>
<!-- #125: Samsung B2B fleet control (reboot / panel power via b2bcontrol /
systemcontrol). These are PARTNER-level privileges: they only take effect
when the .wgt is signed with a Samsung Partner distributor certificate on a
real SSSP panel. On unsigned / URL-Launcher / web / consumer-TV builds they
are ignored (not fatal) — the APIs are simply absent and device-control.js
reports "unsupported". -->
<tizen:privilege name="http://developer.samsung.com/privilege/b2bcontrol"/>
<tizen:privilege name="http://developer.samsung.com/privilege/systemcontrol"/>
</widget>