Re: Master - Detail: How to get back?

2015-04-16 Thread Kyle Sluder
On Thu, Apr 16, 2015, at 09:46 AM, Roland King wrote:
> 
> > On 16 Apr 2015, at 22:20, Gerriet M. Denkmann  wrote:
> > 
> >> 
> >> On 16 Apr 2015, at 13:41, Roland King  wrote:
> >> 
> >> 
> >>> 
> >>> 5. Run 
> >>> 
> >>> iPhone- tapping on "Do & Back" prints:
> >>> 2015-04-16 12:16:52.799 Dummi[28069:20737983] -[MasterViewController 
> >>> doSomethingAndBackToMaster:] did something with "2015-04-16 05:16:49 
> >>> +", will do: [ perform]
> >>> 
> >>> iPad  - tapping on "Do & Back" prints:
> >>> nothing. 
> >>> 
> >> 
> >> 
> >> What did you expect it to do on the iPad?
> > 
> > I expected it to print and then to ignore the segue, because as you say, it 
> > makes no sense on iPad.
> 
> Ah no - it would only have printed if the segue was run/actioned/whatever
> you do to a segue. That would only happen if the class implementing the
> exit segue had been located. Exit segue resolution is something a bit
> like the responder chain. In this case the class which implemented the
> segue isn’t in the chain of UIViewControllers on the iPad so it’s not
> found so it’s not run. 

This is more or less the correct explanation, but it's tricky, and
arguably not the desired behavior.

If Gerriet had implemented the unwind selector on a subclass of the
navigation controller rather than on the navigation controller's root
view controller, then the split view controller would have found it when
the segue runtime sent it -viewControllerForUnwindSegueAction:. But that
method only looks directly at the receiver's children.

> 
> Exit segues are documented however I’ve never found the documentation
> terribly clear, it does however tell you what methods are called in the
> search for an exit segue and how the search goes up the chain. 
> 

The most comprehensive documentation for how unwind segues work is
currently found in TT2298: Using Unwind Segues
.

> In this case I’d say this ‘works as designed’, the iPad view controller
> hierarchy is just different from that on the iPhone and the exit segue
> doesn’t fire. 

Yep. But, as always, we appreciate bugs that explain why the current
design doesn't work for a particular use case.

--Kyle Sluder

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-16 Thread Gerriet M. Denkmann

> On 16 Apr 2015, at 21:42, Kyle Sluder  wrote:
> 
> On Apr 15, 2015, at 10:49 PM, Gerriet M. Denkmann  
> wrote:
>> 
>> 
>> 
>> 
>> 3.Run
>> 
>> Run on iPhone:
>> Back Button is called "Master"
>> 
>> Run on iPad:
>> Back Button is called "Master iPad"
>> 
>> Strange, but not very important.
> 
> Again, please file this as a separate Radar. (Are you sure it doesn’t say 
> “Master…” on iPhone? That is, does it really say “Master iPhone” but it’s 
> being truncated?)

iPhone uses the title of the Master Navigation Bar for the Back Button.
In the Master iPhone Scene I changed the title of the Navigation Bar to 
“Monster”, and now the iPhone Back Button looks like “< Monster”.

