Topic: Problem with 0.5.0 Release Candidate

    #iHeader { background-color:green }

Re: Problem with 0.5.0 Release Candidate

Hello Chrilith !

Firstly, thank you for this excellent work. The RC2 is faster and pleasant than the 0.3.9.

Otherwise, the idea of making WebApp.net compatible with Firefox, IE, Opera and other browsers is very good.

Able to create themes is also something very interesting.

----

I noticed some problems:

- There is a problem with iMenu / iArrow when there are many elements (+50): the interface becomes very slow.

Adding an manual XmlHttpRequest on this big list makes many and many bugs when the request is done, and when we want to go back (1 to 5 seconds to wait before the "back" action takes effect).

- The addition of manual XmlHttpRequest is "flashing" the content of these requests in some cases, while with 0.3.9 there was no problem

- Sometimes, during an asynchronous request, the transition animation is not done and the content is displayed directly, probably because of the content.

- Sometimes, during an asynchronous request, the actual content (text) of the page flashes before switching to the next page

EDIT : Problems only on the iPhone's Safari. On the Mac Safari, all is okay.

EDIT 2 : With a iList <h2>, if the text is too long, the gray bar do not take 2 lines and the text overlaps the next iList element. (Mac & iPhone)

EDIT 3 : Many bugs in fullscreen mode :

- Text fields (eg: for login) are strange where I touch them into the keyboard mode, even if the field is in the bottom of the page, the page goes back on top, and the field is not select. I need to tap the "Next" button in the keyboard mode to switch to the next text field.

- The <a> links with a target="ext" doesn't work (I think it's normal... but there is no solution currently to link to a .pdf, .doc, .txt, etc, like I can do with a rev="media" for QuickTime contents... I think it's THE big problem of WebApp.net :-)

- Cookies doesn't work anymore when I re-start my page. But it's not a WebApp.net problem I think !

----

A question: Are you French ? I want to show you my project, but it is only disponible in French.

I think that my project will show to you many bugs of your micro framework, because it's really big (~100 pages, many cases of utilisations of WebApp.net)

If you want more informations, tell me and I will send to you a PM !

EDIT 3 : Sorry for the big post, but nobody have reported this kind of problems !

Last edited by Valty (2009-02-22 14:53:43)

Re: Problem with 0.5.0 Release Candidate

Hello!

I also have a problem with the new version : the AddEventListener function
seems not to work properly with 0.5.0.

Here is the code I used, in the html head of my first page (with waHome as
first layer) :

<script type="text/javascript">

    WA.AddEventListener("load", LoadingTab);
         
    function LoadingTab(evt) {
         WA.Header(0, "tab1");
    }

</script>

With 0.3.9a, my tab bar was displayed fine in the Header. I haven't changed
the code, and it unfortunately isn't displayed with 0.5.0. Is it a bug? Or can
I do something to fix that?

Thanks a lot!

4

Re: Problem with 0.5.0 Release Candidate

I can't use 0.5.0 in its current state for my project. A lot of things have been broken.

The footer/header is broken and displayed incorrectly. And it displays differently in different browsers. I know it shouldn't be a problem if the app is only going to be viewed on the iPhone Safari, but I need to be able to develop it somehow. It's a pain if I can't use Firefox and FireBug to develop it.

There's so little documentation about the changes, it's horrible. You say you've changed the loader behaviour... How? What do I need to change to make it work? I can't look at the demo source code because it's changed by Logic.js duynamically. And the new demo's source code hasn't been released.

And stop messing with javascript return statements. Or at least write some documentation about how they should work. My onclicks have been broken in the new release. I can't make buttons do what I want them to.

Sometimes it seems that too much css is being generated by Logic.js. You're trying to make it simpler to develop the pages, but you're overriding custom styles and behaviour. I really like how webapp handles page transitions and all those nice lists, but there should be more control over it. I shouldn't be made to change or override your framework code to do things I want to.

Re: Problem with 0.5.0 Release Candidate

Hello Ed,

WebApp.net is the basis for works only on WebKit derivatives browsers. The 0.3.9 only works with Safari, Chrome, WebKit, etc...

With the 0.5.0 RC2, there is a small CSS that allows working with FireFox (header readjustment). But the display is not good because Firefox does not support CSS WebKit instructions (for borders and buttons).

