EE Harrier and Harrier Mini review
EE’s Kestrel was its first own-brand 4G smartphone, meant for those wanting breakneck mobile data speeds without breaking the bank. One year on, the Kestrel is coming to the end of its life, and when remaining stock is depleted, it’ll disappear from the network’s handset roster. The market for affordable 4G smartphones isn’t vanishing anytime soon, however, which is why EE’s readied a replacement for the Kestrel prior to its retirement. Actually, make that two: the new EE Harrier and Harrier Mini.
The Harrier Mini is what you’d consider the true spiritual successor to the Kestrel, with the more modest spec sheet and monetary requirements (it’s £100 on pay-as-you-go). In this sense, the larger Harrier (£200 on pay-as-you-go) is a small step into new territory for EE, intended to satisfy the more exacting consumer with an eye for bigger and better numbers. Regardless of their differences, however, affordability is of paramount importance to both, and by design, they are among the cheapest devices available on EE’s network. Compared with peers in roughly the same price range, however, the Harrier stands out as offering good value for your money, whereas the Mini feels like something of a devolution from EE’s previous form.
Hardware

Last year, EE sought the manufacturing grunt of Huawei to deliver its first own-brand device. This time around, however, EE drafted in an old friend from the Orange and T-Mobile days, BenQ, to produce the Harrier and its smaller sibling. The result is a pair of bespoke devices developed for EE alone, as opposed to a retooled and rebranded version of an existing device as is the Kestrel. Despite being made specifically for the carrier, though, neither Harrier manages to shake that OEM-made aura all own-brand handsets seem to bear.
That’s not to say either is particularly unseemly, just that they have a generic quality to them. Rectangles with rounded corners, slightly curved backs — not too thin and not too fat: basic, functional design. Due to its larger display, the Harrier is significantly taller and wider than the Mini, but otherwise they’re identical in appearance. The only real defining feature of the pair is the brushed metal-effect back they share, which looks like it was lifted off an HTC One M8 or M9. It’s just a removable plastic cover shielding the micro-SIM and microSD card slots, but somehow it doesn’t come off as tacky despite it being an obvious imitation of more premium materials. The gold ring around the main camera lens and mirrored EE logo aren’t gaudy either, even if they sound like EE trying hard to make the Harriers look like something they’re not.

They certainly don’t feel excessively cheap, anyway. Build quality is robust and consistent across both Harriers, although being all-plastic affairs means you can twist and flex them (especially on the larger model) to a greater extent than if there were metal or extra glass incorporated into the design. There aren’t any squeaky seams, ill-fitting backplates or loose buttons, though, which are typical indicators of crude builds.
In use, both handsets are comfortable enough, with curves in the appropriate places that allow them to rest snugly in your palm. If I had to pick a side, however, I’d have to say I prefer the Harrier Mini to its bigger brother. It’s smaller, lighter, cuter and slips into your trouser pocket that much easier. The Harrier proper, in comparison, is much more difficult to use one-handed; awkward, almost. Yes, it has a significantly bigger, 5.2-inch display, but it doesn’t seem like much attention has been paid to ergonomics. The 5.2-inch LG G2 feels downright small in comparison. Still, you might not mind giving your hand a bit of a workout in exchange for the extra screen real estate.
| Harrier | Harrier Mini | |
|---|---|---|
| Dimensions | 147 x 74.5 x 8.9mm | 138 x 67.9 x 9.5mm |
| Weight | 145g | 124g |
| Display | 5.2-inch IPS LCD (1,920 x 1,080) | 4.7-inch IPS LCD (1,280 x 720) |
| Pixel Density | 424 ppi | 312 ppi |
| Processor | 1.5GHz octa-core Snapdragon 615 | 1.2GHz quad-core Snapdragon 410 |
| RAM | 2GB | 1GB |
| Storage | 16GB (expandable) | 8GB (expandable) |
| Primary camera | 13-megapixel BSI | 8-megapixel BSI |
| Secondary camera | 2-megapixel | 2-megapixel |
| Battery | 2,500mAh | 2,000mAh |
| OS | Android 5.0 Lollipop | Android 5.0 Lollipop |
| Cellular | Cat 4 LTE | Cat 4 LTE |
| WiFi | 802.11b/g/n | 802.11b/g/n |
| Bluetooth | 4.0 | 4.0 |
| NFC | Yes | No |
Display

