Showing posts with label Google Play. Show all posts
Showing posts with label Google Play. Show all posts

24 August, 2017

Minimize An App to System Tray

24-Aug-2017


I am writing a small WinForms program, and I thought of including minimize an app to system tray feature. Since this is the first time I will do this, I just did a search in Google. I am very sure many have done it as it already is a common feature.

Well, common for everybody else, but at this point, not me. Not yet.

Thus, I searched for ‘minimize an app to system tray’, and I did find valuable articles, many in Q&A forums, like StackOverflow.com.

I’ll go directly to the point now. What is required to make it happen?

1. Handle the form’s resize event.
2. Make a NotifyIcon click event restore the form back.

Here’s how it’s done.


Handle the Form’s Resize Event

Select the form and on its Events, declare this:

private void MyForm_Resize(object sender, EventArgs e) {
    if (FormWindowState.Minimized == this.WindowState) {
       myNotifyIcon.Visible = true;
       myNotifyIcon.ShowBalloonTip(500);
       this.Hide();
    }
    else if (FormWindowState.Normal == this.WindowState) {
       myNotifyIcon.Visible = false;
    }
}


Make a NotifyIcon Click Event Restore the Form Back

Add a NotifyIcon tool, and on its click event, declare this:

private void myNotifyIcon_Click(object sender, EventArgs e) {
    this.Show();
    this.WindowState = FormWindowState.Normal;
}


This is all that is required, really. But sometimes it doesn’t work. One small trick is needed.

Add an Icon to the NotifyIcon tool.

myNotifyIcon.Icon = SystemIcons.Application;

Also, you can add in the Text and Tip properties:

myNotifyIcon.BalloonTipText = "App is minimized to System Tray.";

myNotifyIcon.BalloonTipTitle = "My App Name";


Sometimes, you will see articles that suggest using the Form’s Visible property. But this is also known to still make the app appear or selectable (although not visible) when you do Alt + Tab. So stick to Hide() and Show() events. Still your choice, though.

Okay. I’ll stop here, cause that’s all that is really needed to minimize an app to system tray. Easy, right?

Happy coding!

01 February, 2015

Android 5.0 in my Samsung Galaxy Note II (N7105)

The official online color is: #A4C639 . 한국어: 공...
The official online color is: #A4C639 . 한국어: 공식 온라인 색은: #A4C639 . (Photo credit: Wikipedia)
01-Feb-2015



Today seems a good day to write about this article... before it is forgotten...

A year or so after I flashed Android 4.4.2 ROM in my GT-N7105 phone, I started looking for some update to the OS. I believe there was one or two upgrades in the past year, and since I am getting none when I checked using my phone, I searched from the web using my PC.

Found that there is the UNOFFICIAL release for Android 5.0 - Lolllipop code name.

Read through the posts, and the found the installers. Saw that GApps is also available, so what am I waiting for?

I mean, I am more of the curious type, than the cautious one...

I went to the download sites, took the ROM and GApps files, and the supposeldy CWM recovery file that goes along with this Android 5.0 version.

It was a breeze!

But not before I had to check on how to do things altogether, I mean, after a year without actually doing it, just updates.

Which means my phone had rested for some time.

I like the new OS. Grouping of apps is naturally a function. And I found that this is already taken out from the 'All Apps' view. You cannot uninstall anymore from there. So you would have to open the apps group, and if you tap-hold, you get to drag it up to 'Uninstall' or 'Homescreen' - and it does just what you chooses. OF course, system apps would tell you that you can't do an unistallation.

Notifications also get the clear all button (is that what it is called in Android?) and you do double-tap to an item in the list to open it.

I also installed CM Launcher, after so long using Go Launcher EX. With CM Launcher, I installed Battery Doctor, to replace Green Power apps. I like CM Launcher in its simplicity. I like Battery Doctor in its verboseness of info. Charged will tell me if it is fully charged, and when it is in trickle mode, a few minutes after full charging. And when done, totally, will tell you to unplug.

For the curious one like me, here are the links:



Rooting:

Lollipop ROM:

Lollipop GApps:

Installing Custom ROM:



Odin v3.04 – 3.07 for Windows



Salute to the team for getting ahead of the rest!

28 March, 2013

GT-9103: SD Card Is Damaged!

Image representing Android as depicted in Crun...
Image via CrunchBase
28-Mar-13


I have a few items to write on, but I believe this one is quite urgent.

Two weeks ago, I sort of “tampered” once again my already-quiet Samsung Galaxy R. I searched for the latest Android custom ROM, which is 4.2.2. I found the one that is offered by Paranoid Android. I actually managed to flash that one properly, both the kernel and the Google Apps. These are the files: i9103-3.00-16FEB2013-192725.zip and gapps-full-4.2-20130308.zip. These are coming from Paranoid Android.

Of course, things don’t end there.

When I was installing those root apps, I came to the SuperUser app, and to my mistake, I selected the wrong option, when I was offered something like “usually for HTC phone”, and that broke my phone’s SD card.

A lot of apps don’t work after that: Camera, Wallpaper Changer, etc. I found that many things are so much dependent on the internal SD card. Anyway, I already have the other phone, my GT-I3100, so the impact isn’t that much.

Still, I can’t rest assured. I’m not convinced that nothing can be done with the “broken” SD card. Nonetheless, I am one step short of bringing that old phone, although unused, to Samsung Service Center.

I did try and try and try to re-flash the ROM, so that by any chance, re-installing SuperUser app, if I tap the ‘correct’ button, the SD card may get fixed all by itself.

Furthermore, within the last week, I noticed that my phone is showing some “inversion” in the display, like the upper diagonal half (top left to bottom right) getting inverted. The time showing 10:50 is upside down. Imagine that!

Bad becoming worse. Really no fix, I thought. I searched the web for help on the ‘Damaged SD Card’, and although it was consistently mentioned in the articles that I found not to do format, I still tapped on the ‘Format’ button in the suggested fix by the apps that identified the SD card as damaged. I was wondering, the one who developed the App isn’t the one who wrote the articles…?

Then my insatiable curiosity got me.

I said, there could be something offered by CM, the same 4.2.2 kernel, for my GT-i9103. So yesterday, I searched the web. Something came up. There were 2, actually. There was the kernel alone, cm-10-20121223-UNOFFICIAL-i9103.zip, and the pair: I9103DXLP6_I9103OLBLP6_XSP.zip and gapps-jb-20121011-signed.zip. Looking at the dates, I said, these are earlier released than the one from Paranoid Android. So I was asking myself, “Why didn’t I see these first?”

Anyway, I went to download the files, not knowing whether I should do flash using the standalone kernel, or the pair.

I decided to use the pair, but to be sure, in case something doesn’t work, I also copied the standalone zip file. True enough, there was an error thrown out with the pair, the main zip file. I proceeded to install the Google Apps from the zip file despite the fact that the main file didn’t install properly, and then after reboot, the phone was in a boot loop.

I now tried to install the standalone file, and it worked! Still, first reboot resulted to a boot loop.

I did another flash, and this time, using the standalone kernel file, and this went through without a problem, and the reboot also went through nicely, and when the phone came up, I entered all the necessary credentials, and the apps were installed back automatically.

But Play Store app was missing, and though I can search and “install” it using the browser, the app doesn’t show in the Apps list. It is nowhere to be found. So I thought, can I bring it up using the other half of the pair, just the Google Apps file?

And that I did. I flashed the GApps file, and after reboot, the Google Apps were in.

And guess what? The main reason for my posting this article is to say that after flashing the CM 4.2.2 kernel for my GT-i9103, the SD Card came back to life!

Also, the other reason why I would be more comfortable running CM codes is that there is a regular update, which I download and install now and then, sometimes every night (NIGHTLY builds). That is what I do with the GT-P3100 phone.

So now I have a CM custom Android 4.2.2 ROM running, with the Google Apps in, and the SD Card fully functional once again!

Hope this short post will be of help to somebody as well.

Till then!
Enhanced by Zemanta