LightBlog

vendredi 26 août 2016

Galaxy Note 7’s new all-in-one Notes app will come to other Note devices

GalaxyNote7_SamsungNotes_1

Previous Note users who jumped on Samsung's newest phablet powerhouse may have noticed, upon ejecting the S Pen, that note management of your different inputs has changed. This is because Samsung has simplified the experience, and consolidated all the note-taking functions into one app – Samsung Notes. Before, different use cases were separated between Action memo, S Note, Scrapbook, and Memo apps.

note-7-s-penSee also: Note-worthy: Taking a closer look at the new S Pen9

Apart from being simpler on the user (i.e. tabbing between available tools instead of switching apps), having a one-stop note app allows for some nifty integration between different kinds of content. For instance, users can merge a drawing, text, and voice recording into a single note creation. Samsung integrated a way for the app to detect the type of content and adjust its size based on the grid-style interface of the home screen, making it easier to visualize or share.

Samsung Notes doesn't just improve management but enhances note capabilities as well. The text input now supports check boxes, bullets, numbering, and font colors. It has handwriting recognition, if you prefer to write out your notes, and the app's search feature can detect handwritten notes. On the drawing side of things, Samsung Notes sports seven types of specialized drawing brushes.

GalaxyNote7_SamsungNotes_2

This is all dandy, but what if you're sticking with your current Note a bit longer? Fortunately, Samsung has stated that the new Samsung Notes app will be carried over to other Note devices 'in the near future'. That's a little vague – we don't know how far back the support will reach or how soon that means, but at least it's something. Do older Note owners want to get in on the Samsung Notes action, or is it not a big deal for you?



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

The Hangouts Chrome extension is getting a familiar makeover

New Google Hangouts Chrome extension

While you're waiting for Allo to launch – or you're video-calling one of the other five million Duo usersGoogle is still giving Hangouts a fair shake.

The company announced an update to the Hangouts Chrome extension interface that will make it very similar to the Hangouts Chrome app interface. After the update the Chrome extension will feature the same tablet-style interface as the Chrome app, with a permanent contact list on the left side and the conversations on the left (see the screenshot above.)

Google says the change will make the experience of group chats more consistent and easier to navigate.

New Google Hangouts users will see the new interface starting August 31, and existing users will be given the option to switch starting the same day. On October 15, the new interface will kick in for every user of the Hangouts Chrome extension.

Seeing that Google is shutting down the Chrome app store for everyone except Chrome OS users, it will probably focus on the extension from now on. As for the Hangouts service itself, its future is uncertain. When Allo was announced back in May, Google denied that it would replace Hangouts, but the writing was on the wall. More recently, Google said that Hangouts would be retooled as a corporate messaging app.



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

Google quietly shuts down Device Assist support app

device assistant android apps

Spare a thought for Device Assist. It didn't even get to celebrate its second birthday.

Google quietly pulled the plug on Device Assist, an app that helped Nexus and Android One users make the most of their devices. Launched in late 2014, the app alerted users about potential issues that it detected on the device. In a cruel twist, it now alerts users about its own demise.

Google has a record of shutting down services, inevitably upsetting faithful users in the process. But Device Assist is no Google Reader: the app lived anonymously and it's now going quietly into the night.

The problem with Device Assist was that it wasn't really helpful for its intended audience. While tips on how to change display brightness or how to clear up storage space may be useful to some users, Nexus – and Android One – users tend to be more savvy than the general population. We don't have any usage stats, but it's likely that supporting it was simply not worth the trouble anymore.

Device Assist is no longer available in the Play Store, thought it remains functional for the users who had it installed.



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

2-in-1 iris scanner and camera modules could accelerate mid-range adoption

Samsung Galaxy Note 7 iris scanner registration

The inclusion of iris scanning technology inside Samsung's Galaxy Note 7 sets a another new standard for smartphone security. However, like all new developments, it's not cheap to implement and will take a while to trickle down to lower cost models.