EE didn’t cut any corners when it came to the devices’ screens. The Harrier has a 5.2-inch, full HD display (1,920 x 1,080) and the Mini, a 4.7-inch, 720p panel (1,280 x 720), both of which are respectable for their respective price points and sizes. And, despite a gap in pixel density between the two — 424 ppi for the Harrier and 312 ppi for the Mini — I can’t see any noticeable difference in acuity. Both are IPS LCD panels, meaning deep blacks aren’t their strong suit. Whites, on the other hand, are accurate, and colours are as vibrant as they should be. The Harrier’s display seems to have a little extra pop when bright colours are at play, but only when both handsets are next to each other showing the same image can you tell there’s a slight disparity.
Viewing angles aren’t the best, but they are by no means terrible, and sunlight readability is an area in which both shine. There’s plenty of power available to those LCD displays, especially the Harrier; enough to cut through the majority of glare on especially bright days. Android Lollipop’s adaptive-brightness setting judges situations admirably, but manual tweaks are sometimes necessary if you’re trying to frame a picture when the sun’s on your back, for instance.
Software

Both Harriers come with Android 5.0 Lollipop out of the box. The latest version of Google’s mobile OS is a significant upgrade from the last, so if you want to catch up on everything that’s changed, from the new “Material Design” language to added features, check out our full review here. EE hasn’t taken it upon itself to create any kind of branded skin for the Harriers, so you’re getting more or less the stock Lollipop experience. I say “more or less” because the carrier has decided to preinstall a lip-curling amount of bloatware, none of which can be uninstalled to free up space or declutter the app tray.
Some of this is pretty irritating, particularly the “Free Games & Apps” store I wouldn’t peruse if you paid me. Others, like Lookout Security & Antivirus and MailWise (an email client), some might find useful, but definitely didn’t need to be baked in. It’s a similar story for all of Amazon’s services: Kindle, Local, Music and its Appstore. I often take advantage of Amazon’s free app promotions and I’m invested in the Kindle ecosystem, but I’d prefer to make my own decisions and not be force-fed apps and services. It’s worth mentioning here that all of Google’s services are present on the handsets, too, so you’ve got access to the Play store (et cetera) as well as Amazon’s equivalent.

The Harriers were announced shortly after EE launched its seamless WiFi calling feature, and the Mini was pitched as the “most affordable 4G smartphone with WiFi calling.” This isn’t actually live on either Harriers at the moment, though, and is coming “this summer” as part of a software update. So, if WiFi calling is of particular importance to you, know that neither device is currently compatible.
Camera

