Flex :: Detect Whether A Window Is Hidden (cmd-h) Vs Closed (cmd-w) - Mac

Feb 4, 2010

I'm developing an AIR application which uses multiple windows. I'm running into an issue where I want to open new windows (toaster notifications for example) when the primary application window is not visible, but the behavior is different depending on how the window is closed.

When a user hides all application windows with CMD-H, opening a new window causes all application windows to come back to the foreground (instead of just that new window, like I would expect). If the user closed a window with CMD-W, however, that window does not become visible when I open a new window.

Is there a way to either 1) tell when the user uses cmd-h to hide all windows OR 2) tell whether a window is hidden using cmd-h vs. closed cmd-w?

View 2 Replies


Similar Posts:


Flex :: Detect When The Security Panel Has Been Closed?

Oct 11, 2010

Is there a way to detect this in Flash?

View 1 Replies

Flex :: Determine If A PopUpManager Window Is Open (or When It Has Closed)?

Sep 6, 2011

In Flex (Flash Builder 4) I am opening a new window via PopUpManager.addPopUp. I have timer code that runs in my component and I need to stop my timer when that window opens and start the timer again when the window closes.

I figure it's easy enough to stop the timer in the function that opens the window, but how can I start the timer again when the window closes?

Is there a way to tell if there is a pop-up window in front of my component, or if a specific pop-up window is still open via PopUpManager?

View 2 Replies

Windows :: Flex - Adobe Air Start Native Window Hidden?

Feb 16, 2011

How do I open a new window as hidden? (note the visible="false")

<s:Window xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
showStatusBar="false"
resizable="false"
visible="false">

If I declare a window this way, and then call this.open(false);, the window will quickly open and then hide, and then be reshown when I actually display it, I want to do this to be able to load content and fit the window to that size before showing it.

View 1 Replies

Flex :: Adobe Air: Drag Application Crash - Error #3200: Cannot Perform Operation On Closed Window

Nov 23, 2009

Now I set dragEnabled="true", dropEnabled="true" and dragMoveEnabled="true" to archive the ability to reorder my Items via Drag and Drop. But as soon as I start to Drag an Item the whole Application crashes with:

[Code]....

View 1 Replies

Actionscript 3 :: Detect Clicks Outside Of A Window For A Multi-window AIR App In Flex?

Mar 13, 2011

