Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#14047 closed defect (wontfix)

Dojox.mobile.TextBox focus problem

Reported by: mc007ibi Owned by: ykami
Priority: high Milestone: tbd
Component: DojoX Mobile Version: 1.7.0b1
Keywords: Cc: Chris Mitchell, Ming Zhe Huang, Atsushi Ono
Blocked By: Blocking:

Description

Hi,

open please on any Android the mobileGallery and goto the Forms section. Now tap on any of the edit boxes. You will see that the entire view disappears. I tried many other ways as well but always same result.

Thanks,Guenter.

ps: Its my first bug report.

Attachments (1)

scrollable.patch (400 bytes) - added by Atsushi Ono 8 years ago.
[patch][ccla] Fix scroll issue

Download all attachments as: .zip

Change History (17)

comment:1 Changed 8 years ago by ykami

Cc: Chris Mitchell Ming Zhe Huang Atsushi Ono added

comment:2 Changed 8 years ago by ykami

onoat has started taking a look at this.

comment:3 Changed 8 years ago by Atsushi Ono

This is because "position:relative" is missing in body so that FixedSplitterPane's height becomes 0px. Please add "position:relative" to html,body in mobileGallery/demo_android.html.

Adding "position:relative" can solve this issue, but then I have faced another issue that ScrollableView's scroll breaks after finishing inputs and closing soft keyboard in Forms view of mobileGallery. I have attached a patch to fix this scroll issue.

Changed 8 years ago by Atsushi Ono

Attachment: scrollable.patch added

[patch][ccla] Fix scroll issue

comment:4 Changed 8 years ago by ykami

In [26813]:

Refs #14047 !strict. Call resizeAll() when the virtual keyboard is closed on Android.

comment:5 Changed 8 years ago by ykami

Thank you onoat for the patch.
Archer, I think you need to add position:relative as onoat pointed out.

comment:6 Changed 8 years ago by Chris Mitchell

In [26818]:

refs #14047 changed html,body postition:relative in mobileGallery/demo-android.html per onoat. \!strict

comment:7 Changed 8 years ago by Chris Mitchell

I made the change to the mobileGallery as recommended by onoat Guenther, Kami, et. al. please test on Android device and let me know if this now fixes the issue and we can close this out.

comment:8 Changed 8 years ago by Atsushi Ono

I verified that the fix has solved the issue on my Android device (Nexus S).

comment:9 Changed 8 years ago by Chris Mitchell

Resolution: fixed
Status: newclosed

comment:10 Changed 8 years ago by Ming Zhe Huang

Hi, I'm sorry for the delay (just got back from vacation).

The change fixed the problem. However, I have to point out that:

  1. I tested an older version in which I couldn't reproduce the problem. It looks like due to our recent change. Is it expected or a regression?
  2. Just a suggestion. If "position:relative" of <body> is mandatory for dojo mobile applications, shall we consider adding this CSS declaration to default dojo mobile theme? I checked Sencha demo (NOT source code), and they do this way. From a developer's perspective, it's quite annoying to manually add this for every application.

comment:11 Changed 8 years ago by zhangyp

our iphone demo deos not have position:relative and works. our original demo on Android also assume the default position is static and do not have problems. jQuery Mobile does nothing to the position of <body> element. I think this problems should be fixed as regression. Right now, the fix is just a work around.

comment:12 Changed 8 years ago by zhangyp

Resolution: fixed
Status: closedreopened

comment:13 in reply to:  10 Changed 8 years ago by ykami

  1. I tested an older version in which I couldn't reproduce the problem. It looks like due to our recent change. Is it expected or a regression?

Expected. We recently reduced android workaround code, which changed the behavior a little.

  1. Just a suggestion. If "position:relative" of <body> is mandatory for dojo mobile applications, shall we consider adding this CSS declaration to default dojo mobile theme?

I can understand what you mean. We should have reasonable settings by default. However, in this case, it is not always necessary, it basically depends on how user application is structured. Also some other people dislike global settings being changed secretly.

comment:14 in reply to:  12 Changed 8 years ago by ykami

Resolution: wontfix
Status: reopenedclosed

zhangyp, please understand iOS and Android have different stories. In the mobileGallery case, having position:relative is the solution to be able to work on both iOS and Android. It is quite easy to change the code so that mobileGallery works equally on both iOS and Android without position:relative, but you will then encounter flicker problems.

comment:15 Changed 8 years ago by zhangyp

Workaround is always easy than fix to the root cause of the problem. As you said, people might dislike global setting secretly. From the user's point of view, we cannot force them to set position:relative on <body> without telling them why. My point is that these problems including flicker problems are regressions because they originally works fine. Consider about the release schedule, we can fix these problems by workaround. But we should let the users know that it is a workaround and still need to spend effort to fix the root cause in the following release.

comment:16 Changed 8 years ago by ykami

zhangyp, ok I understand your point. But I don't think it is a workaround. It was actually necessary from the beginning. See test_iPad-Settings.html as an example. I vaguely remember I already talked about it with Archer a couple of times.

Note: See TracTickets for help on using tickets.