Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Rolf Bjarne Kvinge
Hi,

Do you have more than one AppDelegate classes? I have strange issues before
when there were two AppDelegate classes (in different namespaces)
registered as 'AppDelegate' to the Objective-C runtime, and at runtime
which one is picked is completely random.

The easiest way to check this is to install the 6.3.4 beta and try your app
in the simulator - you will get an exception at startup if there are more
than one class registered with the same Objective-C name.

Rolf

On Sun, Apr 28, 2013 at 6:35 PM, Paul Johnson
p...@all-the-johnsons.co.ukwrote:

 Hi,


  Very strange. I've not seen this before - I'd guess version
 differences with X.iOS, but I'm not sure... Can you remote into the
 other machine and have a play?


 It is an odd one. I remoted onto the Australian box which is how I fixed
 it. I can't fix at this end as I can't see where the problem is!


 Paul

 --
 Space, it says, is big. Really big. You just won't believe how vastly,
 hugely, mindbogglingly big it is. I mean, you may think it's a long way
 down the road to the chemist's, but that's just peanuts to space, listen...
 Hitch Hikers Guide to the Galaxy, a truly remarkable book!

 ___
 MonoTouch mailing list
 MonoTouch@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/monotouch

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Paul Johnson

Hi Rolf,


The easiest way to check this is to install the 6.3.4 beta and try your
app in the simulator - you will get an exception at startup if there are
more than one class registered with the same Objective-C name.


Only one AppDelegate there. Tried this under the stable, beta and alpha 
releases. All give the same results on the other machine. If it was on 
Android, I'd say it was a threading issue.


The fix I have in place solves the issue, but not the problem (as I see it)

Paul
--
Space, it says, is big. Really big. You just won't believe how 
vastly, hugely, mindbogglingly big it is. I mean, you may think it's a 
long way down the road to the chemist's, but that's just peanuts to 
space, listen...

Hitch Hikers Guide to the Galaxy, a truly remarkable book!

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Rolf Bjarne Kvinge
On Mon, Apr 29, 2013 at 4:13 PM, Paul Johnson
p...@all-the-johnsons.co.ukwrote:

 Hi Rolf,


  The easiest way to check this is to install the 6.3.4 beta and try your
 app in the simulator - you will get an exception at startup if there are
 more than one class registered with the same Objective-C name.


 Only one AppDelegate there. Tried this under the stable, beta and alpha
 releases. All give the same results on the other machine. If it was on
 Android, I'd say it was a threading issue.


Well, it was a shot in the dark anyway :)

There is always the low-tech solution of riddling your code with calls to
Console.WriteLine...

Rolf
___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Paul Johnson

Hi,


There is always the low-tech solution of riddling your code with calls
to Console.WriteLine...


Did that too - AppDelegate ignored. Now something has just occurred to 
me and I'm not sure if it happens in monotouch as it does in monodroid.


When the compiler hits an event, the event code is read to ensure it's 
correct and working. For example


listView.Click += delegate {
if (condition)
 // do something
else
 // do something else
};

If the something else line goes out of bounds or does something silly, 
the compilation dies there.


What I'm wondering is if something similar is happening here except 
instead of it being at compile time, it's at runtime (the method is 
called before AppDelegate is reached when it shouldn't be reached until 
FinishedLaunching has been hit - in other words, the UI is starting 
before it's started officially)


Does/can that happen?

Paul

--
Space, it says, is big. Really big. You just won't believe how 
vastly, hugely, mindbogglingly big it is. I mean, you may think it's a 
long way down the road to the chemist's, but that's just peanuts to 
space, listen...

Hitch Hikers Guide to the Galaxy, a truly remarkable book!

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Rolf Bjarne Kvinge
Hi,

On Mon, Apr 29, 2013 at 6:43 PM, Paul Johnson
p...@all-the-johnsons.co.ukwrote:

 Hi,


  There is always the low-tech solution of riddling your code with calls
 to Console.WriteLine...


 Did that too - AppDelegate ignored. Now something has just occurred to me
 and I'm not sure if it happens in monotouch as it does in monodroid.

 When the compiler hits an event, the event code is read to ensure it's
 correct and working. For example

 listView.Click += delegate {
 if (condition)
  // do something
 else
  // do something else
 };

 If the something else line goes out of bounds or does something silly, the
 compilation dies there.

 What I'm wondering is if something similar is happening here except
 instead of it being at compile time, it's at runtime (the method is called
 before AppDelegate is reached when it shouldn't be reached until
 FinishedLaunching has been hit - in other words, the UI is starting before
 it's started officially)


Never say never, but this doesn't sound plausible to me.

What is the actual behavior you're seeing on the screen? Does the app show
up as expected, or does it exit?

Rolf



 Does/can that happen?


 Paul

 --
 Space, it says, is big. Really big. You just won't believe how vastly,
 hugely, mindbogglingly big it is. I mean, you may think it's a long way
 down the road to the chemist's, but that's just peanuts to space, listen...
 Hitch Hikers Guide to the Galaxy, a truly remarkable book!

 ___
 MonoTouch mailing list
 MonoTouch@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/monotouch

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Paul Johnson

Hi,


What is the actual behavior you're seeing on the screen? Does the app
show up as expected, or does it exit?


I get a splash screen. It is then supposed to put up a message to say 
loading data (UIAlert) and then another UIAlert to say welcome. Now here 
is the reason why I think it was at runtime.


UIAlert #1 works. It doesn't use the LocalizedString code. UIAlert #2 
isn't hit, but what is happening is really odd. The LocalizedString is 
being called but looks to being called twice - once before 
FinishedLaunching has been executed, once after with the same token. 
This token is only ever used once (no replications of the token exist 
when I do a Search in Files other than in the Localized.strings file).


