Showing posts with label better. Show all posts
Showing posts with label better. Show all posts

Monday, February 6, 2017

Four ways smartphones are changing the world for the better

Four ways smartphones are changing the world for the better


smartphone-570513_960_720

Facebook in 2004. YouTube in 2005. Twitter in 2006. iPhone in 2007. Android in 2008. The launch of these landmark products has changed our lives dramatically over the last decade. We didnt know it at the time, but these were milestones on the road to a new world. They were some of the key moments of the mobile revolution.

Not all changes brought by the mobile revolution have been positive. In fact, for certain groups of people from around the world, the explosion of mobile has brought misery and exploitation. We touch on this dark side of our mobile addiction here. But on a global scale, the mobile age has unlocked great benefits for all of us. In this post well be looking at some of the ways smartphones have changed our world for the better.

Word spreads around the globe

One of the most significant improvements the mobile revolution has brought about is the speed at which information spreads from one part of the globe to another. It doesnt matter if the content is to our liking or not. The visionaries who foresaw that people would like to own a small handheld device (i.e. the smartphone) that can connect them to millions of their peers over the internet were proven absolutely right!

Mass-media companies like BBC, CNN, Reuters, The Independent or The New York Times quickly recognized this potential and established official presences on Facebook or Twitter and other platforms, using them to broadcast breaking news around the clock.

It goes deeper than that. Thanks to the internet and our feature-packed smartphones, we can not only consume and interact with incoming news, we can also be the first ones to communicate things to the rest of the world if we happen to be at the right place, at the right time. And were doing this over devices that just two decades ago wouldve looked at home in sci-fi flicks. 

Events in one country now have almost instant implications for the rest of the world. With steady improvements in network speeds and hardware, were more connected than ever. Remember the so-called Arab Spring (regardless of the eventual outcomes of the events): how social opposition movements spread out like wildfire; how people were inspired by citizens of other countries to demand similar liberties for themselves; and how people organized on social media to attend rallies and protests.

2011_Egyptian_protests_Facebook_&_jan25_card

Although my personal experience with Periscope has been fairly disappointing (despite shooting from a phone with 4K camera and OIS over high-speed LTE), apps like it allow people to stand up as individual journalists and broadcast incidents live as they happen. We see footage shot with smartphones in mass-media almost every day now.

For marginalized groups, taking to social media has become an effective way to appeal to the general public. This can backfire, as inevitably, our online presence makes the internet a domain of interest for governments. Thus, we have a struggle between opposing forces – on one side people demanding equality, privacy and liberties; on the other, authorities who want to control and regulate. Aaron Swartz, the late internet activist, once said, "It is not, you know, only certain people have licence to speak, now everyone has a licence to speak. Its a question of who gets heard".

In my opinion, we are living through a transition period triggered by a dramatic change in mobile networks in the last decade and personal experience tell me that transition periods could be painful. But sooner or later things will stabilize and everyday liberties enjoyed by leading Western countries will spread out throughout the world. Surely, the mobile networks are speeding up this process.

Abolishing boundaries

I have been searching for an informative graph showing how the average number of countries people visited changed in the last 300 years or so. Unfortunately I didnt come across a good figure. We can intuitively say that the number is continuously increasing as travelling is becoming safer and cheaper.

I cannot express how living in other countries, communicating with people from other cultures can broaden ones life perspective. By 30, I have spent much more time abroad than my whole family combined, and I think that the time we spend abroad will continue to increase for future generations. The mobile revolution is one of the key reasons why this is the case.

As someone who was living in Japan with a very elementary level of Japanese speaking ability, it amazes me how people survived before Google Maps, Translate, and many others apps that make traveling so much easier today. From one perspective, the dependence on mobile technology is pathetic (I would have preferred if I had enough time to learn Japanese), but on the other hand it surely makes it easier for people to explore foreign cultures.

WordLensDemo5Feb2012

From my own personal observation, I wasnt that much into mobile technology when I was living in the UK, maybe because I did not needed it as much. However, in Japan, my smartphone became one of my most prized possessions, as it connected me to the rest of the world and made it convenient for me to interact with my surroundings (even the simple task of checking the ingredients in a product, which would otherwise be impossible if Google Translate did not exist). 

