Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ English (US) release notes, mirroring CHANGELOG.md (Brazilian Portuguese). Befor
- **Per-game profiles**: each Steam game can have its own resolution, HDR, FPS limit and audio output. With the game running, open the session menu and pick **Game profile → Save the current settings**; next time it starts in console mode, the profile is applied by itself and undone when the game closes. Also works for Steam games opened from Playnite or the Xbox app. Profiles are listed in Settings → **Per-game profiles**, where you can delete them. (#170)
- **Browser (JoyChromium)** in the session menu, pinned right under ControlFS and working the same way: [JoyChromium](https://github.com/lippdev/joychromium) (the TV browser you drive with the controller) opens full screen over the game and, if it isn't installed, the first press downloads its newest release, checks its SHA-256 and installs it. Going back to the PC while it's open takes it out of full screen and leaves it as a window, tabs and all. (#175, #181)
- **Move the mouse pointer out of the way** (issue #172): when the launcher shows up on the TV, the pointer goes to the bottom-right corner of the game screen (twice, since Steam recenters it while opening) and goes back where it was when you return to the PC. On by default; turn it off in Settings or under System → When entering console mode. Based on @JarJarShinks' version in #173. (#177)
- Redesigned title bar: on the Console interface the background runs up to the top edge of the window (no grey strip) and the minimize, maximize and close buttons are white, with the same soft highlight as the interface's own buttons; on the Desktop interface the icon and name are larger and the buttons fill the bar's height. (#182)

### Fixes
- Custom app: Console Mode moves only the program's largest window to the game screen, instead of every window Windows reports as its main one; a tooltip is no longer stretched over the TV. (#175)
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Notas em português do Brasil; a versão em inglês (Estados Unidos) fica em `CH
- **Perfis por jogo**: cada jogo da Steam pode ter sua própria resolução, HDR, limite de FPS e saída de áudio. Com o jogo rodando, abra o menu da sessão e escolha **Perfil do jogo → Salvar os ajustes atuais**; da próxima vez que ele abrir no modo console, o perfil é aplicado sozinho e desfeito quando o jogo fecha. Vale também para jogos da Steam abertos pelo Playnite ou pelo app Xbox. Os perfis ficam em Ajustes → **Perfis por jogo**, onde dá para apagá-los. (#170)
- **Navegador (JoyChromium)** no menu da sessão, fixo logo abaixo do ControlFS e funcionando do mesmo jeito: o [JoyChromium](https://github.com/lippdev/joychromium) (o navegador para a TV que se usa com o controle) abre em tela cheia por cima do jogo e, se não estiver instalado, o primeiro clique baixa a versão mais recente, confere o SHA-256 e instala. Voltar ao PC com ele aberto o tira da tela cheia e o deixa como janela, sem perder as abas. (#175, #181)
- **Tirar o ponteiro do mouse do caminho** (issue #172): quando o iniciador aparece na TV, o ponteiro vai para o canto inferior direito da tela de jogo (duas vezes, porque a Steam o recentraliza ao abrir) e, ao voltar ao PC, volta para onde estava. Ligado por padrão; desligue em Ajustes ou em Sistema → Ao entrar no modo console. Baseado na versão de @JarJarShinks no #173. (#177)
- Barra de título redesenhada: na interface Console, o fundo vai até a borda de cima da janela (sem a faixa cinza) e os botões de minimizar, maximizar e fechar ficam brancos, com o mesmo realce suave dos botões da interface; na interface Desktop, o ícone e o nome ficam maiores e os botões ocupam a altura toda da barra. (#182)

### Correções
- Aplicativo personalizado: o Console Mode leva para a tela de jogo só a maior janela do programa, em vez de todas as que o Windows aponta como principal; uma dica de ferramenta não é mais esticada sobre a TV. (#175)
Expand Down
7 changes: 7 additions & 0 deletions docs/TESTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -619,3 +619,10 @@ Pré-condições: a opção **Tirar o ponteiro do mouse do caminho** ligada (é
- [ ] Controle que fazia o menu "subir sozinho": o menu fica parado; se o log mostrar `analógico fora do centro desde o início`, o direcional e os botões continuam navegando. Anote o modelo do controle. Resultado: ______
- [ ] Controle normal: o analógico navega como antes (na primeira leitura ele está no centro). Resultado: ______
- [ ] Aba Sessão em espanhol, francês e russo: as legendas dos ajustes rápidos aparecem inteiras, em até duas linhas. Resultado: ______

## Barra de título (#182)

- [ ] Interface Console: nenhuma faixa cinza no topo; o fundo (Aurora, capas ou imagem) vai até a borda da janela, e minimizar, maximizar e fechar aparecem brancos, com realce suave ao passar o mouse e mais forte ao clicar. Resultado: ______
- [ ] Interface Console: arrastar a janela pela área de cima (fora das abas e dos botões) funciona; as abas, o relógio e os botões redondos continuam clicáveis. Resultado: ______
- [ ] Interface Desktop: ícone e "Console Mode" à esquerda, botões de janela altos; em Ajustes, o botão de voltar aparece e funciona. Tema claro e escuro do Windows: os botões seguem o tema. Resultado: ______
- [ ] Trocar entre Desktop e Console (botão ou Y): a barra muda junto, sem sobrar faixa nem botões brancos no tema claro. Resultado: ______
53 changes: 30 additions & 23 deletions src/ConsoleMode/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,41 +12,48 @@
<RowDefinition Height="*"/>
</Grid.RowDefinitions>

<!-- Title bar: the back button sits outside the drag region so it stays clickable. -->
<!-- The pages take the whole window: the console interface paints its background under the title bar (it leaves
the top 48 px free itself), so there is no separate strip above it; the desktop pages start below the bar. -->
<Grid Grid.RowSpan="2">
<views:ConsoleHomeView Visibility="{x:Bind ViewModel.IsConsoleUi, Mode=OneWay}"/>
<Grid Margin="0,48,0,0">
<views:HomeView Visibility="{x:Bind ViewModel.IsDesktopHome, Mode=OneWay}">
<views:HomeView.Transitions>
<TransitionCollection>
<EntranceThemeTransition FromHorizontalOffset="-24" FromVerticalOffset="0"/>
</TransitionCollection>
</views:HomeView.Transitions>
</views:HomeView>
<views:SettingsView Visibility="{x:Bind ViewModel.IsDesktopSettings, Mode=OneWay}">
<views:SettingsView.Transitions>
<TransitionCollection>
<EntranceThemeTransition FromHorizontalOffset="24" FromVerticalOffset="0"/>
</TransitionCollection>
</views:SettingsView.Transitions>
</views:SettingsView>
</Grid>
</Grid>

<!-- Title bar, drawn over the pages: the back button sits outside the drag region so it stays clickable.
The app's name shows on the desktop interface only; the console one has its own brand mark in its top bar. -->
<Grid Grid.Row="0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button Style="{StaticResource NavigationBackButtonNormalStyle}" Margin="4,0,0,0"
<Button Style="{StaticResource NavigationBackButtonNormalStyle}" Margin="6,0,0,0"
VerticalAlignment="Center" Width="40" Height="36"
Visibility="{x:Bind ViewModel.IsDesktopSettings, Mode=OneWay}"
Command="{x:Bind ViewModel.GoHomeCommand}"
ToolTipService.ToolTip="{x:Bind ViewModel.Texts.Back, Mode=OneWay}" AutomationProperties.Name="{x:Bind ViewModel.Texts.Back, Mode=OneWay}"/>
<Grid x:Name="AppTitleBar" Grid.Column="1" Background="Transparent">
<StackPanel Orientation="Horizontal" Spacing="12" Margin="12,0,0,0" VerticalAlignment="Center">
<Image x:Name="TitleIcon" Width="16" Height="16"/>
<TextBlock Text="{x:Bind ViewModel.Texts.Brand, Mode=OneWay}" Style="{StaticResource CaptionTextBlockStyle}" VerticalAlignment="Center"/>
<StackPanel Orientation="Horizontal" Spacing="10" Margin="14,0,0,0" VerticalAlignment="Center"
Visibility="{x:Bind ViewModel.IsDesktopUi, Mode=OneWay}">
<Image x:Name="TitleIcon" Width="20" Height="20"/>
<TextBlock Text="{x:Bind ViewModel.Texts.Brand, Mode=OneWay}" FontSize="13" FontWeight="SemiBold"
Foreground="{ThemeResource TextFillColorSecondaryBrush}" VerticalAlignment="Center"/>
</StackPanel>
</Grid>
</Grid>

<Grid Grid.Row="1">
<views:ConsoleHomeView Visibility="{x:Bind ViewModel.IsConsoleUi, Mode=OneWay}"/>
<views:HomeView Visibility="{x:Bind ViewModel.IsDesktopHome, Mode=OneWay}">
<views:HomeView.Transitions>
<TransitionCollection>
<EntranceThemeTransition FromHorizontalOffset="-24" FromVerticalOffset="0"/>
</TransitionCollection>
</views:HomeView.Transitions>
</views:HomeView>
<views:SettingsView Visibility="{x:Bind ViewModel.IsDesktopSettings, Mode=OneWay}">
<views:SettingsView.Transitions>
<TransitionCollection>
<EntranceThemeTransition FromHorizontalOffset="24" FromVerticalOffset="0"/>
</TransitionCollection>
</views:SettingsView.Transitions>
</views:SettingsView>
</Grid>
</Grid>
</Window>
19 changes: 19 additions & 0 deletions src/ConsoleMode/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ public MainWindow(MainViewModel viewModel)
appWindow.Resize(new Windows.Graphics.SizeInt32((int)(960 * scale), (int)(760 * scale)));
appWindow.TitleBar.ButtonBackgroundColor = Colors.Transparent;
appWindow.TitleBar.ButtonInactiveBackgroundColor = Colors.Transparent;
// Tall caption buttons: as high as the 48 px bar, instead of 32 px ones floating at the top.
appWindow.TitleBar.PreferredHeightOption = TitleBarHeightOption.Tall;
StyleCaptionButtons(appWindow.TitleBar, ViewModel.IsConsoleUi);

if (File.Exists(AppPaths.IconPath))
{
Expand Down Expand Up @@ -59,6 +62,7 @@ public MainWindow(MainViewModel viewModel)
// The console interface fills the screen, like a console; the desktop one gets its size back.
ViewModel.PropertyChanged += (_, e) =>
{
if (e.PropertyName == nameof(MainViewModel.IsConsoleUi)) StyleCaptionButtons(appWindow.TitleBar, ViewModel.IsConsoleUi);
if (e.PropertyName == nameof(MainViewModel.IsConsoleUi) && appWindow.Presenter is OverlappedPresenter p)
{
if (ViewModel.IsConsoleUi) p.Maximize();
Expand All @@ -70,6 +74,21 @@ public MainWindow(MainViewModel viewModel)
WatchDesktopPad(hwnd);
}

/// <summary>
/// Minimize, maximize and close over the console interface's dark background: white, with the same soft veil on hover
/// and press as its own buttons. The desktop interface keeps Windows' colours for its theme.
/// </summary>
private static void StyleCaptionButtons(AppWindowTitleBar bar, bool console)
{
Windows.UI.Color? Argb(byte a, byte r, byte g, byte b) => console ? Windows.UI.Color.FromArgb(a, r, g, b) : null;
bar.ButtonForegroundColor = Argb(0xFF, 0xFF, 0xFF, 0xFF);
bar.ButtonInactiveForegroundColor = Argb(0x80, 0xFF, 0xFF, 0xFF);
bar.ButtonHoverForegroundColor = Argb(0xFF, 0xFF, 0xFF, 0xFF);
bar.ButtonHoverBackgroundColor = Argb(0x1F, 0xFF, 0xFF, 0xFF);
bar.ButtonPressedForegroundColor = Argb(0xFF, 0xFF, 0xFF, 0xFF);
bar.ButtonPressedBackgroundColor = Argb(0x33, 0xFF, 0xFF, 0xFF);
}

// The desktop interface, driven by the pad like a console menu (ported from PR #17):
// D-pad/stick move, A activates (lists, toggles, cards), B closes a list or leaves Settings,
// Start toggles Settings, Y jumps to the console interface, tour: A next / B skip.
Expand Down
3 changes: 3 additions & 0 deletions src/ConsoleMode/ViewModels/MainViewModel.ConsoleUi.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
public ObservableCollection<ComboOption> ControllerLayoutOptions { get; } = [];

[ObservableProperty] private bool _isConsoleUi;
[ObservableProperty] private ComboOption? _selectedUiMode;

Check warning on line 17 in src/ConsoleMode/ViewModels/MainViewModel.ConsoleUi.cs

View workflow job for this annotation

GitHub Actions / Build and test

The field ConsoleMode.ViewModels.MainViewModel._selectedUiMode using
[ObservableProperty] private bool _isRolePanelOpen;
[ObservableProperty] private MonitorRowViewModel? _rolePanelMonitor;
[ObservableProperty] private bool _isPlayStationHints;
Expand All @@ -26,6 +26,8 @@

public bool IsDesktopHome => !IsConsoleUi && IsHomePage;
public bool IsDesktopSettings => !IsConsoleUi && IsSettingsPage;
/// <summary>The desktop interface: the title bar shows the app's name there (the console one has its own brand mark).</summary>
public bool IsDesktopUi => !IsConsoleUi;
public string FocusScreenName => FocusRow?.Name ?? "";
public string RolePanelTitle => LocalizationService.Get("ChooseRoleFor", RolePanelMonitor?.Name ?? "");
public string HdrText => LocalizationService.Get(HdrEnable ? "ToggleOn" : "ToggleOff");
Expand All @@ -47,6 +49,7 @@
partial void OnIsConsoleUiChanged(bool value)
{
OnPropertyChanged(nameof(IsDesktopHome));
OnPropertyChanged(nameof(IsDesktopUi));
OnPropertyChanged(nameof(IsDesktopSettings));
OnPropertyChanged(nameof(IsTourMap));
OnPropertyChanged(nameof(IsTourRole));
Expand Down
7 changes: 4 additions & 3 deletions src/ConsoleMode/Views/ConsoleHomeView.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@
<ScalarTransition x:Key="ConsoleFade" Duration="0:0:0.18"/>
</UserControl.Resources>

<!-- 10-foot layout: big cards, thick focus ring, no mouse needed. Solid background instead of Mica. -->
<Grid x:Name="Root" Background="#07090D" Padding="56,0,56,32">
<!-- 10-foot layout: big cards, thick focus ring, no mouse needed. Solid background instead of Mica. The view also
fills the title bar (the top padding leaves its 48 px free), so the background runs up to the window edge. -->
<Grid x:Name="Root" Background="#07090D" Padding="56,48,56,32">
<Grid.Resources>
<!-- Containers of cards are not focus stops: the focus lands on the cards themselves. -->
<Style TargetType="ItemsControl">
Expand All @@ -43,7 +44,7 @@
</Grid.Resources>

<!-- Background: the built-in wallpaper, covers of your installed Steam games or your picture, under a solid-colour gradient -->
<Grid x:Name="BackgroundLayer" IsHitTestVisible="False" Margin="-56,0,-56,-32">
<Grid x:Name="BackgroundLayer" IsHitTestVisible="False" Margin="-56,-48,-56,-32">
<!-- Built-in wallpaper ("Aurora"): soft green and blue glows over a deep blue-black with a few faint
orbit lines, all on the right, where the gradients below leave the art visible -->
<Grid Visibility="{x:Bind ViewModel.ShowBackgroundWallpaper, Mode=OneWay}">
Expand Down
Loading