Another area in which the two Harriers differ is their camera chops. Both sport 2-megapixel front-facing cameras for selfies and video calling, but the Harrier has a 13MP main camera compared with the Mini’s 8MP primary shooter. Surprisingly, you won’t find the stock Android camera app on either device; instead, there’s an app of unknown origin in its place. It takes a split-second longer to load than I’d like, and makes for a slightly more cluttered viewfinder. But it has a similarly basic interface. By this I mean you’re not overwhelmed with options: White balance, exposure compensation and ISO settings are all taken care of automatically. The menus aren’t for fine tweaking, but they’re where you find the panorama photo and slow-motion video modes, image quality settings — that sort of thing.
Neither device boasts a particularly spectacular example of a smartphone camera, but the Harrier’s is the better of the two, and not just because of its higher resolution. The automatic white balance setting seems to be more accurately tuned on the Harrier, though only in natural lighting. The Mini does a superior job of colour correction when artificial light sources are involved. It’s pretty rare for either handset to spit out the exact image you want, whether that’s because the colours aren’t quite as saturated as they should be, or the exposure setting is off. I’m also disappointed in the HDR mode on both devices, as the extra level of contrast it’s supposed to bring is barely noticeable. It can be useful for brightening up photos when the light begins to fade, but only on the Harrier since the Mini takes significantly longer to process the HDR image, so they often come out blurry.
Both Harriers have backside-illuminated sensors. The big brother handles low-lit situations slightly better than the Mini, but only marginally so. Focal range is a problem for both devices. Neither can be trusted to lock on to objects close to the lens and you’re lucky if the Harrier Mini manages to focus on anything regardless of distance. Quite often it doesn’t focus at all, resulting in a blurry mess of an image. Video quality (1080p) is comparable across the pair. Both have slightly fidgety autofocus and exposure settings, which I find is true with most smartphones, but the image and audio quality of clips is just fine otherwise.
As I said, the Harrier’s camera is without a doubt the better of the two, but keen smartphone photographers will probably want to steer clear of both devices, even if they edit their snaps with Instagram most of the time.
Performance and battery life

You’ve probably guessed already that of the two EE handsets, the Harrier is packing the bigger engine under the hood. A 1.5GHz octa-core Snapdragon 615, to be exact, compared with the Mini’s 1.2GHz quad-core Snapdragon 410. Before I get into specifics, I want to vent a particular frustration I have with Android 5.0 Lollipop: It’s slow. There’s a lot to like, but it’s lost that snap I so enjoyed on KitKat. Even on devices running some of the best mobile processors around, it feels slightly heavy and resource-intensive — the contrast in responsiveness between KitKat and Lollipop on the YotaPhone 2, for instance, is marked. Now, that’s not as much of an issue when you’re running seriously expensive hardware, but more affordable phones suffer.
The Harrier is powerful enough that this is more an observation, not a major gripe. In fact, whiz through a couple of tracks on Asphalt 8: Airborne, one of my go-to resource-hogging 3D games, and all will appear well. It loads relatively quickly and playing on the highest graphics setting is no trouble for the Harrier. But, why then do core experiences like Chrome, Google Maps and even the stock dialer take a second to boot up? Flicking through your home screen or the app drawer is as slick as ever, but the transitions between “desktop” and apps are no longer smooth and immediate. Browsing performance, too, has an extra, thin layer of lag in Lollipop, and whether using the Harrier or Mini, I found the duplicate “Browser” app to be quicker on the draw than Chrome.
The Harrier Mini actually suffers considerably at the hands of Lollipop. Ever since I reviewed the original Moto G, I’ve been a champion of budget smartphones — my argument being, why pay the best part of your monthly wage for a feature-obese, top-tier smartphone when you can get something for a fraction of the price that has an excellent user experience? Lollipop has basically thrown this back in my face, and the Harrier Mini is proof. I’d honestly much rather have a Kestrel, with KitKat running dreamily on the lesser Snapdragon 400.

