Jump to content

Smart Mobile Studio 3.9.1 (1st Alpha release) is available


Recommended Posts

  • 1 month later...
  • Replies 53
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

We are proud to release Smart Mobile Studio 3.9.1. This is the first Alpha release of the upcoming Smart Mobile Studio 4.0. The biggest improvement is the new WYSIWYG Designer, which takes developing

2nd Alpha release of the upcoming version 4.0 is now available. You can install it with SmartUpdate from the ALPHA-channel. If you have installed the first alpha release, you can simply run SmartUpdat

New update is available. This is probably the last alpha release. RTL: Add TabOrder-property Make TW3Label, TW3Display and TW3DisplayView not focusable Set TabOrder for these

Posted Images

Did something change in the WebSocket code?   I had a project working on an earlier Alpha (don't recall which one) and I updated to the latest.  Now when I call connect my server sees the connection and makes it but the callback never is called now.  Couple of weird things I observe:  

1) I was using this:

procedure TTabSettingsForm.W3ButtonConnectionClick(Sender: TObject);
var
  URL: string;

begin
  if FSocket.Connected or FConnected then
  begin
    FSocket.Disconnect(
      procedure (Socket: TW3WebSocket; Success: boolean)   <<<< No Blue dots in IDE from here to 
      begin
        if Success then
        begin
          W3ButtonConnection.Caption := 'Connect';
          W3ButtonStartNode.Enabled := False;
        end else
        begin
          W3ButtonConnection.Caption := 'Disconnect';
          W3ButtonStartNode.Enabled := True;
        end;
      end )
  end else
  begin                                                <<<<< Here

 

So I created a callback function explicitly

 

  end else
  begin
    URL := 'ws://' + W3EditBoxIpAddress.Text + ':' + W3EditBoxIpPort.Text;
    try
      if W3CheckBoxTcp.Checked then
        FSocket.BinaryMessageDataType := wdtArrayBuffer;
      FSocket.Connect(URL, ['openlcb.websocket'], @WebSocketConnectCallback);
procedure TTabSettingsForm.WebSocketConnectCallback(Socket: TW3WebSocket; Success: Boolean);
begin
  if Success then
  begin
    W3ButtonConnection.Caption := 'Disconnect';
    W3ButtonStartNode.Enabled := True;
  //    W3ButtonStartNodeClick(W3ButtonStartNode);
  end else
  begin
    W3ButtonConnection.Caption := 'Connect';
    W3ButtonStartNode.Enabled := False;
  end;
end;

Now it has blue dots on all the code but this function is never called even though the server says there is a connection.

 

Jim

Link to post
Share on other sites
  • 2 weeks later...
  • Administrators

A new update is available. This one contains two new controls:

  •     TW3GoogleLogin
  •     TW3FacebookLogin

Both are non-visual components, but they are available in the Designer under the Cloud-tab.

These two controls let you add Single-Sign-On via Google and Facebook to your web page. To use them,

  • Add the control to the form
  • Set the AppId- or ClientId-properties
    • You need to register at Google or Facebook to get these ids
    • You also need to copy the app to the registered URI that you specify during registration
  • Set the OnLogin and OnLogout -events
  • Finally, set Enabled to True
  • Copy the compiled app to your web server and test

Documentation:

TW3GoogleLogin

TW3FacebookLogin

Note! When writing this, there is a problem with Facebook's API and Firefox browser. This problem is not related to Smart Mobile Studio at all, but affects any Facebook logins in Firefox. Refer to these URLs for more information:

https://support.mozilla.org/en-US/questions/1130053
https://stackoverflow.com/questions/33855626/firefox-blocking-facebook-js

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...