This is partly because a front facing camera component is used along side a separate chip for authenticating the scanned iris against registered copies, requiring the purchase of multiple components. Combining these two essential features on to a single chip would help handset manufacturers save on both development and components costs, allowing them to bring iris scanning technology to lower cost smartphone models. Fortunately this is exactly what Dongwoon Anatech Co. Ltd. has achieved.

"Integrated modules can reduce cost and it is more advantageous from a design perspective since it takes up lesser space within a smartphone .. It is predicted that camera modules with IR filters will become a trend for iris authentication solution in the future." – Dongwoon President Kim Dong-cheol.

IR filter changer drive IC

An employee from Dongwoon examines an IR filter changer driver for iris authentication

The company has announced the development of an infrared filter changer driver IC that can authenticate an iris using infrared light wavelengths rather than visible rays of light. The camera can still function as a regular selfie camera too, as the design features an actuator that raises an IR filter in front of the camera lens when scanning an eye. Japanese semiconductor has also produced a very similar chip that uses infrared technology.

The cost of production is expected to fall by around 30 percent compared with using two separate components. The company also has a similar chip design that integrates optical image stabilization into the IC, which usually multiplies costs 10 fold. Hopefully this new design can bring these high-quality components to the market at reduced costs as well.

Samsung-Galaxy-Note-7-hands-on-first-batch-AA-(18-of-47)See also: Samsung explains how the Galaxy Note 7 iris scanner works26

Who knows, we might see a lot more smartphones boasting iris scanning technology in the next year or so, and they might not all come with flagship price tags either.



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

Reactive programming with RxAndroid

rxsample_featured

Reactive programming, RxJava and RxAndroid have become increasingly familiar nomenclature within the Android app development world. For someone new to these concepts, it can appear a little bit overwhelming and strange. The aim of this tutorial is to show how simple reactive programming actually is, and to serve as an introduction for developers not familiar with the concept (also a refresher for all you uber reactive programmers).

Reactive programming concepts

Reactive programming is an extension of the Observer software design pattern, where an object has a list of Observers that are dependent on it, and these Observers are notified by the object whenever it's state changes.

There are two basic and very important items in reactive programming, Observables and Observers. Observables publish values, while Observers subscribe to Observables, watching them and reacting when an Observable publishes a value.

In simpler terms:

  • An Observable performs some action, and publishes the result.
  • An Observer waits and watches the Observable, and reacts whenever the Observable publishes results.

There are three different changes that can occur on an Observable that the Observer reacts to. These are:

  1. Publishing a value
  2. Throwing an error
  3. Completed publishing all values

A class that implements the Observer interface must provide methods for each of the three changes above:

  1. An onNext() method that the Observable calls whenever it wishes to publish a new value
  2. An onError() method that's called exactly once, when an error occurs on the Observable.
  3. An onCompleted() method that's called exactly once, when the Observable completes execution.

So an Observable that has an Observer subscribed to it will call the Observer's onNext() zero or more times, as long as it has values to publish, and terminates by either calling onError() or onCompleted().

Sample Program

As usual, we have developed a sample app, available on github, that demonstrates the concepts in this tutorial. Each concept is presented in it's own Activity. You'll need the rxjava and rxandroid libraries for this tutorial, which you can add to your project by including the following lines in your app build.gradle file.

  dependencies {      ...      compile 'io.reactivex:rxandroid:1.2.1'      compile 'io.reactivex:rxjava:1.1.9'  }  

Simple Example

Our first sample activity is the quintessential Hello World. We are going to create an Observable that retrieves a string from a TextView, and publishes this string to an Observer. This Observer then outputs the string to a TextBlock.

Creating an Observable
We've elected to create our Observable using the static Observable.create() method. There are a ton of different ways to create Observables, some of which we'll get to later, and most of which you'll discover based on your needs.

          Observable<String> myObservable = Observable.create(                  new Observable.OnSubscribe<String>() {                      @Override                      public void call(Subscriber<? super String> sub) {                          sub.onNext(rx1Binding.editText.getText().toString());                          sub.onCompleted();                      }                  }          );  