So I have this AIR app coded in flex where I have several floating native windows and what I want is to detect when a user clicks outside of a window so that I can close it. (I don't want to use the PopupManager Class and would want to use the native windows).

My question is, is there a way to detect a click outside of a spark window, or alternativley is there some root container/object which is a parent to all the native windows so that a click inside any native window would bubble up to it? (Apparently the stage object of the root windowed application is not that object since each window is not a child of the stage for the root application).

View 1 Replies

Flash - How To Detect When SWF Is Closed In AS2

Jul 2, 2011

Is there a script in AS2 that will call a function when the SWF is closed? I found solutions, but they're all in AS3.

View 1 Replies

ActionScript 3.0 :: Execute A Function When Window Is Closed?

Feb 7, 2010

I was wondering if you can make an eventlistener to trigger to execute a function when the window/tab viewing the swf is closed. I searched around, and there seems to be a way to do this with flash.external class and javascript, but some users have javascript disabled, so is there a way to achieve this without javascript?

View 3 Replies

ActionScript 1/2 :: Trigger A Function When The Popup Window Closed?

Aug 27, 2009

using the javascript window.open() and getURL() i am opening a popup from flash. I want to call some flash function when i close that popup window.

View 3 Replies

ActionScript 3.0 :: Keep Getting Error 1009 Until SWF Movie Window Closed?

May 28, 2010

I have created a simple slideshow of thirteen frames. The slideshow script starts at Frame 2. This is because I have inserted a preloader in Frame 1. When I output my SWF and upload it to the web, it pulls down without incident. However, when I "Simulate Download" locally, Flash says this in the Output window:

TypeError: Error #1009: Cannot access a property or method of a null object reference.
at AS3GallerywPreloader_fla::MainTimeline/updatePreloader()
[AS3GallerywPreloader_fla.MainTimeline::frame1:9]
And it keeps writing this error message, ad infinitum, until I close the SWF movie window!

Here is the preloader script:
stop();
loaderInfo.addEventListener (ProgressEvent.PROGRESS, updatePreloader);
function updatePreloader (evtObj: ProgressEvent): void{
var percent:Number = Math.floor((evtObj.bytesLoaded*100) /evtObj.bytesTotal);
preloader_txt.text = percent+"%";
if (percent==100) {
nextFrame ();
}}

I should note that the slideshow portion functions as it should (the Back and Forward buttons advance frame by frame). In essence, the whole movie works. But I suspect I that error code is a bad thing to have. I ran the "Debug" feature (Debug-->Debug Movie), but got no apparent indication of a bad line of code.

View 6 Replies

ActionScript 2.0 :: Detecting Flash/html Window Closed?

Jan 9, 2007

is it possible for flash to detect when a user closes an html window with a swf embeded in it?

I want to record a user session time and need to be able to call a function and serverside script from within flash when a user closes the window...is there a way?

(I thought I might be able to do it with onUnload, but that will only work for unloading movieclips, not closing the main swf.)

View 1 Replies

ActionScript 3.0 :: Create Alert Before Browser Window Is Closed?

Jan 29, 2010

I have flash as a gui to edit some docs. I'd like to caution the user to save before they close the window (or navigate away from it).ut can it be done with a .swf ?I think this was asked awhile back in this forum but I cant seem to locate it.

View 2 Replies

Actionscript 3 :: Detect "hidden Files Extension" (windows System ) From Flash App?

Sep 3, 2010

i'm working on an app (flash/As3) that lets the user upload and edit an image, and then save it to the computer, using FileReference. it's posible to know if the user computer have the option "hidden file extensions" (windows system) selected? How can i do it?

View 3 Replies

ActionScript 2.0 :: Perform A "destructor" Like Action When Browser Window Is Closed?

Dec 4, 2003

I have a chat program built using flash for the front end tied to a J2EE back end. My program creates socket connections which must be closed appropriately when a user signs off.

When a user decides to sign off they can click the sign off button and everything is peachy. However, a less responsible user may choose to sign off by simply killing the browser window. Is there any way to implicitly call an actionscript routine on this event?

View 1 Replies

ActionScript 3.0 :: Call A Function Before The Flex App Is Closed?

Oct 10, 2010

I was wondering if flex has some events that can call before I close the whole application or close browser. Since I would like to send a httpservice to a php before the swf is closed. I tried this before:

<mx:Application xmlns:mx="" creationComplete="init()" remove="clearHistroy()">

But it didn't work.

View 1 Replies

Flex :: Open With Default Editor And Wait To Be Closed

Mar 25, 2011

we're developing an app that should be able to open specified file with default editor application. (so if it is .doc - it suppose to be opened by MSWord or openOffice)

But I also need to wait until user will close the editor, check if it was changed (by size and date), and upload it to the server.

So the following steps:

1) find def editor

2) open file

3) wait it be closed

4) do smth after that with the file.

now results of my research:
-> opening by def editor is simple: file.openWithDefaultApplication();

but there is no way to know that editor is closed (maybe by checking that file is not locked in timer???)