I believe that this convenience of travelling and staying connected to the rest of the world will bring about another positive transformation, although this may not happen during our lifetime. It is highly likely that someday, as more people interact and connect with foreign cultures, borders between countries will start to dissolve and the world will become a united planet were everyone will be able to travel and settle down wherever they like. In turn, this could promote world peace and abundant economical growth. Smartphones and mobile networks will be at the heart of this evolution, as they silently make it easier for us to travel far and wide.

Invaluable help for the most vulnerable 

Its summer in the northern hemisphere. For many of us, this is a time to think of when and where to go for a summer holiday. Unfortunately, summer has a different meaning for terrorist organisations as conditions become more favorable to escalate conflicts. Consequently, summer means something totally different to the refugees who try to flee from war.

The smartphone is, again, the key tool that allows refugees to navigate around foreign places, send distress calls, or communicate with relatives they had to leave behind in the conflict regions. We should agree that things could have been much worse if mobile networks did not exist.

refugee-boat

But how do refugees gain access to internet?

My investigations focusing on the conditions of Syrian refugees in Turkey, did not reveal strong evidence of widespread wireless connection availability in refugee camps. Facebook is working towards providing free internet for UN refugee camps, according to the BBC. However, this hasnt been accomplished yet.

Some people have to pay exorbitant fees for internet access, for example by getting it directly from human traffickers or by means of undocumented work. In this respect, as in many others, refugee populations remain highly vulnerable to exploitation.

Difficult as securing access may be, owning a smartphone gives refugees the chance to communicate, collect information, and navigate in unknown territories. This holds true even for those who make it to Europe. In interviews, many of them said that the smartphone and the external battery packs are among the most important items they carry with them.

It has become an instinctual gesture to turn to our smartphones when we are exposed to an unknown environment. Writing about this reminds me of my first year in Japan (2014) when I was using an LG Nexus 5. Even in such a safe country, I would avoid going to places that I was not familiar with late at night, if I wasnt sure my battery would hold up (and the Nexus 5s battery was nothing special). Its no wonder that theres a big market for those budget Chinese phones with huge batteries or for insane battery packs! Just imagine

For the rest of us who should not have a refugee experience, the smartphone allows us to find information beyond what may be delivered to us by the mass media. Unfortunately, the refugee crisis feels like it is becoming an insolvable problem, and I am sure that almost each of us have an opinion on what the best solution may be. If we agree that its not possible to have a meaningful opinion without acquiring knowledge, I think mobile networks dramatically increased the breadth of knowledge on our fingertips.

Solving big science problems together

Speaking of seemingly insolvable problems, this year weve seen Googles DeepMind AI conclusively mastering the game of Go (an ancient Chinese board game). DeepMind crushed a human Go champion by selecting the best decision out of an intractable number of potential choices. This showed that with out-of-the-box thinking,  machine learning can help us overcome problems which may seem beyond our reach today.

Recent research published in the highly respected scientific journal Nature has shown that humans still have an ace up their sleeves when it comes to solving complex problems better than machines. In order to find better solutions to quantum computing problems, researches took them to the general public by making a game representing these quantum computing problems: Quantum Moves.

041316_ec_quantum-computing_free

By studying peoples intuitive solutions (remember these people are just playing a game and have no knowledge of quantum physics) to the problems presented in the game, the scientists were able to identify much quicker solutions to their rocket-science problems. This shows the potential benefit of taking things to the general public, again made possible by mobile networks and smartphones.

Maybe someday we will come to a stage where more apparently insolvable problems will be taken to the public and with joint collaborative efforts we will overcome them together to make the world a better place to live. Again, I think the smartphone will be at the heart of this change and it will strengthen its status as an indispensable item in the 21st century.

Please comment down below and let us know what you think on how the world is changing positively because of smartphones!



from Android Authority http://ift.tt/2ajOSeu
via IFTTT

Available link for download

Read more »

Monday, January 2, 2017

Better Google Drive Sync

Better Google Drive Sync


Google Drives apps for Windows and Mac got better. You can now select which subfolders to sync with your computer. Until now, you could only select the top-level folders.


