How to disable pop-up / preview (heads up) message notifications for Samsung Galaxy S7, S8 and S8+

To disable heads-up notifications, install Android SDK and issue the following command in command line (all in one line): adb shell settings put global heads_up_notifications_enabled 0 To simply view current settings before or after changes, use: adb shell settings get global heads_up_notifications_enabled More ways on how to disable these settings (if not available via user […]

String.format in Java has weird rounding by default

I was participating in one of our Android projects, and while testing I discovered, that our program acted weird — app displayed one value, but acted like the value was different. The value was 1.45, and our Java Android app displayed 1.4 instead of 1.5. The source looked something like: double d = 1.45; String […]