• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: does windowDidClose or not?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: does windowDidClose or not?


  • Subject: Re: does windowDidClose or not?
  • From: William Bumgarner <email@hidden>
  • Date: Mon, 17 Apr 2006 08:23:43 -0700

On Apr 17, 2006, at 6:36 AM, Finlay Dobbie wrote:
On 17/04/06, Ben Dougall <email@hidden> wrote:
yes but a window closing and a window deallocating are two different
things -- you can still easily have a working pointer to the window
once it's closed i think.

It's possible but not necessarily the case. Windows can be set to release themselves when closed, which may cause them to be dellocated.

Might there be a better way to implement the user interaction?

Having a commit-on-close behavior implies that validation isn't going to happen or, if it does, the window that the user just closed isn't actually going to close. If the user hits cmd-w to close the window, the window really should close (unless there are unsaved changes).

Some suggestions:

- changes should be applied as the user enters them. This allows validation on the fly and would give the user immediate feedback as to how their changes are applied to the underlying application. Commonly used in inspectors and preferences windows.

- changes should be committed on a specific action. The user might hit an "OK" button to cause the changes to be committed. If the changes validate, the window can close. A little bit odd for a standalone window; you would typically see something like this in a sheet or other modal UI.

- use a document like window such that the close button dirties as changes are made and the user uses "save" (cmd-s) to commit the changes. Really only makes sense for proper document based data/ windows.

b.bum
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: does windowDidClose or not?
      • From: Ondra Cada <email@hidden>
References: 
 >Re: does windowDidClose or not? (From: Uli Kusterer <email@hidden>)
 >Re: does windowDidClose or not? (From: Ben Dougall <email@hidden>)
 >Re: does windowDidClose or not? (From: "Finlay Dobbie" <email@hidden>)

  • Prev by Date: Adding bindings to a custom view - "simple" implementation
  • Next by Date: Re: Setting a custom NSImageCell
  • Previous by thread: Re: does windowDidClose or not?
  • Next by thread: Re: does windowDidClose or not?
  • Index(es):
    • Date
    • Thread