Google Drives sync options show the size of your individual subfolders and the space remaining on your computer, just in case youre running out of free disk space. Another new feature shows a warning when youre deleting or moving a file thats shared with other people.


Available link for download

Read more »

Monday, December 19, 2016

Building better apps with Runtime Permissions

Building better apps with Runtime Permissions


Posted by Ian Lake, Developer Advocate

Android devices do a lot, whether it is taking pictures, getting directions or making phone calls. With all of this functionality comes a large amount of very sensitive user data including contacts, calendar appointments, current location, and more. This sensitive information is protected by permissions, which each app must have before being able to access the data. Android 6.0 Marshmallow introduces one of the largest changes to the permissions model with the addition of runtime permissions, a new permission model that replaces the existing install time permissions model when you target API 23 and the app is running on an Android 6.0+ device.

Runtime permissions give your app the ability to control when and with what context you’ll ask for permissions. This means that users installing your app from Google Play will not be required to accept a list of permissions before installing your app, making it easy for users to get directly into your app. It also means that if your app adds new permissions, app updates will not be blocked until the user accepts the new permissions. Instead, your app can ask for the newly added runtime permissions as needed.

Finding the right time to ask for runtime permissions has an important impact on your app’s user experience. We’ve gathered a number of design patterns in our new Permission design guidelines including best practices around when to request permissions, how to explain why permissions are needed, and how to handle permissions being denied.

Ask up front for permissions that are obvious

In many cases, you can avoid permissions altogether by using the existing intents system to utilize other existing specialized apps rather than building a full experience within your app. An example of this is using ACTION_IMAGE_CAPTURE to start an existing camera app the user is familiar with rather than building your own camera experience. Learn more about permissions versus intents.

However, if you do need a runtime permission, there’s a number of tools to help you. Checking for whether your app has a permission is possible with ContextCompat.checkSelfPermission() (available as part of revision 23 of the support-v4 library for backward compatibility) and requesting permissions can be done with requestPermissions(), bringing up the system controlled permissions dialog to allow the user to grant you the requested permission(s) if you don’t already have them. Keep in mind that users can revoke permissions at any time through the system settings so you should always check permissions every time.

A special note should be made around shouldShowRequestPermissionRationale(). This method returns true if the user has denied your permission request at least once yet have not selected the ‘Don’t ask again’ option (which appears the second or later time the permission dialog appears). This gives you an opportunity to provide additional education around the feature and why you need the given permission. Learn more about explaining why the app needs permissions.

Read through the design guidelines and our developer guide for all of the details in getting your app ready for Android 6.0 and runtime permissions. Making it easy to install your app and providing context around accessing user’s sensitive data are key changes you can make to build better apps.

Join the discussion on

+Android Developers

Available link for download

Read more »

Friday, October 21, 2016

Fragments 101 building better user interfaces

Fragments 101 building better user interfaces


android fragments android studio screenshot-16x9-720p

Android is an exciting platform to develop for, but it does have one major limitation: you can only display a single Activity onscreen at any one time (true, the upcoming Multi-Window mode does seem set to shake things up a bit, but well get to that shortly).

Thats where fragments come in.

Ever since Android 3.0, fragments have given developers a way of dividing their apps user interface into multiple, self-contained blocks, and then displaying these blocks in the way that makes sense for the users current screen configuration.

When you include fragments in your application, your app can either display these fragments:

  • One at a time in separate activities, in whats known as single-pane mode.
  • Side-by-side in a single Activity, in whats known as multi-pane mode.

For example, if you use fragments your app may choose to display a single fragment on a handset thats held in portrait mode, and then display two fragments side-by-side on a tablet-sized device – or, it may even switch to multi-pane mode when the user tilts that aforementioned handset from portrait mode, into landscape mode.

featuredSee also: Using CoordinatorLayout in Android apps1

This is where the real value of fragments lie: they give you a way of designing a single UI thats flexible enough to adapt to a wide range of different screen configurations. Thanks to the magic of fragments, you can sleep soundly at night knowing that your app is providing a good user experience, regardless of the kind of device it winds up on.

So what is a fragment, exactly?

Lets look at an example. Imagine you have a single Activity (the imaginatively-titled Activity A) and two fragments (Fragment 1 and Fragment 2).