> 
>> 
>> 
>> 4.Unwinding
>> 
>> Added in MasterViewController:
>> 
>> - (IBAction)doSomethingAndBackToMaster:(UIStoryboardSegue*)segue
>> {
>>   DetailViewController *detailViewController = segue.sourceViewController;
>>   NSLog(@"%s did something with \"%@\", will do: [%@ perform]",__FUNCTION__, 
>>   detailViewController.detailItem, segue);
>>   [ segue perform ];
> 
> 
> You should not be sending -perform yourself. The segue runtime sends -perform 
> to the unwind segue itself. You are given a pointer to the segue object so 
> that you can inspect its source and destination view controllers and its 
> identifier, so you may choose what work you need to perform in your unwind 
> method.

Following your suggestion, I have removed the “[segue perform]” line.

Kind regards,

Gerriet.


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-16 Thread Roland King

> On 16 Apr 2015, at 22:20, Gerriet M. Denkmann  wrote:
> 
>> 
>> On 16 Apr 2015, at 13:41, Roland King  wrote:
>> 
>> 
>>> 
>>> 5. Run 
>>> 
>>> iPhone  - tapping on "Do & Back" prints:
>>> 2015-04-16 12:16:52.799 Dummi[28069:20737983] -[MasterViewController 
>>> doSomethingAndBackToMaster:] did something with "2015-04-16 05:16:49 
>>> +", will do: [ perform]
>>> 
>>> iPad- tapping on "Do & Back" prints:
>>> nothing. 
>>> 
>> 
>> 
>> What did you expect it to do on the iPad?
> 
> I expected it to print and then to ignore the segue, because as you say, it 
> makes no sense on iPad.

Ah no - it would only have printed if the segue was run/actioned/whatever you 
do to a segue. That would only happen if the class implementing the exit segue 
had been located. Exit segue resolution is something a bit like the responder 
chain. In this case the class which implemented the segue isn’t in the chain of 
UIViewControllers on the iPad so it’s not found so it’s not run. 

Exit segues are documented however I’ve never found the documentation terribly 
clear, it does however tell you what methods are called in the search for an 
exit segue and how the search goes up the chain. 

In this case I’d say this ‘works as designed’, the iPad view controller 
hierarchy is just different from that on the iPhone and the exit segue doesn’t 
fire. 
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-16 Thread Kyle Sluder
On Apr 15, 2015, at 10:49 PM, Gerriet M. Denkmann  wrote:
> 
> 
>>> Can this be done? Or is there a better way to make my button work both
>>> for iPhone and iPad?
>> 
>> Well, my first question is: can you just put your work in the
>> implementation of the unwind selector?
> 
> That is the way the work is done.
> 
>> The unwind itself will be a no-op
>> if the split view controller is not collapsed, but the runtime should
>> still invoke your unwind selector. If it doesn't, that's a bug, and you
>> should file a Radar and send me the number.
> Bug 20566151 iPad cannot Unwind
> 
> If someone wants to check this bug, here is how I did it:
> 
> 
> 1. Create project
> 
> I created (in Xcode 6.3) a new iOS Application: Master-Detail Application; 
> named it "Dummi" (left all the other things unchanged: i.e Objective-C, 
> Universal, no CoreData).
> 
> 
> 2.Rename Master Scenes
> 
> Looked at Main.storyboard. It has 2 Master Scenes. This I think confusing.

You should file this as a separate Radar.


> 
> I clicked the yellow "Master" symbol in the first Master Scene, set 
> Attributes Inspector → View Controller → Title to "Master iPad".
> 
> Same with other "Master" → "Master iPhone".
> 
> 
> 3.Run
> 
> Run on iPhone:
> Back Button is called "Master"
> 
> Run on iPad:
> Back Button is called "Master iPad"
> 
> Strange, but not very important.

Again, please file this as a separate Radar. (Are you sure it doesn’t say 
“Master…” on iPhone? That is, does it really say “Master iPhone” but it’s being 
truncated?)

> 
> 
> 4.Unwinding
> 
> Added in MasterViewController:
> 
> - (IBAction)doSomethingAndBackToMaster:(UIStoryboardSegue*)segue
> {
>DetailViewController *detailViewController = segue.sourceViewController;
>NSLog(@"%s did something with \"%@\", will do: [%@ perform]",__FUNCTION__, 
>detailViewController.detailItem, segue);
>[ segue perform ];


You should not be sending -perform yourself. The segue runtime sends -perform 
to the unwind segue itself. You are given a pointer to the segue object so that 
you can inspect its source and destination view controllers and its identifier, 
so you may choose what work you need to perform in your unwind method.

> }
> 
> Added in Detail Scene a UIBarButtonItem to the right of the Navigation Bar; 
> Titel = "Do & Back".
> 
> Control-dragged from "Do & Back" to red Exit symbol in Master iPhone Scene; 
> selected "doSomethingAndBackToMaster:".
> 
> 
> 5. Run 
> 
> iPhone- tapping on "Do & Back" prints:
> 2015-04-16 12:16:52.799 Dummi[28069:20737983] -[MasterViewController 
> doSomethingAndBackToMaster:] did something with "2015-04-16 05:16:49 +", 
> will do: [ perform]
> 
> iPad- tapping on "Do & Back" prints:
> nothing. 

Thanks, for filing. That’s definitely unfortunate.

> 
> 
>> But while I'm here, I figure I should share some little-known knowledge:
>> segues do not need to be attached to a control at all. A segue is
>> actually defined by its source and destination view controllers, not by
>> any controls that invoke it.
>> 
>> To create a "manual segue" (that is, one which must be invoked in code,
>> rather than by any button action):
>> 
>> 1. In the Document Outline on the left side of the storyboard editor,
>> expand the Master and Detail scenes
>> 2. Control-drag from the Detail scene's view controller to the Master
>> scene's Exit proxy.
>> 3. Choose the unwind selector to create a manual unwind segue that isn't
>> attached to any specific control.
> 
> No such choice.
> I get offered:
> Manual Segue
>doSomethingAndBackToMaster:
> Nothing else

That’s what you should see. Perhaps the title of the menu should be “Unwind 
Segue”, but right now it’s titled “Manual Segue” to emphasize that this is an 
unwind segue which you must invoke yourself via 
-performSegueWithIdentifier:sender:.

--Kyle Sluder

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-16 Thread Gerriet M. Denkmann

> On 16 Apr 2015, at 13:41, Roland King  wrote:
> 
> 
>> 
>> 5. Run 
>> 
>> iPhone   - tapping on "Do & Back" prints:
>> 2015-04-16 12:16:52.799 Dummi[28069:20737983] -[MasterViewController 
>> doSomethingAndBackToMaster:] did something with "2015-04-16 05:16:49 +", 
>> will do: [ perform]
>> 
>> iPad - tapping on "Do & Back" prints:
>> nothing. 
>> 
> 
> 
> What did you expect it to do on the iPad?

I expected it to print and then to ignore the segue, because as you say, it 
makes no sense on iPad.

> If the master column is already showing there’s nothing to do, if not you’re 
> in portrait. Did you expect it to do the same thing the ‘Master’ button does 
> and show the master column? That’s not really an unwind, it’s movement to a 
> parallel state. 
> 
> It’s arguably a bug. The reason it doesn’t do anything at all is because the 
> viewcontroller hierarchy is rather different between iPad and iPhone, in 
> iPhone the master and detail are stacked in a UINavigationController, so the 
> unwind segue finds the master as it goes up the tree. In the other they are 
> siblings in the splitviewcontroller, so the unwind segue doesn’t get found. 
> Even if you subclass the splitviewcontroller to return the master view 
> controller you’ll find the segue still does nothing as, as I said, it’s not 
> really an unwind. 
> 

Kind regards,

Gerriet.



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Roland King

> 
> 5. Run 
> 
> iPhone- tapping on "Do & Back" prints:
> 2015-04-16 12:16:52.799 Dummi[28069:20737983] -[MasterViewController 
> doSomethingAndBackToMaster:] did something with "2015-04-16 05:16:49 +", 
> will do: [ perform]
> 
> iPad  - tapping on "Do & Back" prints:
> nothing. 
> 


What did you expect it to do on the iPad? If the master column is already 
showing there’s nothing to do, if not you’re in portrait. Did you expect it to 
do the same thing the ‘Master’ button does and show the master column? That’s 
not really an unwind, it’s movement to a parallel state. 

It’s arguably a bug. The reason it doesn’t do anything at all is because the 
viewcontroller hierarchy is rather different between iPad and iPhone, in iPhone 
the master and detail are stacked in a UINavigationController, so the unwind 
segue finds the master as it goes up the tree. In the other they are siblings 
in the splitviewcontroller, so the unwind segue doesn’t get found. Even if you 
subclass the splitviewcontroller to return the master view controller you’ll 
find the segue still does nothing as, as I said, it’s not really an unwind. 



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Gerriet M. Denkmann

>> Can this be done? Or is there a better way to make my button work both
>> for iPhone and iPad?
> 
> Well, my first question is: can you just put your work in the
> implementation of the unwind selector?

That is the way the work is done.

> The unwind itself will be a no-op
> if the split view controller is not collapsed, but the runtime should
> still invoke your unwind selector. If it doesn't, that's a bug, and you
> should file a Radar and send me the number.
Bug 20566151 iPad cannot Unwind

If someone wants to check this bug, here is how I did it:


1. Create project

I created (in Xcode 6.3) a new iOS Application: Master-Detail Application; 
named it "Dummi" (left all the other things unchanged: i.e Objective-C, 
Universal, no CoreData).


2.  Rename Master Scenes

Looked at Main.storyboard. It has 2 Master Scenes. This I think confusing.

I clicked the yellow "Master" symbol in the first Master Scene, set Attributes 
Inspector → View Controller → Title to "Master iPad".

Same with other "Master" → "Master iPhone".


3.  Run

Run on iPhone:
Back Button is called "Master"

Run on iPad:
Back Button is called "Master iPad"

Strange, but not very important.


4.  Unwinding

Added in MasterViewController:

- (IBAction)doSomethingAndBackToMaster:(UIStoryboardSegue*)segue
{
DetailViewController *detailViewController = segue.sourceViewController;
NSLog(@"%s did something with \"%@\", will do: [%@ 
perform]",__FUNCTION__, 
detailViewController.detailItem, segue);
[ segue perform ];
}

