oulan / iui

Automatically exported from code.google.com/p/iui
MIT License
0 stars 0 forks source link

[PATCH] Add autoloadAnchor property #253

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
For many apps, the onLoad automatic navigation to a screen based on the
anchor is a feature, but for applications with a login or loading screen
that should come first, this is a hindrance.

This patch adds the iui.autoloadAnchor property, which, if set to 'false'
by client-code, will skip the automatic navigation on load (but will still
peform automatic navigation to the selected="true" screen).

Note: this patch is based on patches for #251 and #252, so it may work best
to apply them in order.

Original issue reported on code.google.com by PeterAndJessica@gmail.com on 4 Jun 2010 at 12:53

Attachments:

GoogleCodeExporter commented 9 years ago
Maybe a login function should save the anchor and then load it after login is 
complete?

Original comment by msgilli...@gmail.com on 11 Jun 2010 at 3:06

GoogleCodeExporter commented 9 years ago
Turning off the autoload of the anchor is fairly simple.. Passing the anchor to 
the startup/login panel or function (it would be the responsibility of the 
startup/login function to call iui.showPageById() after it is done), while 
cool, may be too complicated.

We already have the convention of selected="true" for the startup panel -- but 
I'm not sure how iUI would pass the anchor to that panel and it seems like we 
would still need a config setting (like autoloadAnchor=false) to turn off the 
default behavior.

Original comment by PeterAndJessica@gmail.com on 11 Jun 2010 at 5:57

GoogleCodeExporter commented 9 years ago
Another thing I'd like to add to iUI is the ability to have a plugin do ajax 
loads based upon the anchor.  This anchor loading code is something I added -- 
don't blame JoeH ;)  It covers about 80% of the cases, but IMHO needs some 
rework that goes beyond this patch.  So maybe we could just commit this patch 
or maybe we could try to be more ambitious and make a bigger fix.  I really 
want to focus on getting my iscroll branch fixed up and merged in before  I 
make any other changes  to iUI.

I think this  is a good patch, though, and would recommend it to people that 
need to disable disable "autoLoadAnchor"

Original comment by msgilli...@gmail.com on 11 Jun 2010 at 10:19