Every slowdown on the Harrier feels exaggerated on its smaller sibling. Those core experiences take that little bit longer to load, and browsing is just a bit clunkier. I wrestled with crashes and extremely slow menu navigation when testing out Asphalt 8 on the device, even if it played well at the medium graphics setting when I was actually on the track. Multitasking is pretty much out of the question, too. If you’re downloading an app, for example, forget about doing anything else without the whole phone grinding to a halt. This isn’t going to be a problem for mum or dad, but it’s a far cry from what I usually expect out of affordable devices these days. I thought we were past this. Perhaps the Mini only having 1GB of RAM compared to the Harrier’s 2GB is partly to blame too, even if it shouldn’t be.
Another problem I have with the Mini is lack of storage. It’s advertised as having 8GB of internal memory, but the reality is you get less than 4GB to work with while Lollipop takes up the rest. There’s a microSD slot to supplement that, but if I can’t download large apps in the first place, how can I move them over to the SD card (if indeed, that app supports it)? I’ve even had to format the phone once after corrupting the memory with downloads and updates that didn’t complete, but clogged up available storage space all the same. You’re a little better off with the Harrier, which affords you just over 10GB of its 16GB total.
In terms of connectivity, both phones have all the basics: 802.11b/g/n WiFi, Bluetooth 4.0, GPS and, of course, Cat 4 LTE. The Harrier has NFC, too, which is welcome given that EE has its own Cash on Tap contactless payments app for small transactions. Battery life is formidable on both handsets. The Harrier carries a 2,500mAh nonremovable battery, while the Mini makes do with a 2,000mAh cell. Nevertheless, in our standard 720p looping-video battery-rundown test, the Harrier lasted nine hours, while the Harrier Mini squeezed out an extra 28 minutes on top of that.
Those results aren’t close to, say, the LG G4 and its 11-hour stint, but you’ve got plenty of juice to work with all the same. On one particular day of light usage, where the Harrier sat on my desk and I checked the odd notification, picked up a few calls and took a few pictures in the evening, I only used around 25 percent of battery life from dawn ’til dusk. Increase your screen time, though, and you’re still gonna get at least a full day of heavy usage out of either handset. Probably a full two days if you’re not trying to drain it for the sake of it.
The competition

Since both the Harrier and Harrier Mini are only available on EE’s network, it’s best to start with other options the carrier has. And it’s no real surprise that in terms of EE’s handset roster, they work out to be pretty competitive. The larger Harrier is available for free on contracts from £22 per month, or for £200 on pay-as-you-go (in-store only). It’s by far the most expensive pay-as-you-go handset EE offers, but then it’s the best-specced, too. The only device on contract worth mentioning that has an identical monthly spend is the HTC One mini 2. It’s fair to say the Harrier bests it on paper, but I do have a soft spot for the One mini 2, as its premium metal exterior is much easier on the eye.
The Harrier Mini is free on contracts from £17 per month, or £100 on pay-as-you-go. There isn’t much in terms of notable competition in the same price range, apart from EE’s own Kestrel. It, too, is £17 per month on contract, and only £50 on pay-as-you-go while stocks last. It might be older hardware, but given the performance issues I’ve experienced with the Harrier Mini, I’d argue the Kestrel is the more attractive option, especially on a pay-as-you-go tariff where it’s half the price.
O2, being the “premium” provider it is, doesn’t have much in the way of direct competition to either handset, apart from the HTC Desire 620, which is free on contracts from £16.50 per month. It’s better specced than the Harrier Mini in a couple of areas, has a funkier design and carries a well-known brand name that some consumers might take comfort in. Vodafone’s got a couple of handsets free on contracts from £22 per month that might give the Harrier something to worry about. Granted, they are getting on a bit, but Samsung’s Galaxy S4 and LG’s G2 were flagships of their time, and are both excellent phones despite their age.

Vodafone also has an own-brand handset that goes toe to toe with the Harrier Mini. The recently released Smart prime 6 is almost identical to the Harrier Mini apart from having a larger, 5-inch screen, and it’s also free on contracts from £17 per month. It’s only £79 on pay-as-you-go, however, so even if it does have the same performance issues as the Mini, you’ll be £20 better off.
Finally, Three doesn’t have any particularly compelling competitors in its pay-as-you-go lineup. On contract, though, it has the LG Spirit 4G free from £13 per month, and the Desire 620 free from £17 per month, both of which are eye-catching alternatives to the Harrier Mini. For £21 per month, you can also get a free, colourful iPhone 5c if you think you might prefer iOS over Android Lollipop.
Wrap-up