Added in Detail Scene a UIBarButtonItem to the right of the Navigation Bar; 
Titel = "Do & Back".

Control-dragged from "Do & Back" to red Exit symbol in Master iPhone Scene; 
selected "doSomethingAndBackToMaster:".


5. Run 

iPhone  - tapping on "Do & Back" prints:
2015-04-16 12:16:52.799 Dummi[28069:20737983] -[MasterViewController 
doSomethingAndBackToMaster:] did something with "2015-04-16 05:16:49 +", 
will do: [ perform]

iPad- tapping on "Do & Back" prints:
nothing. 


> But while I'm here, I figure I should share some little-known knowledge:
> segues do not need to be attached to a control at all. A segue is
> actually defined by its source and destination view controllers, not by
> any controls that invoke it.
> 
> To create a "manual segue" (that is, one which must be invoked in code,
> rather than by any button action):
> 
> 1. In the Document Outline on the left side of the storyboard editor,
> expand the Master and Detail scenes
> 2. Control-drag from the Detail scene's view controller to the Master
> scene's Exit proxy.
> 3. Choose the unwind selector to create a manual unwind segue that isn't
> attached to any specific control.

No such choice.
I get offered:
Manual Segue
doSomethingAndBackToMaster:
Nothing else

> 4. On the Properties Inspector for that newly-created segue, give it an
> identifier.
> 5. Wire up your bar button item to a method that uses
> -performSegueWithIdentifier:sender to trigger the unwind.
> 
> —Kyle Sluder

