Jump to content
Sign in to follow this  
ianmckinnon

Default browser and Chrome

Recommended Posts

Using Remobjects I found that when using Chrome an error message about not supporting BinMessages was issued on connect to the server. I contacted André Mussche and he kindly gave us a fix to the RemobjectsSDK.js file that sorted this.

 

While on this subject the default browser does not work at all with RO. It would be nice if that could be fixed.

Share this post


Link to post
Share on other sites

Yeah, good point. The "IsSupported" feature should be implemented in the demo itself, though - and not in the IDE. The same goes for WebGl and a few other "browser fragile" features...

 

We have a few methods already.

 

Try, for instance, to put this into the "ApplicationStarting" method of some of the demos:

 

 
  if w3_getIsIPhone then 
    ShowMessage('iPhone!'); 

 

That will give you a messagebox at startup on iPhone, but not in the embedded browser... (Enter the url in the status-bar into your Safari Mobile browser to test).

 

In the W3System unit, you also find these methods:

 
function w3_getIsIPad: Boolean; 
function w3_getIsIPhone: Boolean; 
function w3_getIsIPod: Boolean; 
function w3_getIsAndroid: Boolean; 
function w3_getIsSafari: Boolean; 
function w3_getIsFirefox: Boolean; 
function w3_getIsChrome: Boolean; 
function w3_getIsInternetExplorer: Boolean; 
function w3_getIsOpera: Boolean; 

 

 

Share this post


Link to post
Share on other sites

The supported feature appears to be essential. With André's help we now have a very much better working copy of the RO.js. With that I am able to use safari, both on the PC and on a mobile. The bad news is the display does not behave as in other browsers.

 

I am building all my components at run time, their size and position. One panel I am placing in the center of the top of the screen. In safari that panel is on the left, not the center. Worse still if I display (showmessage) the left position, the panel is placed in the right spot, otherwise not. A second panel on the center vertically on the right of the screen (rotated - angle 270) it appears on the top as if the top is zero, but if I use zero its left position is wrong.

 

Can that behaviour be explained?

Share this post


Link to post
Share on other sites

Hm. This sounds very odd. The origo for the controls is defined by the CSS. I know there are differences, but i never encountered this. Could i bother you to send me the project or a compiled version? Just so i can pinpoint where the problems may be? Have you altered the CSS positioning? Sounds to me that your components have gone from absolute to relative positioning.

Share this post


Link to post
Share on other sites

Odd indeed. Further investigation (1 brief test) found that if I set the top after the left it seems OK. I found this before with some situations, the order properties are set can effect the results. What I am doing in this case is creating the component, setting left, then top, then later changing the left. This resets the top to zero.

 

BTW the new RO.js has fixed the default browser problem - great :-)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×