With last year’s Kestrel, EE delivered a phone with a great user experience and 4G connectivity at a reasonable price. The Harrier Mini might be the spiritual successor to the Kestrel, but it’s the bigger, higher-spec Harrier that’s better placed to carry on the Kestrel’s legacy. Its 13MP camera might not be the best around; it’s more laden with bloatware than it should be; and small hands might struggle with its… healthy dimensions. But, it’s packing a great full HD display, all the processing power you realistically need, and long battery life to get you through those busy days. More importantly, it’s competitively priced.
The Harrier Mini shares a few of these traits. It, too, sports a solid panel (with a slightly lower 720p resolution), and is no slouch in terms of battery endurance. Its 8MP camera is verging on terrible, however; you don’t have a great deal of storage to work with; and performance can be frustratingly sluggish. Furthermore, there are plenty of viable alternatives in the same price range or below. I’d even consider the Kestrel a better option at this point, which is pretty much all you need to know about the Harrier Mini.
Filed under: Cellphones, Mobile
PSA: Some users report that Google Now reminders don’t work

A batch of overcooked pasta is a small inconvenience, but when Google Now users rely on reminders to take their medication, pay bills, or get to the next appointment, bugs can become a cause of major headache.
According to several Reddit users, the reminder functionality of Google Now is currently broken. The app sets the reminder successfully, but the reminder popup doesn’t fire off at the set time as it should. As you can imagine, that can lead to all sorts of nuisances.
Reddit users Sloth_on_meth first reported the issue and screen capped it in this short video.
Several users in the thread have confirmed the issue; we were able to replicate the issue on a Nexus 5 with the latest version of the Google app, but not on other devices.
It’s not the first time we see issues with the reminder function not working. Before, however, trying to set a reminder returned an error message. Now the issue is more troublesome, because users are not alerted that the feature is disabled.
Sony to hold Taiwan/Hong Kong press conference for its “new Xperia flagship”

A number of Asian media sites are reporting that Sony will be holding a launch event for its new Xperia flagship in Hong Kong and Taiwan next week, along with a range of other devices for Asian markets.
Sony has a number of press events scheduled in Eastern markets during next week. For starters, the company will be jetting off to New Delhi, India on May 26th. Here Sony is expected to launch the waterproof Xperia M4 Aqua in the country and possibly a second handset as well. The following day, a press conference for the regional launch the Xperia C4, Z4 Tablet and Z3 Plus will reportedly take place in Taiwan.

Moving on to Thursday 28th, another event is set to be held in Hong Kong. Invites have already begun to circulate and make reference to a “new Xperia flagship”. The invite is touting top of the line camera, screen, sound, design, and water features “all rolled into one”.
Sony will be sending four product development engineers from Japan out to the event in Hong Kong to talk about the new design, but it’s not clear how much of a change, if any, this handset will present from the Xperia Z4 that launched exclusively in Japan last month. Reports appearing right after the launch of the Xperia Z4 suggested that Sony may be preparing a second high-end smartphone for other markets at the end of May, but we’ll have to wait and see.
Sony certainly has a busy schedule next week. What do you think or hope that the company is up to?
This is the limited edition Iron Man Galaxy S6 Edge coming next week