Gerriet.



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Kyle Sluder
On Wed, Apr 15, 2015, at 07:18 AM, Gerriet M. Denkmann wrote:
> 
> While my iPhone can use the “DoSomethingAndGoBackToMasterView” button
> fine,
> the same button does nothing for iPad.
> 
> Of course iPad does not need an unwinding segue - both master and detail
> view are always visible (at least in landscape orientation). But the
> “DoSomething” part is still needed.
> 
> Currently the button has a Triggered Segue (used on iPhone) and a Sent
> Action - obviously ignored, because of the segue.
> 
> So the idea: if the app starts on iPad, I could just clear the Triggered
> Segue and the Sent Action would be used.
> But how? UIBarButtonItem has nothing about segues.

Correct; you can't manipulate segue definitions at runtime.

> 
> Can this be done? Or is there a better way to make my button work both
> for iPhone and iPad?

Well, my first question is: can you just put your work in the
implementation of the unwind selector? The unwind itself will be a no-op
if the split view controller is not collapsed, but the runtime should
still invoke your unwind selector. If it doesn't, that's a bug, and you
should file a Radar and send me the number.

But while I'm here, I figure I should share some little-known knowledge:
segues do not need to be attached to a control at all. A segue is
actually defined by its source and destination view controllers, not by
any controls that invoke it.

To create a "manual segue" (that is, one which must be invoked in code,
rather than by any button action):

1. In the Document Outline on the left side of the storyboard editor,
expand the Master and Detail scenes
2. Control-drag from the Detail scene's view controller to the Master
scene's Exit proxy.
3. Choose the unwind selector to create a manual unwind segue that isn't
attached to any specific control.
4. On the Properties Inspector for that newly-created segue, give it an
identifier.
5. Wire up your bar button item to a method that uses
-performSegueWithIdentifier:sender to trigger the unwind.

--Kyle Sluder

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Gerriet M. Denkmann

While my iPhone can use the “DoSomethingAndGoBackToMasterView” button fine,
the same button does nothing for iPad.

Of course iPad does not need an unwinding segue - both master and detail view 
are always visible (at least in landscape orientation). But the “DoSomething” 
part is still needed.

Currently the button has a Triggered Segue (used on iPhone) and a Sent Action - 
obviously ignored, because of the segue.

