Mobile devices have virtual keyboards. There is only limited space on the display to show the keyboard, so it will be helpful to the user to see only the needed keys. Using the right input type will dramatically improve the mobile experience. There are many different input types available for html pages. Here are my ..
Category : Uncategorized
Yes, it is possible to disable the text selection with a simple line of CSS. The user-select property is a new CSS3 property. Using user-select enables web and app developers to control the ability to select text. Most browsers (With CSS3 support), can do this by using variations on the CSS3 user-select property. The user-select ..
There are two parts of the version in AndroidManifest.xml. android:versionCode android:versionName In your AndroidManifest.xml the versionCode is a number, and every version you want to submit to google play needs to have a higher number then the last. VersionName is just a string, and can be anything you want it to be. In VersionName you ..
There is a easy solution to remove all uncommitted changes from your working directory in GIT git fetch origin git reset –hard origin/master Note: After executing this command, all uncommitted changes will be removes from your working directory. If you want to save the current work before removing all uncommitted changes, you can do: git ..
In Java there is a easy was to capture screenshots. The following captureScreenshot method will capture a screenshot of the display of your screen and save it to the disk. public void captureScreenshot(String filename) throws Exception { java.awt.Dimension size = java.awt.Toolkit.getDefaultToolkit().getScreenSize(); java.awt.Rectangle rectangle = new java.awt.Rectangle(size); java.awt.Robot robot = new java.awt.Robot(); java.awt.image.BufferedImage image = robot.createScreenCapture(rectangle); ..
There is a simple solution, to get the name of the current method in Java. It uses the stack trace to get the name of the mehod. It works with different virtual machines like oracle, dalvik (Android), Open JDK, etc. String name = Thread.currentThread().getStackTrace()[1].getMethodName(); But don’t use this in time-critical code, because working with the ..
To generate random readable passwords you can combine words, letters and special chars. The words can come from a wordlist array. For example you can use the list of the 10,000 most common English words in order of frequency, as determined by n-gram frequency analysis of the Google’s Trillion Word Corpus. In the exmaple the ..
This is a simple Android background Service Template. You can use it to run updates in the background without blocking the UI. To start and stop the service use the following lines in your activity: // starting the service Intent intent = new Intent(this, UpdateService .class); startService(intent); // stopping the service Intent intent = new ..
For the IoT you can use a cheap esp8266 microcontroller with WiFi onboard. To connect the esp8266 to the wireless network you can use the following lua snippet that will work with the nodemcu..
To get the first 10 in descending order in sqlite SELECT * FROM table ORDER BY id DESC LIMIT 10 To get the first 10 in ascending order in sqlite SELECT * FROM table ORDER BY id ASC LIMIT 10 Note: If there are less than 10 entrys in the sqlite database, you will get ..