In a new teaser Samsung is giving us the first look at the red-and-gold Iron Man limited edition of the Galaxy S6 Edge.
Samsung’s marketing deal with Marvel has so far spawned consistent product placement in Avengers: Age of Ultron, several Avengers themes in the Galaxy S6 store, and, of course, a range of Avengers-themed accessories for Samsung’s top devices. But the highlight of this marketing extravaganza is the Iron Man edition of the S6 Edge, which looks like something Tony Stark would approve and use.
The image above was teased by Samsung Korea earlier today; the Iron Man S6 Edge appears to feature a vibrant red and gold finish, complete with a totally unsubtle depiction of the titular superhero.
One of the hashtags accompanying the picture translates to “1000 limited edition,” so it’s very likely that the Iron Man Galaxy S6 Edge won’t be a mass product. Then again, if demand is high enough, we wouldn’t be surprised if Samsung doubled down on the idea and even brought more Avenger editions of the S6 Edge. More details next week.
Android M might have its own fingerprint login system
Android is getting a TouchID-style system of its own with Android M, according to Buzzfeed‘s sources. Apparently it’ll act a lot like the iOS tool too, bypassing passwords for associated apps in favor of reading your fingerprint. Given that I/O is practically right around the corner (next week!) it shouldn’t be long before this all gets confirmed — Google hasn’t responded to our request for comment just yet.
[Image credit: Getty Images]
Filed under: Cellphones, Software, Mobile, Google
Source: Buzzfeed
Pebble Time units to start shipping out on May 27
Makers of the popular Pebble wearable announced the new Pebble Time smartwatch in February this year via Kickstarter. After reaching its $20 million funding goal in no time, the company had promised to start shipping out products by May.
The company is now sticking to its promise and has announced that the first units of the smartwatch will start shipping out starting May 27, which is next Wednesday. Given the pace of production, units that were pre-ordered by the company have already been produced by the company, so there shouldn’t be any delays.
Although the first shipments will start next Wednesday, this doesn’t mean that all users will be lucky enough to get their hands on it right away. Some might have to wait until mid-June to get their Pebble Time, but that’s not long from now, so it’s not particularly bad news.
Despite the arrival of several Android Wear smartwatches as well as the Apple Watch, the Pebble Time has managed to garner enough interest among fans, which speaks volumes about the company and its popularity.
Source: Kickstarter
Via: Phone Arena
Come comment on this article: Pebble Time units to start shipping out on May 27
Pebble Time units to start shipping out on May 27
Makers of the popular Pebble wearable announced the new Pebble Time smartwatch in February this year via Kickstarter. After reaching its $20 million funding goal in no time, the company had promised to start shipping out products by May.
The company is now sticking to its promise and has announced that the first units of the smartwatch will start shipping out starting May 27, which is next Wednesday. Given the pace of production, units that were pre-ordered by the company have already been produced by the company, so there shouldn’t be any delays.
Although the first shipments will start next Wednesday, this doesn’t mean that all users will be lucky enough to get their hands on it right away. Some might have to wait until mid-June to get their Pebble Time, but that’s not long from now, so it’s not particularly bad news.
Despite the arrival of several Android Wear smartwatches as well as the Apple Watch, the Pebble Time has managed to garner enough interest among fans, which speaks volumes about the company and its popularity.
Source: Kickstarter
Via: Phone Arena
Come comment on this article: Pebble Time units to start shipping out on May 27
Google makes a Hangouts Mac app you’ll want to use
Listen up, OSX users: with the new Hangouts update from Google you might actually want to use the official app rather than Adium. It consolidates your contacts on the left side of one window and puts your chats on the right as you’ll see below. It’s pretty simple and intuitive and is rocking Mountain View’s Material Design style, and frankly the simplification feels a bit overdue. Google’s Mayur Kamat writes that you can take advantage of the new features on Chrome OS, Linux and Windows too but you’ll have to disable “transparent mode” first.

Source: Mayur Kamat (Google+)
How to code a simple Android widget