The mystery deepens!

Paul
--
Space, it says, is big. Really big. You just won't believe how 
vastly, hugely, mindbogglingly big it is. I mean, you may think it's a 
long way down the road to the chemist's, but that's just peanuts to 
space, listen...

Hitch Hikers Guide to the Galaxy, a truly remarkable book!

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-29 Thread Rolf Bjarne Kvinge
On Mon, Apr 29, 2013 at 11:19 PM, Paul Johnson
p...@all-the-johnsons.co.ukwrote:

 Hi,


  What is the actual behavior you're seeing on the screen? Does the app
 show up as expected, or does it exit?


 I get a splash screen. It is then supposed to put up a message to say
 loading data (UIAlert) and then another UIAlert to say welcome. Now here is
 the reason why I think it was at runtime.

 UIAlert #1 works. It doesn't use the LocalizedString code. UIAlert #2
 isn't hit, but what is happening is really odd. The LocalizedString is
 being called but looks to being called twice - once before
 FinishedLaunching has been executed, once after with the same token. This
 token is only ever used once (no replications of the token exist when I do
 a Search in Files other than in the Localized.strings file).


This doesn't sound like anything I've run into before :|



 The mystery deepens!


Good hunting!

Rolf
___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-28 Thread Nic Wise
Is is being ignored, or just no debugging?

What happens if you put Console.WriteLine or Debug.WriteLine in there?
do you see output?

What happens if you install the sims?

On 28 April 2013 01:52, Paul Johnson p...@all-the-johnsons.co.uk wrote:
 Hi,

 Got an interesting problem here. I have the same app running on two
 identical machines with the same software and OS set ups (two Mac minis, the
 other one is the Australia)

 The app has been developed on my machine, committed to svn and then brought
 down to the aussie box and built.

 When I run the debugger here, the app fires through and picks things up
 correctly from AppDelegate for localisation. The one in Australia completely
 ignores AppDelegate. By that I mean none of the break points in AppDelegate
 are hit, they are on my box.

 Is there any way to find why the flow is completely different between the
 machines?

 The only difference between the the machines is that I have the simulators
 for iOS 5, 5.1 and 6 installed whereas the other box doesn't. When I build
 for 6.1, everything works at this end.

 I've noticed some of the xib files are set for a target of iOS 3. Is this
 likely to be the issue?

 Paul
 --
 Space, it says, is big. Really big. You just won't believe how vastly,
 hugely, mindbogglingly big it is. I mean, you may think it's a long way down
 the road to the chemist's, but that's just peanuts to space, listen...
 Hitch Hikers Guide to the Galaxy, a truly remarkable book!

 ___
 MonoTouch mailing list
 MonoTouch@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/monotouch



-- 
Nic Wise
t.  +44 7788 592 806 | @fastchicken
b. http://www.fastchicken.co.nz/
___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-28 Thread Paul Johnson

Hi,


Is is being ignored, or just no debugging?


Being ignored


What happens if you put Console.WriteLine or Debug.WriteLine in there?
do you see output?


See nothing


What happens if you install the sims?


Nothing.

One thing I did find was that if it ignores the first instance of an 
error (it is returning AppDelegate.Self.LB.LocalizedString(string token) 
but Self is null so the app dies) then AppDelegate is seen and 
everything works from there on in. Again, don't see this on the version 
I have here, but only on the other machine.


Paul

--
Space, it says, is big. Really big. You just won't believe how 
vastly, hugely, mindbogglingly big it is. I mean, you may think it's a 
long way down the road to the chemist's, but that's just peanuts to 
space, listen...

Hitch Hikers Guide to the Galaxy, a truly remarkable book!

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-28 Thread Nic Wise
Very strange. I've not seen this before - I'd guess version
differences with X.iOS, but I'm not sure... Can you remote into the
other machine and have a play?

On 28 April 2013 17:01, Paul Johnson p...@all-the-johnsons.co.uk wrote:
 Hi,


 Is is being ignored, or just no debugging?


 Being ignored


 What happens if you put Console.WriteLine or Debug.WriteLine in there?
 do you see output?


 See nothing


 What happens if you install the sims?


 Nothing.

 One thing I did find was that if it ignores the first instance of an error
 (it is returning AppDelegate.Self.LB.LocalizedString(string token) but Self
 is null so the app dies) then AppDelegate is seen and everything works from
 there on in. Again, don't see this on the version I have here, but only on
 the other machine.


 Paul

 --
 Space, it says, is big. Really big. You just won't believe how vastly,
 hugely, mindbogglingly big it is. I mean, you may think it's a long way down
 the road to the chemist's, but that's just peanuts to space, listen...
 Hitch Hikers Guide to the Galaxy, a truly remarkable book!

 ___
 MonoTouch mailing list
 MonoTouch@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/monotouch



-- 
Nic Wise
t.  +44 7788 592 806 | @fastchicken
b. http://www.fastchicken.co.nz/
___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch


Re: [MonoTouch] Same app seems to follow two different paths - any ideas?

2013-04-28 Thread Paul Johnson

Hi,


Very strange. I've not seen this before - I'd guess version
differences with X.iOS, but I'm not sure... Can you remote into the
other machine and have a play?


It is an odd one. I remoted onto the Australian box which is how I fixed 
it. I can't fix at this end as I can't see where the problem is!


Paul

--
Space, it says, is big. Really big. You just won't believe how 
vastly, hugely, mindbogglingly big it is. I mean, you may think it's a 
long way down the road to the chemist's, but that's just peanuts to 
space, listen...

Hitch Hikers Guide to the Galaxy, a truly remarkable book!

___
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch