Posted by
Categories Miyoo Mini Plus, MinUI

International Superstar Soccer running on a SNES emulator within the MinUI launcher.

Having spend just a few hours with MinUI on my Miyoo Mini Plus, I already prefer it over OnionOS (or the stock firmware, for that matter).

What is MinUI?

It’s an alternative, minimalist launcher for the Miyoo Mini Plus (and the RGB30, Trimui Smart (and Pro), Miyoo Mini, M17, and Anbernic RG35XX) that took a lot of inspiration of the Analogue Pocket’s Analogue OS.
Out of the box (the MinUI-20231126b-2-base.zip) it supports Game Boy, Game Boy Color, Game Boy Advance, Nintendo Entertainment System, Super Nintendo Entertainment System, Sega Genesis & PlayStation 1. With the MinUI-20231126b-2-extras.zip there is also support for Neo Geo Pocket (and Color), Pico-8, Pokémon Mini, Sega Game Gear, Sega Master System, Super Game Boy, TurboGrafx-16 (and TurboGrafx-CD) & Virtual Boy.

Make sure to visit the https://github.com/shauninman/MinUI/releases page to download the latest version of the launcher.

If you want some additional tools for MinUI you can get those from https://github.com/westoncampbell/MiyooMini/releases/tag/MiniUI-OnionPAKs. This pack has an audio player, some alternative file browsers, a terminal emulator, a screenshot tool and more.

If you migrate from Onion OS to MinUI, you might have to rename your save files. In my case I had to rename my mGBA saves from .srm to .gba.sav. I don’t know if this is needed for other emulators.

Comments 0

Posted by
Categories Microsoft Windows 10

Some sloppy PowerShell code to get a window back when it’s open, but outside the screen.

Add-Type @"
    using System;
    using System.Runtime.InteropServices;

    // https://msdn.microsoft.com/en-us/library/windows/desktop/dd162897(v=vs.85).aspx
    public struct RECT 
    {
        public long left;
        public long top;
        public long right;
        public long bottom;
    }

    public class User32WinApi 
    {

        // https://msdn.microsoft.com/en-us/library/windows/desktop/ms633505(v=vs.85).aspx
        /*
            Gets the handle of the in-focus window
            NB: In some scenarios this can be NULL; so code needed to handle such an event
        */
        [DllImport("user32.dll")]
        public static extern IntPtr GetForegroundWindow();

        // https://msdn.microsoft.com/en-us/library/windows/desktop/ms633503(v=vs.85).aspx
        /*
            top & left are always 0 (i.e. since the rectangle is relative to the window itself)
            bottom & right equal the windows hieght and width, respectively.
        */
        [DllImport("user32.dll")]
        [return: MarshalAs(UnmanagedType.Bool)]
        public static extern bool GetClientRect(IntPtr hWnd, out RECT lpRect);

        // https://msdn.microsoft.com/en-us/library/windows/desktop/ms633534(v=vs.85).aspx
        [DllImport("user32.dll")]
        [return: MarshalAs(UnmanagedType.Bool)]
        public static extern bool MoveWindow(IntPtr hWnd, int X, int Y, int nWidth, int nHeight, bool bRepaint);

    }

"@
$repaint = $true 
$windowSize = New-Object RECT

"Quick; get the window you're after in focus; you have 5 seconds..."
Start-Sleep -Seconds 5 #allow 5 seconds for the user to get the window they're after in focus (e.g. using ALT+TAB / whatever)
$activeWindow = [User32WinApi]::GetForegroundWindow()
if ($activeWindow) {
    if([User32WinApi]::GetClientRect($activeWindow, [ref]$windowSize)) {
        if ([User32WinApi]::MoveWindow($activeWindow, 0, 0, $windowSize.right, $windowSize.bottom, $repaint)) {
            "Window moved successfully (hope you agree!)"
        } else {
            Write-Warning "Failed to move the active window"
        }
    } else {
        Write-Warning "Failed to get size of the active window"    
    }
} else {
    Write-Warning "No active window found"    
}
Comments 0