foreground

iPhone iOS 4: how do you go from background to foreground in objective-c

Hi, I am trying to make my application that is in the background come to the foreground after a call is disconnected. Here is the code: if([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"tel:0123456789"]]){ [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:0123456789"]]; } else { // Could no...

How to run an application with the foreground privilege on windows?

I have a python program that is controlled via a web interface on localhost. This program needs to start applications and bring them to foreground - which is easy (using AttachThreadInput / SetForegroundWindow) until the app in question requires an UAC dialog. Since I cannot use the AttachThreadInput/SetForegroundWindow trick on the UA...

Silverlight 4 Foreground ColorAnimation

I am trying to animate the Foreground color of a hyperlinkbutton when the user MouseOver the control. I created a custom style in which I want to animate the Foreground color. The Foreground color is set like so <Setter Property="Foreground" Value="#FF73A9D8"/> In the visualStateManager section I have the following element for the Co...

load iPhone background app in the same state as the first time

In ios4, when you quit your iphone application with the homebutton, it goes to the background. the second time you enter your app (foreground) I wanna be able to load the app like the first time (ViewDidAppear) and not in the state that I left it. ...

Adding Color to Font's attributes java swing

I tried to add Color to java.awt.Font's attributes like this: font.getAttributes().put(TextAttribute.FOREGROUND, jColorChooser.getColor()); But I get the error The method put(TextAttribute, capture#12-of ?) in the type Map is not applicable for the arguments (TextAttribute, Color) The Font API says This Font only r...

How to be notified when foreground (top) activity (application) changes

I want to write a service for Android platform that is notified when the current foreground activity changes. Basically the service should do some tasks only when the top activity changes. Is there any way to subscribe and to be notified when this kind of event occurs ? Or there is no possibility and the service should poll from time t...

How to restore last values of listview and other views after coming app from foreground ?

When i click home button and then come back to to my application it doesn't show the last values on the listview or any other view it just look same with when i started the application.I believe it is can be done with onResume and onPause but i couldn't find how . ...

Foreground Vs Active window

In Windows, what is the difference between foreground and active window? To be specific, under what circumstances can a foreground window not be an active window? If the 2 terms are referring to the same concept why there're 2 terms. The msdn documentation here mentions "clicking a window, or by using the ALT+TAB or ALT+ESC key comb...

Changing the forecolor and backcolor of text in a textbox

I'm making a C++ code editor application using VB.NET. I'd like to change the color of the keywords as the user types it. Also I'm looking for a way to highlight some lines of the code. Is there a way to change the forecolor and backcolour of a piece of text inside a textbox? ...

Close foreground thread gracefully on windows service stop

In my windows service I create one "parent" foreground thread that in turn spawns "child" threads using ThreadPool (which means they are background) to execute tasks. What is the best way to close foreground thread gracefully on windows service stop? Here is my current implementation (stripped out of task-specific logic): public parti...

iOS 4.x bring app from background to foreground using private api

Hi All, In my app, I am placing a phone call due to which my app goes in background and suspended. After disconnecting the call instead of my app coming in foreground, native phone app comes into foreground. Is there any way by which my app comes into foreground (instead of native phone app) after disconnecting the call. If there is ...