Fragment 1 displays a list of nearby tourist attractions the user might want to visit. When the user selects an item from this list, Fragment B displays information about the currently-selected attraction.

Depending on the current screen configuration, your app may display these fragments in the following ways:

  • If the users screen is large enough, Activity A will display Fragment 1 and Fragment 2 side-by-side, in a multi-pane layout.
  • If there isnt enough room to accommodate both fragments, the app displays each fragment separately. In this scenario, Activity A displays Fragment 1 only. When the user selects an item from Fragment 1, the app creates a new Activity (lets call it Activity B) whose sole purpose in life is to host Fragment B.

Where does Multi-Window mode fit into all of this?

At this point you may be wondering: whats the difference between fragments and Nougats Multi-Window mode?

Android 7.0 seems set to address some of the platforms one-Activity-at-a-time limitations, but theres a crucial difference between fragments and Multi-Window:

  • Multi-Window will allow Android users to view Activities from different applications side-by-side.
  • Fragments give developers a way of displaying different content within a single application, depending on the users current screen configuration.

What you need to know before using fragments

When used correctly, fragments are a powerful tool in the Android developers arsenal, but if youre going to get the most out of fragments theres a couple of things you need to bear in mind:

1. A fragment is closely tied to its host Activity

A fragment may have its own behaviour, user interface and (to a certain extent) its own lifecycle, but it can only ever exist inside a host Activity. In fact, let me clarify that point about a fragments lifecycle: you can only add and remove fragments when the host Activity is in its resumed state. This means that even though a fragment does have a distinct lifecycle, that lifecycle is dependent on the lifecycle of its host Activity.

For the sake of keeping this tutorial (relatively) punchy, Im only going to look at how to add a fragment to an Activity declaratively, as this is the quickest and easiest way of getting started with fragments. The downside to this particular method, is that you wont be able to add and remove this fragment at runtime – if this is your end goal, then youll need to delve into your applications code (and the official Android docs has lots of useful info on this).

2. Backwards compatibility

If you want your app to connect with the largest possible audience (and who wouldnt want that?) then it has to be compatible with as many different versions of the Android operating system as possible. The good news is that, even though fragments didnt find their way into Android until Honeycomb, you can use fragments in your project while remaining backwards compatible with Android 1.6 and higher, thanks to the Android Support Library v4.

To add this Support Library to your project, launch the Android SDK Manager, select the SDK Tools tab and download the Android Support Repository.

fragments - android sdk manager-16x9

Next, add the library to your project by opening its module-level build.gradle file and adding the following to its dependencies section:

 dependencies { ……… ……… ……… compile com.android.support:appcompat-v7:24.0.0 } 

This is all you need to do for now, but just be aware that when you come to create your host Activity youll need to do the following:

  • Extend FragmentActivity, instead of the usual Activity class.
  • Import the android.support.v4.app.Fragment class.

Ill come back to both of these points when were looking at how to create your first Android fragment – which conveniently, just-so-happens to be the subject of our next section.

Creating a Fragment

Although you can create invisible fragments that contribute background behaviour but dont contribute a UI component, most fragments do have a user interface, so Im going to kick things off by defining my fragments UI.

In Android Studio, create a new layout file by opening your projects app/res folder, and then right-clicking the layout folder and selecting New, followed by Layout resource file.

fragments - new layout resource file-16x9
Give your layout resource file a name (Im going to use list_fragment) and select the root element you want to use, such as LinearLayout or RelativeLayout.

fragments - new resource file window-16x9
Click OK and Android Studio will go ahead and create your layout resource file. At this point you can add whatever UI elements you want to include in your fragment. Im going to use the following:

 <?xml version="1.0" encoding="utf-8"?> <LinearLayout  android_orientation="vertical" android_layout_width="match_parent" android_layout_height="wrap_content" android_background="#CCCCCC"> <TextView android_layout_width="wrap_content" android_layout_height="wrap_content" android_textSize="30sp" android_textStyle="bold" android_textColor="#ffffff" android_text="This is the contents of my list_fragment.xml" android_id="@+id/textView2" android_layout_gravity="center_horizontal" /> </LinearLayout> 

