Skip to content

Instantly share code, notes, and snippets.

@yosh1
Created October 8, 2018 04:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yosh1/d74da63267e17c71063c2754c0081863 to your computer and use it in GitHub Desktop.
Save yosh1/d74da63267e17c71063c2754c0081863 to your computer and use it in GitHub Desktop.
QRコードやバーコードを表示するときに画面の明るさを最大にする ref: https://qiita.com/yoshi1125hisa/items/de6e09bdfec1dafccec6
WindowManager.LayoutParams layoutParams = getWindow().getAttributes();
layoutParams.screenBrightness = WindowManager.LayoutParams.BRIGHTNESS_OVERRIDE_FULL;
getWindow().setAttributes(layoutParams);
UIScreen.mainScreen().brightness = 1.0f
[[UIScreen mainScreen] setBrightness:1.0f];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment