/    Sign up×
Community /Pin to ProfileBookmark

java command to minimize window?

I am trying to figure a way to make a button that when clicked will minimize the current window. Is there a javascript command that will do this?

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@GollumMay 14.2003 — I'm pretty sure there isn't one. The reason being to prevent security attacks using code running in windows hidden to the user.

The best you can do is call window.blur() which will on some platforms send the window to the bottom of the window stack.
Copy linkTweet thisAlerts:
@SniperXMay 14.2003 — You could resize the window into a small block though.

i.e. at the bottom of the screen
Copy linkTweet thisAlerts:
@boroarkeMay 15.2003 — What would the javascript be to do that? I am a newbie and need some help.

Thanks!!
Copy linkTweet thisAlerts:
@havikMay 16.2003 — To resize the window:

window.resizeTo(Width, Height)

to move the window:

window.moveTo(x, y)

Havik
×

Success!

Help @shawjames spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.20,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...