• 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: Enabling add button
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Enabling add button


  • Subject: Re: Enabling add button
  • From: "I. Savant" <email@hidden>
  • Date: Thu, 18 Dec 2008 15:10:34 -0500

On Thu, Dec 18, 2008 at 2:52 PM, Andre Masse <email@hidden> wrote:

> Let me explain a bit more. This is an in house application for only 3 people
> (me, my wife and my son) that was originally built with 4th Dimension. I
> agree that this is not the expected behavior for mac users but it is for
> mine, as this is the way automatic buttons are handled in 4D. I'm willing to
> make this more "mac like" but I want to prevent something like this:
>
> 1- user select a row in the master table view,
> 2- press the button's shortcut (intentionally or not)
> 3- a row is added to the detail's table view but since it does not have the
> focus, the row selection's is grayed and its not that evident that an
> operation has occurred. Further more, to edit the new row, the user will
> have to move the focus to the table view by clicking on it...

  I see ... I can't really suggest anything more than what you'd
mentioned if you're using bindings for the detail view (subclassing
and overriding). Well, except maybe binding the button to a
KVC/KVO-compliant "state" property somewhere else in your app that
returns true if the table's window's first responder is the desired
table ...

  I see the problem you're referring to, though, in a keyboard-driven
environment, but this is a difficult problem to solve without causing
other problems (ie, unexpected UI behavior). It's almost the classic
"more security == less convenience" scenario. In this case "security"
refers to that of your data integrity. :-)

> A typical use case is something like this:
>
> 1- do a query to find a client by name
> 2- user either add a client or modify one by adding rows in the detail's
> table view
> repeat...
>
> The master table view use a datasource (no bindings).
>

  Perhaps all your tables should use a datasource (and delegate). This
way your add button can call a method that directly checks the
responder status, then if everything is okay, adds the object, reloads
the table's data (so the object is available immediately - not
possible using Bindings), then call the table's
-editColumn:row:withEvent:select: method to make the table ready to
edit.

--
I.S.
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Enabling add button
      • From: Andre Masse <email@hidden>
References: 
 >Enabling add button (From: Andre Masse <email@hidden>)
 >Re: Enabling add button (From: "I. Savant" <email@hidden>)
 >Re: Enabling add button (From: Andre Masse <email@hidden>)

  • Prev by Date: Re: Preventing Automatic Gzip Decompression with NSURLConnection?
  • Next by Date: Re: Enabling add button
  • Previous by thread: Re: Enabling add button
  • Next by thread: Re: Enabling add button
  • Index(es):
    • Date
    • Thread