Is it really a problem ? WebApp.net is a micro-framework designed for mobile working, and just works with iPhone, Androïd, WinMo Opera (poorly... but it's WinMo) and maybe with the future "mobile FireFox".

For the documentation and the demo... the 0.5.0 is a release candidate... not a stable version. But I agree that it is difficult to identify new things without this.

Maybe you should wait for the final version ! :-)

Re: Problem with 0.5.0 Release Candidate

Re: Problem with 0.5.0 Release Candidate

To everyone, please, provide me with a sample code who shows the problem you met on the forum if it is small or send me an email with a link to the problem

Thanks!

8

Re: Problem with 0.5.0 Release Candidate

Sorry about the rant. I was annoyed with not being able to get the new version to work. I will try to write a decent post about the issues I'm having.

Re: Problem with 0.5.0 Release Candidate

Ok thanks, for the info, the first post will be updated according to your answers and what have been fixed.

10

Re: Problem with 0.5.0 Release Candidate

Re: Problem with 0.5.0 Release Candidate

For your logo:

You can put it in your "waHeadTitle" container and then use CSS to adjust its top position:

#waHeadTitle img { position:relative; top:-5px }

Like this your logo will be centerer and properly positioned (adjust the top value, of course wink)
For the background, you don't need to make your own anymore, just use "background-color" as explain earlier. You can also use background-image if you want your logo to not move while sliding.

I'll check the onclick problem.

Could you explain what you've done regarding menu problem?

Don't know about back button and Chrome. AFAIK, even if it is a release, it is not so stable.

Theme let you know what you can change to customize the colors, not required, only an incomplete sample. Firefox is here to fix some presentation with this browser. For dev purpose only. WebApp.Net doesn't work on IE because it use a non standard javascript engine and lakes of many CSS features support.

Target is supposed to be fixed in this version and onclick internally handled - so everything should work nice with this version.

!important directive makes things easier but I try to prevent its use as much as possible. I use it only when I have no other choice.

Thanks a lot!!!

Re: Problem with 0.5.0 Release Candidate

Sorry, my answer is a bit late. Actually, I found the solution, or rather an explanation : I had a link to another javascript function in the html head of my webapp first page (so in xhtml):

WA.AddEventListener("load", Redirection);
 
function Redirection(evt) {
 
 var anchor = x_document.location.hash;
 
 if ( anchor == "#_Part1")
 {
  var url = "/iphone/fr/Part1/index.html";
 }
 else if ( anchor == "#_Part2")
 {
  var url = "/iphone/fr/Part2/index.html";
 }
//...
 else
 {
  //do nothing
 }
 
 WA.Request(url, null, -1);
}

This code was put in the html code before the following, which was called before I updated WAn and not any more after that :

<HTML xmlns="http://www.w3.org/1999/xhtml">
<HEAD>
        ....
 <!-- link to the before-mentioned function-->
        ....
 <SCRIPT type="text/javascript">
 
  //this zone is always called on page load
 
  WA.AddEventListener("load", LoadTab);
 
  function LoadTab(evt) {
   //this function is only called on page load with the 0.3.9a version, not the 0.5.0
   WA.Header(0, "tab1");
  }
 
 </SCRIPT>
</HEAD>
<BODY>
 ....
</BODY>

So, it seems that only one javascript function can be called just after the page loads with WAn's new version. Is it true? Can we change this? I've found that when I disabled the first part of the javascript code the knotty part of code was well called, so it is approximately solved.

Could it be possible to have a preciser description of the code update with the new version? And access to a more human-readable Logic.js, as in the Debug folder of the previous release?

Thanks.

Re: Problem with 0.5.0 Release Candidate

Hey Chrilith:

Here is some code that shows a "jumping" page bug.
I tried to remove more ul's and li's, but then the bug would go away.
My guess is it has something to do with header buttons, since WebApp
"jumps" up and down a set height.  But that's a total guess.
(Sorry about formatting, cut&paste from linux does that;) )
BTW, is there a debug version of V0.5.0RC2, so we can help debug?

<html>
<head>
  <title>WebAppV0.5.0</title>
    <meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta names="apple-mobile-web-app-status-bar-style" content="black-translucent" />
    <link rel="Stylesheet" href="WebAppV0.5.0/Design/Render.css" />
    <script type="text/javascript" src="WebAppV0.5.0/Action/Logic.js"></script>
</head>
<body -dir="rtl"><div id="WebApp">
<div id="iHeader">
    <a href="#" id="waBackButton">Back</a>
    <a href="#" id="waHomeButton">Home</a>
  <a href="#" onclick="return WA.HideBar()"><span id="waHeadTitle">Bug Demo</span></a>