From the code snippet above, the Observable's onSubscribe() method calls the Subscriber's onNext(), followed immediately by onCompleted(). (A Subscriber is a class that implements the Observer interface).

Creating an Observer
Creating our Observer is pretty straightforward, as seen in the code chunk below. We simply override the Observer interface methods. Notice that we have empty implementations for both onCompleted and onError.

          Observer myObserver = new Observer<String>() {                @Override              public void onCompleted() {                }                @Override              public void onError(Throwable e) {                }                @Override              public void onNext(String text) {                  rx1Binding.textView.setText(text);              }          };  

Linking Observable and Observer
Now that we've created both the Observable and Observer, we have to link them, so that the Observable knows to publish to the Observer. This is done with the Observable's subscribe() method, which is called whenever the "Subscribe" button is clicked.

          rx1Binding.button.setOnClickListener(new View.OnClickListener() {              @Override              public void onClick(View view) {                  myObservable.subscribe(myObserver);              }          });  

Sample Activity1

Voila! We have used reactive programming to fetch and display a string in an Android app. Now, this is a lot of work to display a string, and can be done with much more simplicity and elegance using

  rx1Binding.textView.setText(rx1Binding.editText.getText().toString());  

Let's move on to a more involved sample.

Asynchronous Example

In the previous sample, the Observable fetched a string instantly from within the app. It is highly likely, however, that the Observable would need to perform some long running task such as fetching data from a remote server. For this next sample, we are going to pause for 3 seconds while in the Observable, and then modify the received string before publishing it to the Observer.

rxsample_activity2

As dicussed above, within the Observable, execution is paused for 3000 milliseconds, and then the content of the EditText is split based on newlines. Each line is numbered, and then all the lines are published to the Observer.

          myObservable = Observable.create(                  new Observable.OnSubscribe<String>() {                      @Override                      public void call(Subscriber<? super String> sub) {                          try {                              Thread.sleep(3000);                          } catch (Exception e) {                              e.printStackTrace();                          }                          String[] strings = rx2Binding.editText.getText().toString().split("\n");                          StringBuilder builder = new StringBuilder();                          for (int i = 0; i < strings.length; i++) {                              builder.append((i+1) + ". " + strings[i] + "\n");                          }                          sub.onNext(builder.toString());                          sub.onCompleted();                      }                  }          );  

The Observer remains unchanged from the previous sample. It expects a string from the Observable, and publishes this string to the TextBlock.

Execute Observable on another thread

For any application that users interact with, long running tasks should not be executed on the main UI thread, since this can freeze up the application, and make it appear unresponsive. In Android development, these kind of tasks are usually abstracted into an AsyncTask, and when the task is complete, the UI is updated via on the main thread.

To achieve the same using RxAndroid,

          rx2Binding.button.setOnClickListener(new View.OnClickListener() {              @Override              public void onClick(View view) {                  rx2Binding.button.setEnabled(false);                  myObservable                          .subscribeOn(Schedulers.io())                          .observeOn(AndroidSchedulers.mainThread())                          .subscribe(myObserver);              }          });  

The subscribeOn() method above specifies the thread that the Observable runs on, which is set to the IO Scheduler (Schedulers.io()) . The observeOn() method indicates what thread the Observer should execute on. By default, the Observer will be executed on the same thread as the Observable, but we have set the observeOn() thread to AndroidSchedulers.mainThread() (RxAndroid specific method that indicates the Android UI thread). With just those two lines, we have specified that the blocking/time consuming Observable execute in the background, and whenever it completes, the result should be displayed on the UI.

Introducing Operators

Take a look at the code we used to subscribe in the previous step.

                  myObservable                          .subscribeOn(Schedulers.io())                          .observeOn(AndroidSchedulers.mainThread())                          .subscribe(myObserver);  