As well as a UI component, you need to have a class associated with your fragment. To create a new class, open your projects app/Java folder, right-click its package name and select New, followed by Java Class.

fragments - new java class-16x9
Give your new class a name (Im going to use ListFragment), then open your new class file and make the following changes:

 import android.os.Bundle; //If you want your app to be compatible with devices running Android 1.6 and earlier, //you need to import the fragment class from the v4 support library// import android.support.v4.app.Fragment; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; //Since Im targeting devices running Android 1.6 and higher, //Im going to extend FragmentActivity, rather than the usual Activity class// public class ListFragment extends FragmentActivity { @Override //onCreateView() must return a View, which is the root of your fragments layout// public View onCreateView(LayoutInflater inflater, ViewGroup container, //If the fragment is being resumed, savedInstanceState will pass data //about the previous instance of the fragment// Bundle savedInstanceState) { //Inflate the fragments layout resource file// return inflater.inflate(R.layout.list_fragment, container, false); } } 

The final step is adding this fragment to your Activity. As already mentioned, there are two ways of doing this, but in this article Im only going to look at adding the fragment declaratively by embedding it in the host Activitys layout resource file.

To add a fragment to an Activity, simply open that Activitys corresponding layout resource file and declare the fragment you want to use, in exactly the same way youd declare a View. So you have no problems distinguishing between the portion of the finished UI thats contributed by the activity_main.xml file, and the portion thats contributed by the fragment, Im going to set activity_main to display an image:

 <?xml version="1.0" encoding="utf-8"?> <RelativeLayout   android_layout_width="match_parent" android_layout_height="match_parent" android_background="@drawable/background" tools_context="com.fragmentsexample.jessicathornsby.myapplication.MainActivity"> //Add your fragment// <fragment android_name="com.fragmentsexample.jessicathornsby.myapplication.ListFragment" android_id="@+id/list_fragment" android_layout_width="match_parent" android_layout_height="wrap_content" /> </RelativeLayoutLayout> 

Wrap-up

And thats it! The full source code for the demo app can be found on GitHub. How have you used fragments in your own Android app projects? Let us know in the comments.



from Android Authority http://ift.tt/2ak1cKN
via IFTTT

Available link for download

Read more »

Monday, September 19, 2016

Building better mobile apps for work

Building better mobile apps for work


Posted by Matt Goodridge - Google Play for Work Product Manager

Last year, we introduced Android for Work, a program designed to pair the strength of the Android platform with support from the rich ecosystem of OEMs (device manufacturers like Samsung), EMMs (Enterprise Mobility Managers) and carriers with the goal of transforming the workplace. This means that developers get the support they need to develop apps that configure to meet business needs without customization.

With Android for Work, developers have been able to build apps for business and make them available via Google Play for Work to all types of industries. No matter the place or use case, Android for Work has helped lead businesses to foster employee productivity and creativity through increased mobility.

Today we are announcing the Android for Work DevHub, a place for developers to keep up with Android in the workplace and engage fellow business app developers in an open forum. Android for Work DevHub members will receive access to Google Play for Work and Android for Work product betas and developer events and will have the opportunity to learn from Google experts on topics like how to:

  • leverage tools and resources provided by the AppConfig Community, which established a standard that provides Android developers a simple way set up app configurations,
  • improve app security by integrating with Android for Work APIs,
  • get an app featured on Google Play for Work,
  • and more…

Among the early members of the Android for Work DevHub is Keeper, a mobile-first company committed to securing corporate credentials and sensitive information. Darren Guccione, Keeper’s CEO and co-founder, said: “Having our team be able to talk with Google experts as a part of the Android for Work DevHub has been very helpful in optimizing Keeper, as an essential product, for the workplace.” In addition to Keeper, select developers across an array of industries are already represented in the Android for Work DevHub, and—starting today—any business developer can apply to become a member, too.

To learn more about Android for Work, join us at Google I/O Thursday, May 19th at 2pm on Stage 10 Cassiopeia. I’ll be joined live on stage with James Kelly, product manager in Android for Work and Rich Hyndman, and Android developer advocate, to walk through the latest developments in Android for Work that will help you make awesome apps for businesses and to meet the Android for Work team in-person at our shop to see the Android for Work retail experience.


Available link for download

Read more »