</div>
<div id="iGroup">
  <!-- Home -->
    <div class="iLayer" id="waHome" title="Home">
        <div class="iMenu">
      <h3>Title</h3>
            <ul class="iArrow iShop">
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
            </ul>
      <h3>Title</h3>
            <ul class="iArrow iShop">
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
            </ul>
      <h3>Title</h3>
            <ul class="iArrow iShop">
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
            </ul>
      <h3>Title</h3>
            <ul class="iArrow iShop">
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
            </ul>
      <h3>Title</h3>
            <ul class="iArrow iShop">
        <li><a href="#_Simple"><img src="Demo/Img/image.png" class="iFull"/></a></li>
            </ul>
        </div>        
    </div>
  <!-- Simple List -->
    <div class="iLayer" id="waSimple" title="Simple List">
        <div class="iList">
            <h2>Title</h2>
            <ul class="iArrow">
                <li>This item has no link</li>
            </ul>
        </div>
    </div>
</div>
</div></body>
</html>

14

Re: Problem with 0.5.0 Release Candidate

<div id="iHeader">

<a href="#" id="waBackButton">Back</a> 
<a href="#" class="iRightButton iBClassic" onclick="return toggleAct();">More</a>

<div id="waHeadTitle">
<a href="#" onclick="return WA.Home();"><img src="logo.png" alt="Logo" /></a>
<br /><span class="tagline">Some text!</span>
</div>

<div class="iForm" id="actionsForm" style="display:none;">
<a id="button1" class="iFormButton" href="#" onclick="return doStuff1();">Press me</a>
<a id="button2" class="iFormButton" href="#" onclick="return doStuff2();">Press me</a>
<a class="iFormButton" href="Layer/about.xml#_About" rev="async">About</a>
</div>

</div>

Re: Problem with 0.5.0 Release Candidate

incaic: yes, the flicker problem is related to the scroll-to-top effect - this is more a safari bug but I'll try to find a workaround

ed: For the header, using what I gave you in previous post should work. To disable the click you need to return false in your toggleAct() - this will fix the problem but in fact it seems there is a bug when false is not returned. Since it is handled by WAn and classic behavior too.

FYI, with or without WAn, using onclick, you need to return false else, the link will be executed and if you have a href pointing to something else than "#" you go to the URL. This is the same thing used by the "confirm" javascript function. Also, using "#" you'll jump to the top in some browsers if you don't return false because # is an anchor to the current page and the scroll position is reset.

16

Re: Problem with 0.5.0 Release Candidate

Last edited by ed (2009-03-03 16:38:41)

17

Re: Problem with 0.5.0 Release Candidate

Noticed something strange...

I have an onload event on the body tag:

<body -dir="rtl" onload="SetupApp();">

It's supposed to add event listeners:

function SetupApp()
{
    WA.AddEventListener("beginslide", OnBeginSlide);
    WA.AddEventListener("load", OnLoadPage);
}

Problem is, I can't get the OnLoadPage function to fire in any way. In the old version it used to fire when I reloaded a page. Now it doesn't.

Re: Problem with 0.5.0 Release Candidate

Instead of onload, try:

addEventListener("load",SetupApp,true);

Last edited by incaic (2009-03-05 19:37:27)

19

Re: Problem with 0.5.0 Release Candidate

Re: Problem with 0.5.0 Release Candidate

Ed, in your example OnLoadPage is never called because the WAn "load" use window.addEventListener and is called before the body onload. You can verofy this easily using alerts or console.log to find the call order.

Re: Problem with 0.5.0 Release Candidate

Ed, I also wasn't able to reproduce youronclick problem. If you look at the demo, you'll see that there is a "search" button using onclick and the form is not shown and immediately hidden.

Looking at your code, I don't understand why you waste time changing buttons and hidding __wa_shadow when this is fully and automatically supported by WebApp.Net using WA.Form (ShowAct/HideAct). Of course your code currently needs to have a form around in order for it to work.... but I'll change this.

Re: Problem with 0.5.0 Release Candidate

WA.Form has been changed in RC3 - let me know if you need help using it to remove your ShowAct/HideAct.

23

Re: Problem with 0.5.0 Release Candidate

Re: Problem with 0.5.0 Release Candidate

Re: Problem with 0.5.0 Release Candidate

well, really weird. There are only few changes in this version and nothing on slide effect, buttons or switch.... I've tested the content of the archive with the current demo (the old one) and I have no problem.