Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
IntraWeb 15.3.7 is out!
#1
Hi folks,

there is a new update available for IW 15:

https://www.atozed.com/2023/06/intraweb-15-3-7/

This new release contains many interesting new features. One new demo will be published soon showing this.

Also it contains our new online help (check subfolder \Help). This is the first version but we are working hard to include more content in the next releases.

Enjoy!  Big Grin
Reply
#2
Hi Alexandre,

The source code for this version doesn't seem published. Can you have a look?
Reply
#3
The browser dimensions issue below is not resolved!

https://atozed.com/forums/thread-3295.html

The dimensions are not -1 like before but they are wrong!
For example on a mobile device with browser dimensions: height:640 width:360,
the dimensions displayed are 1524 and 980!
They look more like the dimensions of the computer screen where the application is running!
Reply
#4
Yes, it is resolved.

You are not considering the Device Pixel Ratio (DPR) of the mobile device which depends on the device. DPR values between 2 and 3 are typical and it seems to be your case.

And there is absolute no way for the IW application server to have access to any browser functionality from the machine where it is running.
Reply
#5
I am sure that it is not related to the device DPR!
Because as I was explaining in the original thread, the dimensions were right for the onAsybcResize and onAsyncOrientationChange!
The dimensions were wrong only for the onRender event!
And it is still the case!
If you run the demo I posted before, you will see that the correct available browser dimensions are displayed for the onAsyncResize and onAsyncOrientationChange!

And those dimensions can be retrieved correctly from any event using the JavaScript code below:
    var available_width = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; 
    var available_height = window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight;
Reply
#6
That's exactly what IW uses to retrieve the browser dimensions. I doubt very much that any device built in the last 10 years will report anything like 640 x 360.

For instance, a Samsung Galaxy 3, released in 2012 has a screen size in pixels = 720×1280. However it doesn't mean that these are going to be the reported dimensions.

BTW, are you using any viewport tag on your page?
Reply
#7
The device I am using for test for Android OS is a Samsung J7! it is old but enough for test.
And the dimensions returned by the posted JavaScript code are exactly what I told you.
You can try on your side and you will see.
There is no viewport tag added on the demo. It is the same simple demo I posted on the thread.
Reply
#8
There are a few things that you are not considering.

When a mobile browser loads a page the first time, it checks for the "viewport" meta tag, so it will change the size (or scale) of the viewport accordingly.

If there is no viewport tag, it will use the default dimensions of the device. These are the sizes that you are reporting. I can guarantee you 200% that the values that you see is what the mobile browser is reporting as the "innerWidth" and "innerHeight". I have absolutely no doubt about this.
These numbers change later (when the Resize events run), because the viewport scaling may change when the layout is applied.

But wait, it gets worse: The sizes reported are different depending on the browser. I believe you are using some browser based on WebKit (Chrome and others). Firefox reports it differently (the same values that you would expect using a desktop browser).

To complete the mess, the resize event don't use the browser viewport sizes, but the scroll sizes, which may be different, especially in WebKit mobile browsers. Again, in Firefox they are very likely to be the same.

If you need to have the exact size of the viewport you need to use the OnResize event which will give you the correct sizes *after* the layout has been applied


Side note:
The IW code loader currently doesn't use a viewport tag, differently from the forms that will use whatever you specify in the server controller property. I'll change the code loader to use the view port tag, however it still won't give you the same result as the OnResize event, in WebKit browsers (possibly others) because of the reasons I explained above.
Reply
#9
We are building a new release that may suit your needs. I'm changing the page loader code to take in account these factors.

Please hold on
Reply
#10
Try this update:

https://www.atozed.com/2023/06/intraweb-15-3-8/

And please have in mind what I explained before. There are many issues to take into account when using browser sizes on mobile devices...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)