App widgets can be thought of as a small window or controller for an Android app that can be embedded in another application (like the homescreen). They can be very useful, allowing users to view or control an app without actually launching it. For example, skipping tracks with a music player widget, or viewing weather information. The great thing about widgets is that they can be updated automatically (after a time period), or in response to user action.
In this developer tutorial, we are going to create a simple Android widget, that updates automatically every 30 minutes, or in response to the user tapping the update button on the widget. Our widget generates and displays a random number on every update (whether automatic or due to user interaction).
To create a widget requires four steps:
- Design the widget layout. At the very least, you will need one layout file describing your widget layout. However, you can also provide additional layout files for
- The widget before it receives any data.
- The widget on a lockscreen (Android 4.0 and above).
- The widget on a lockscreen before it receives any data (Android 4.0 and above).
- Extend AppWidgetProvider. This class provides methods that are called during a widget lifecycle.
- Provide the AppWidgetProviderInfo metadata. Essential information about the widget, such as minimum width and height, update frequency, and more.
- Add the widget to your application manifest.
1. Design the Widget layout
The first thing we do is design our widget layout. While laying out an app widget is similar to laying out an activity and/or fragment, there is a very important factor to note. App Widget layouts are based on RemoteViews layouts. This means that not all View subclasses can be used in a widget. In fact, the only supported classes are FrameLayout, LinearLayout, RelativeLayout, GridLayout, AnalogClock, Button, Chronometer, ImageButton, ImageView, ProgressBar, TextView, ViewFlipper, ListView, GridView, StackView and AdapterViewFlipper. Subclasses and descendants of these are not even supported.
With this in mind, we design our widget layout, named simple_widget.xml
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="@dimen/widget_margin"
android:background="#55000000">
<ImageView
android:id="@+id/imageView"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:src="@drawable/aa"/>
<TextView
android:id="@+id/textView"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:text="000"
android:textSize="@dimen/abc_text_size_large_material"
android:textStyle="bold"/>
<Button
android:id="@+id/actionButton"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:text="Refresh"/>
</LinearLayout>
Note android:padding in the above code snippet. From Android 4.0, app widgets automatically get a padding between the widget frame and the widget bounds. Pre-4.0 devices however do not provide the automatic padding for widgets. To build a widget that has margins for earlier versions, but no additional margins for 4.0 and above, create two dimension resources res/values/dimens.xml and res/values-v14/dimens.xml to provide different values for widget margin, and set your targetSdkVersion to 14.
res/values/dimens.xml
<resources>
<dimen name="widget_margin">8dp</dimen>
</resources>
res/values-v14/dimes.xml
<resources>
<dimen name="widget_margin">0dp</dimen>
</resources>
Extending AppWidgetProvider
Now extend AppWidgetProvider, by creating the class SimpleWidgetProvider. AppWidgetProvider has methods that are called when the app widget is updated, deleted, enabled and disabled among others. For our implementation, we only override onUpdate(), because it is the method called whenever the widget is added to a host.
public class SimpleWidgetProvider extends AppWidgetProvider
@Override
public void onUpdate(Context context, AppWidgetManager appWidgetManager, int[] appWidgetIds)
final int count = appWidgetIds.length;
for (int i = 0; i < count; i++)
int widgetId = appWidgetIds[i];
String number = String.format("%03d", (new Random().nextInt(900) + 100));
RemoteViews remoteViews = new RemoteViews(context.getPackageName(),
R.layout.simple_widget);
remoteViews.setTextViewText(R.id.textView, number);
Intent intent = new Intent(context, SimpleWidgetProvider.class);
intent.setAction(AppWidgetManager.ACTION_APPWIDGET_UPDATE);
intent.putExtra(AppWidgetManager.EXTRA_APPWIDGET_IDS, appWidgetIds);
PendingIntent pendingIntent = PendingIntent.getBroadcast(context,
0, intent, PendingIntent.FLAG_UPDATE_CURRENT);
remoteViews.setOnClickPendingIntent(R.id.actionButton, pendingIntent);
appWidgetManager.updateAppWidget(widgetId, remoteViews);
In the onUpdate() method above, we iterate through all of our widgets (in case the user has placed multiple widgets), get a RemoteViews object, update the RemoteView’s textview with a new random number between 100 and 999, and then specify the action that should occur when the Button is tapped.
To request a manual update when the update button is clicked, we use a PendingIntent. The action for the Intent is set to AppWidgetManager.ACTION_APPWIDGET_UPDATE. This is the same action sent by the system when the widget needs to be updated automatically. We also indicate the widgets that should be updated (all of the app widgets) by calling
intent.putExtra(AppWidgetManager.EXTRA_APPWIDGET_IDS, appWidgetIds).
To update the current widget only, you can call
intent.putExtra(AppWidgetManager.EXTRA_APPWIDGET_ID, widgetId);
Finally, we request the AppWidgetManager object to update the app widget, giving it the current widgetId and the current RemoteViews object.
Providing AppWidgetProviderInfo metadata
This is an xml file that defines additional information, features and data related to the widget. Data such as minimum layout dimensions (width and height), if the widget should be available on the lock screen (Android 4.2 and above), how frequently the widget should be updated, among many others. We define an xml file, called simple_widget_info.xml, and saved in the res/xml folder.
<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
android:minWidth="120dp"
android:minHeight="60dp"
android:updatePeriodMillis="1800000"
android:initialLayout="@layout/simple_widget"
android:resizeMode="horizontal|vertical"
android:widgetCategory="home_screen|keyguard"
android:previewImage="@drawable/preview">
</appwidget-provider>
Most of the attributes have pretty self explanatory names. minWidth and minHeight specify the minimum width and height the widget can have. updatePeriodMillis specifies the update frequency in milliseconds for the widget. Note that frequent updates will significantly affect users battery. Take note of the widgetCategory attribute. This specifies if your widget can be available on the lock screen as well as on the home screen. All widgets are available on the home screen by default, and if not specified. Android 4.2 included the keyguard option, indicating that the widget can be added to the lock screen.
If your widget is displayed on a lock screen, you might want to show different data, or a different layout. To detect if the widget is on a lock screen, you request the widget options using AppWidgetManager’s getWidgetOptions(int widgetId) method. This method returns a bundle, which can be queried for the AppWidgetManager.OPTION_APPWIDGET_HOST_CATEGORY int. This will either be a WIDGET_CATEGORY_HOME_SCREEN or WIDGET_CATEGORY_KEYGUARD.
The sample code below checks for the AppWidgetHost, and displays a different layout for each host type.
AppWidgetManager appWidgetManager; int widgetId; Bundle myOptions = appWidgetManager.getAppWidgetOptions (widgetId); // Get the value of OPTION_APPWIDGET_HOST_CATEGORY int category = myOptions.getInt(AppWidgetManager.OPTION_APPWIDGET_HOST_CATEGORY, -1); // If the value is WIDGET_CATEGORY_KEYGUARD, it's a lockscreen widget boolean isKeyguard = category == AppWidgetProviderInfo.WIDGET_CATEGORY_KEYGUARD; int baseLayout = isKeyguard ? R.layout.keyguard_widget_layout : R.layout.widget_layout;
Declare Widget in the Application Manifest
The final step is to add the app widget to the application manifest. Within the <application> </application> element tags, add the following
<receiver android:name="SimpleWidgetProvider" >
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
</intent-filter>
<meta-data android:name="android.appwidget.provider"
android:resource="@xml/simple_widget_info" />
</receiver>
Don’t forget to change the receiver android:name to your AppWidgetProvider implementation, an the meta-data android:resource to your AppWidgetProviderInfo xml file. At this point, you should be able to run your application, and place your widget on either the home screen or lock screen.

Tapping on the update button should automatically update all your widgets. Can you modify your code to only update the widget that was tapped? How about updating only one random widget on tap? Have fun with this, but remember that a widget that updates frequently will be a drain on the battery.
As usual, the complete code is available for modification and reuse to your hearts content on github.
HTC Mail app reaches the Play Store for better future updates
HTC’s stock mail application has now made its way to the Google Play Store, making it easier for the company to update it whenever necessary. This follows a long list of HTC apps such as BlinkFeed, Gallery etc that are already available in the Play Store.
In the past, HTC had to update the entire system to bring changes to these applications. But by making them separate from the system, the company can ensure that updates are sent in periodically even though the system isn’t updated.
The Mail app is compatible with a wide range of Sense UI running smartphones (Android 5.0 or higher) and is exclusive to HTC devices.
Come comment on this article: HTC Mail app reaches the Play Store for better future updates