We added a couple of intermediate steps between the Observable and the final Observer. Each step above creates a new Observable, and there can be any number of intermediate steps between the initial Observable and the final Observer. These intermediate methods are referred to as operators. There are a huge number of operators in the RxJava library, which we cannot realistically make a dent in within a reasonably sized article.

An interesting, and easy to understand operator is the map() operator. It transforms objects of one type to another. for example

  map(new Func1<Integer, String>() {   @Override   public String call(Integer integer) {   return String.valueOf(integer);  }   });  

In the snippet above, we are converting an Observable that publishes an Integer into an Observable that publishes a String. In the call method, we receive an Integer, and return the String equivalent. The map() method handles the creation of the relevant Observable.

Other ways of creating Observables

Up to this point, we've used only the Observable.create() method to initialize our Observables. The RxJava library contains many other methods for creating Observables, depending on the initial data, and/or how the published values should be consumed. Two of these many methods include Observable.from() and Observable.just().

Observable.just() converts any object into an Observable. For example, the following single line will completely replace the Observable.create() block in our two sample Activity classes above.

  Observable.just(rx1Binding.editText.getText().toString());  

An Observable is created with the single line above. Observable.from() is identical to Observable.just(), except that it expects an Iterable, and will publish an Observable for each of the contents of the Iterable.

A more involved sample

The third sample is going to build expand on the second, an utilize the new concepts introduced above. We will split a string into a list, then, for each item in the list, we would append it's position in the list, and publish each item.

SampleActivity3

        Observable.from(rx3Binding.editText.getText().toString().split("\n"))                .subscribeOn(Schedulers.io())                .map(new Func1<String, String>() {                    @Override                    public String call(String morphedString) {                        try {                            Thread.sleep(2000);                        } catch (Exception e) {                            e.printStackTrace();                        }                        return mCounter++ + ". " + morphedString;                    }                })                .observeOn(AndroidSchedulers.mainThread())                .subscribe(myObserver);  

We've condensed the creation of the Observable, using Observable.from(). For each String published to map(), the app sleeps for 2000 milliseconds, appends the string position to the string, before finally publishing to the Observer. The Observer still remains unchanged.

Handling Errors

An error anywhere in between the source Observable and target Observer gets propagated directly to the Observer's onError() method. The advantage of this is that there is one central place for error handling. No matter how complex your Observable tree gets, the error handling is done at the end, within the Observer's onError().

          myObserver = new Observer<String>() {                @Override              public void onCompleted() {                  rx3Binding.button.setEnabled(true);              }                @Override              public void onError(Throwable e) {                  Toast.makeText(SampleRxActivity4.this,                          "A \"" + e.getMessage() + "\" Error has been caught",                          Toast.LENGTH_LONG).show();                  rx4Binding.startButton.setEnabled(true);                  rx4Binding.stopButton.setEnabled(false);              }                @Override              public void onNext(String string) {                  rx4Binding.textView.setText(rx4Binding.textView.getText() + "\n" + string);              }          };  

Reactive programming - onError

To test this, we included a toggle button, to indicate if we want to trigger an error condition. Within the map() operator, we attempt a divide by zero if the toggle is checked, as shown below.

                  Observable.from(rx4Binding.editText.getText().toString().split("\n"))                          .subscribeOn(Schedulers.io())                          .map(new Func1() {                              @Override                              public String call(String morphedString) {                                  try {                                      Thread.sleep(2000);                                  } catch (Exception e) {                                      e.printStackTrace();                                  }                                  if (rx4Binding.errorToggle.isChecked())                                      mCounter = 2 / 0;                                  return mCounter++ + ". " + morphedString;                              }                          })                          .observeOn(AndroidSchedulers.mainThread())                          .subscribe(myObserver);  

Stopping Subscriptions

So far, we have gone by the assumption that our Observables will execute to completion, and publish all values to the Observer. This is not practicable in real life, since the user might close your app before your Observable has done executing. Also, your Observable can possibly never terminate, publishing values on a timer, or on receipt of data from some other source.

The subscribe() method returns a Subscription object, whose sole purpose is to allow unsubscribing. In the demo app, we declare a Subscription variable

  public class SampleRxActivity4 extends AppCompatActivity {      Subscription subscription;      ...    }  

Then we assign the Subscription created by calling subscribe to our Subscription variable.

                  subscription = Observable.from(rx4Binding.editText.getText().toString().split("\n"))                          .subscribeOn(Schedulers.io())                          ...                                                    .observeOn(AndroidSchedulers.mainThread())                          .subscribe(myObserver);  

And finally we unsubscribe whenever the "Stop Subscription" button is clicked.

          rx4Binding.stopButton.setOnClickListener(new View.OnClickListener() {              @Override              public void onClick(View view) {                  if (!subscription.isUnsubscribed())                      subscription.unsubscribe();                  rx4Binding.startButton.setEnabled(true);                  rx4Binding.stopButton.setEnabled(false);              }          });  

Reactive programming - Stop subscription

Also, make sure to unsubscribe from all Observables in your Activity's onStop() method (or onPause() depending on what you're observing).

      @Override      public void onStop() {          super.onStop();          if (!subscription.isUnsubscribed())              subscription.unsubscribe();      }  

Final Notes

Observers should be what reacts to mutations. You should avoid performing any cpu and/or network intensive tasks on an Observer. In fact, you should perform as little computation as possible in your Observers. All the hard work should be done in the Observable, while the Observer receives the results. Check out the RxJava and RxAndroid javadocs for more information.

As usual, the complete source code for the examples used in this tutorial is available on github. Feel free to check out and use however you see fit.



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

(Update: Nexus 5X added) Android 7.0 Nougat factory images are going live now

Android 7.0 Nougat logo AA 2

If you've been waiting for the Android 7.0 Nougat factory images to appear, the rollout is starting now. Android 7.0 factory images are available on the Google Developers site for the Nexus 9 (Wi-Fi), Pixel C and Nexus Player (links below). We expect images for the recent Nexus smartphones will follow soon.

Android 7.0 Nougat review - N releaseSee also: The official list of Android 7.0 Nougat features317

All three have the same build number as those devices that have already received the OTA update: NRD90M and come with the August 5 security patch. The OTA images are also available for these three devices if you'd prefer to go that route instead. If you need a little help with the flashing procedure, feel free to check out our guide to flashing factory images.

Let us know how you go with Android 7.0 Nougat update and what you think of Google's rollout of it. I don't know about you, but this has been one of the least painful updates I've ever seen. The OTA rolled out so fast yesterday that for the first time I didn't even have to flash a factory image to get the latest version of Android.

Up next: How Android Nougat's Direct Boot feature works



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

Pink gold Galaxy S7 and S7 edge land at Best Buy

Pink Gold Galaxy S7

After a bit of a wait, the snazzy pink gold versions of the Samsung Galaxy S7 and S7 edge are finally hitting the US. The phone will be sold exclusively through Best Buy, with a selection of carrier options available. The pink gold model originally appeared in South Korea all the way back in April.

Other than the color change, the pink gold model features exactly the same hardware as other US Galaxy S7 and S7 edge handsets. So that's the Snapdragon 820 processor version, with 4GB RAM, 32GB of internal storage, a 12MP camera, and the rest of the goodies. However, Best Buy won't be selling an unlocked version of this handset. This color option will only be available with AT&T, Sprint, and Verizon branded handsets, which is a bit of a disappointment.

To sweeten the deal, Best Buy is throwing in a $150 gift card with each purchase. There's also free Gear Fit 2 up for grabs if you opt for the S7 edge variant.

  • HTC 10 VS Samsung Galaxy S7 ...
  • Samsung Galaxy S7 Vs S7 Edge
  • LG G5 vs Galaxy S7 Edge

Samsung indicates that the new color option should go on sale on August 28th, but the AT&T branded version already appears available to purchase. If you're interested in this funky color option, click the button below to head over to Best Buy.

Order from Best Buy


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