-> i can start the native process and pass file as parameter BUT looks like the code NativeApplication.nativeApplication.getDefaultApplication(file.extension); does not work for any extension :( - it doesnt work for "rtf", "doc" but works for "pdf"... and [file.openWithDefaultApplication()] works fine with any file!

View 2 Replies

Flex :: Make All The Popups Retain Their Functionality After The One Before Is Closed?

Aug 5, 2011

I have a for loop that I'm trying to display multiple popups with.

I seem to have multiple popups appearing on the screen, but after I'm done and close the top popup all the buttons on the others below it seem to stop functioning.

How can I make all the popups retain their functionality after the one before is closed?

Here's the code that I'm using to add the popups:

reminderadd = reminder_add(PopUpManager.createPopUp(this,reminder_add,true));
reminderadd.postpone_button.visible = true;
reminderadd.title.text = "Reminder - " + remindernum;
reminderadd["add_button"].addEventListener("click",reminderUpdate);
reminderadd["cancel_button"].addEventListener("click",reminderDismiss);
PopUpManager.centerPopUp(reminderadd);

View 1 Replies

ActionScript 3.0 :: Detect If Window Is Active

May 15, 2009

My site is a Portfolio of other flashwebsites. All have sound. Because it becomes confusing to have all sounds playing at the same time I am trying to do one thing. I need to know if there is a EventListener that detects if the site window is active. If it is not the volume will be zero, if it is the volume will be 1.

View 6 Replies

Flex :: Generate A Flex Image From A Hidden Component?

Jan 20, 2010

I'm trying to put an image, generated from some text, in a RichEditableText. Since it's a styled text, I thought about putting it another RichEditableText, style it, then print it to a Bitmap to use as source for InlineGraphicsElement.I use the following code to do that

var txt:RichEditableText = new RichEditableText();
txt.text = name;
// Appliy given styles to the text flow of input rich editable text

[code].....

View 2 Replies

Flash :: Detect Switch From Adobe Air App To Another Window

Jul 18, 2011

How can I determine if someone switch to another window (say notepad) while keeping air app open behind, I was looking for a way to detect if user switch form air app to another.

View 1 Replies

ActionScript 3.0 :: Detect If Mouse Is Outside Flash Window

Nov 5, 2010

I have a background which scroll's when the mouse is at the edge of the flash window - RTS style. If the mouse cursor goes outside the window I want it to stop scrolling, but flash reads the cursor position as the last place it was, when it was still within the flash window.I know I've done this before, but I can't at all remember how!Is there an event I can listen for or something similar?

View 4 Replies

Javascript :: To Execute Flex Cleanup Function When Browser Is Closed By User?

Oct 29, 2009

I have a Flex client application. I need a clean up function to run in Flex when the user closes the browser. I found the following solution on the net, but it only works half-way for me. How could I fix it?CustomEvent triggered, but not executed. >> EventHandler for CustomEvent.SEND_EVENTS is defined by a Mate EventMap. All the handler does is to call an HTTPServiceInvoker. In debug console, I'm able to see the handler and HTTPServiceInvoker being triggered, but neither the resultHandlers nor the faultHandlers were called. I know this event handler has no problem because when I dispatch the same CustomEvent.SEND_EVENTS in a button click handler, it behaves exactly as I expected)Browser seems to wait for cleanUp function to complete before it closes. (all traces were printed before browser closes down)

Code
I added the following into the index.template.html
window.onbeforeunload = clean_up;

[code].....

View 3 Replies

Flex :: Determine Where Selected Row Is Closed Or Open On ItemClick Event In AdvancedDataGrid

Sep 30, 2010

I have an AdvancedDataGrid with Hierarchical data in it. On itemClick I have to identify if the row I clicked is expanded or collapsed.

View 1 Replies

ActionScript 3.0 :: NetStream.Connect.Closed - Know Which NetStream Has Been Closed

Aug 2, 2010

A NetStatusEvent with info.code of "NetStream.Connect.Closed" is dispatched by NetConnection when a NetStream is closed. This seems kind of weird, shouldn't the NetStream dispatch the event? how do I know which NetStream has been closed if I have more than one running (which I do)? I need to know so I can cleanup the now dead stream.

View 1 Replies

Detect That The Flash Movie Projector Is Active Window?

Feb 4, 2011

How can detect that the flash movie projector is active window

View 1 Replies

ActionScript 2.0 :: Detect Browser Window Height Within Flash?

Apr 21, 2011

I have a flash website which has the following dimensions:

width = 100% of browser window
height = 1500px

What I'm trying to do is have a movie clip with the instance name of 'msie' vertically and horizontally centred to the middle of the browser window (not just the stage).

The current code I'm using is:
msie._x = Stage.width / 2;
msie._y = Stage.height / 2;

This correctly centres the movieclip to the width of the browser window but because the height of the stage is 1500px, it positions it at 750px from the top instead of being vertically centred in the browser window.

how I can get this to work. I feel like all I need to is replace the word 'Stage.' with something else in the code.

View 9 Replies

ActionScript 2.0 :: Detect Window Size, Scale Down If Needed?

Feb 14, 2012

I have a SWF that's 1100 x 730 (odd size, I know). What I want to do is detect the window size (not screen resolution). If the width of the window is less than 1100, scale the SWF to fit the window. If the width of the window is 1100 or higher, do nothing.

View 0 Replies

Flex :: Hidden Features Of MXML?

Apr 15, 2012

What are some of the hidden features of MXML? What existing features are not well known but very useful?MXML being used in Flex Framework became quite popular language because Flash Player is something every PC has and Flash Builder and Flash Catalist are quite popular Adobe programs.specify one feature per answer, and read all answers before posting a dupliate.It's not always a great idea to use these hidden features; often times they are surprising and confusing to others reading your code.

View 3 Replies

Flex :: <mx:List> Is Hidden By Other UI Component

Jul 18, 2010

In flex UI, my <mx:list> can not be shown completely because of other component shelterring (for example: the refresh button shelter part of it ). How can I make the <mx:list> in front of all other UI component.

This is my code:

<s:HGroup verticalAlign="middle">
<s:Label text="Choose Log File"/>
<mx:ComboBox id ="logFileChooseCombo" dataProvider="{fileNameList}" width="150" color="0x000000"

[Code]....

View 1 Replies

Flex :: Hidden Features Of Cairngorm?

Jul 22, 2010

I found a lot of interesting info in the 'hidden features of...' series. I am very new to cairngorm . What are some of the hidden features of cairngorm.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved