Engineers working in Android VoIP development or building custom dialers inevitably encounter a severe fragmentation issue on Xiaomi, Redmi, and Poco devices. You declare the standard SYSTEM_ALERT_WINDOW permission, request it via standard APIs, and verify it using Settings.canDrawOverlays(context) . The API returns true , yet when a VoIP call comes in while the app is backgrounded, the custom call screen fails to appear. This silent failure occurs because MIUI implements a secondary, hidden permission overlay strictly for background execution: the "Display pop-up windows while running in the background" permission. This article details the root cause of this undocumented restriction and provides a production-ready Java implementation to detect and resolve it. The Root Cause: MIUI's AppOps Customization In stock Android, the system alert window acts as a global capability flag. If the user grants the Android overlay permission via ACTION_MANAGE_O...
Practical programming blog with step-by-step tutorials, production-ready code, performance and security tips, and API/AI integration guides. Coverage: Next.js, React, Angular, Node.js, Python, Java, .NET, SQL/NoSQL, GraphQL, Docker, Kubernetes, CI/CD, cloud (Amazon AWS, Microsoft Azure, Google Cloud) and AI APIs (OpenAI, ChatGPT, Anthropic, Claude, DeepSeek, Google Gemini, Qwen AI, Perplexity AI. Grok AI, Meta AI). Fast, high-value solutions for developers.