So the idea: if the app starts on iPad, I could just clear the Triggered Segue 
and the Sent Action would be used.
But how? UIBarButtonItem has nothing about segues.

Can this be done? Or is there a better way to make my button work both for 
iPhone and iPad?

Gerriet.


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Gerriet M. Denkmann

> On 15 Apr 2015, at 15:37, Quincey Morris 
>  wrote:
> 
> On Apr 15, 2015, at 01:18 , Gerriet M. Denkmann  wrote:
>> 
>> In DetailViewController I added:
>> 
>> - (IBAction)unwindToMainMenu:(UIStoryboardSegue*)sender
> 
> I dunno offhand, but you originally said you’re trying to go back to the 
> master view controller, and the tech note says that the destination needs to 
> implement the action method. It looks like you implemented in the source 
> (detail view controller) instead.

I moved the unwindToMainMenu to the MasterViewController, then control dragged 
from my button to the red Exit symbol in the Master Scene.
An “Unwind segue” appeared in the Detail Scene. Does not need an identifier.

Now it works fine.

Thank you very much!

Kind regards,

Gerriet.


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Quincey Morris
On Apr 15, 2015, at 01:18 , Gerriet M. Denkmann  wrote:
> 
> In DetailViewController I added:
> 
> - (IBAction)unwindToMainMenu:(UIStoryboardSegue*)sender

I dunno offhand, but you originally said you’re trying to go back to the master 
view controller, and the tech note says that the destination needs to implement 
the action method. It looks like you implemented in the source (detail view 
controller) instead.



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Gerriet M. Denkmann

> On 15 Apr 2015, at 14:51, Quincey Morris 
>  wrote:
> 
> On Apr 14, 2015, at 23:47 , Gerriet M. Denkmann  wrote:
>> 
>> Using the Xcode template: iOS - Master-Detail, the Detail view has (in the 
>> top left corner) a Back-Button, which works fine.
>> 
>> Now I added another UIBarButtonItem called: “Do something and go back” 
>> connected to some IBAction in DetailViewController.
>> 
>> But how to make it go back to the MasterView? 
>> 
>> Found some mention of the red Exit symbol. But cannot persuade Xcode to 
>> create an Unwind segue to Master.
>> Tried to Control-Drag from the yellow Detail thing to the red Exit below, 
>> but no effect.
>> 
>> What am I missing?
> 
> https://developer.apple.com/library/ios/technotes/tn2298/_index.html
> 
> The key to this is that the unwind action method must have exactly the 
> parameter type shown. Anything else prevents IB from connecting the Exit 
> button to the  target.

In DetailViewController I added:

- (IBAction)unwindToMainMenu:(UIStoryboardSegue*)sender
{
UIViewController *sourceViewController = sender.sourceViewController;
NSLog(@"%s %@ id %@",__FUNCTION__, sourceViewController, 
sender.identifier);
[ sender perform ];
}

Now I can control-drag from by UIBarButtonItem to the red Exit symbol in the 
Detail Scene. A big step forward.
A new “Unwind segue to Scene Exit Placeholder” appeared. I gave it an 
identifier.


Build, run, click on my button: nothing happens.

I added:

- (IBAction)dummyExit: sender;  
{
(void)sender;
NSLog(@"%s %@ ",__FUNCTION__, sender);
}

and control-dragged from my button to the yellow Detail thing.

Build, run, click on my button: nothing happens.
Nothing means: no NSLog, no anything.

What else am I missing?


Kind regards,

Gerriet.



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Master - Detail: How to get back?

2015-04-15 Thread Quincey Morris
On Apr 14, 2015, at 23:47 , Gerriet M. Denkmann  wrote:
> 
> Using the Xcode template: iOS - Master-Detail, the Detail view has (in the 
> top left corner) a Back-Button, which works fine.
> 
> Now I added another UIBarButtonItem called: “Do something and go back” 
> connected to some IBAction in DetailViewController.
> 
> But how to make it go back to the MasterView? 
> 
> Found some mention of the red Exit symbol. But cannot persuade Xcode to 
> create an Unwind segue to Master.
> Tried to Control-Drag from the yellow Detail thing to the red Exit below, but 
> no effect.
> 
> What am I missing?

https://developer.apple.com/library/ios/technotes/tn2298/_index.html 


The key to this is that the unwind action method must have exactly the 
parameter type shown. Anything else prevents IB from connecting the Exit button 
to the  target.



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com