Jump to content
uniGUI Discussion Forums

hph

uniGUI Subscriber
  • Content Count

    56
  • Joined

  • Last visited

  • Days Won

    3

hph last won the day on March 6

hph had the most liked content!

Community Reputation

5 Neutral

About hph

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. hph

    AddJS() don't execute

    procedure TUniServerModule.UniGUIServerModuleHTTPCommand( ARequestInfo: TIdHTTPRequestInfo; AResponseInfo: TIdHTTPResponseInfo; var Handled: Boolean); var sid: TUniGUISession; ActiveSessions : TUniGUISessions; I : Integer; begin if ARequestInfo.URI='/test/send' then begin SessionManager.Sessions.Lock; ActiveSessions := UniServerModule.SessionManager.Sessions; try for I := 0 to ActiveSessions.SessionList.Count -1 do begin sid := ActiveSessions.SessionList[I]; sid.AddJS('doShowText("Hello")'); // --- dont execute!?! end; finally SessionManager.Sessions.Unlock; end; AResponseInfo.ResponseNo := 200; AResponseInfo.ContentText := 'success'; AResponseInfo.WriteContent; Handled := True; end; end; Hi Why is this javascript function doShowText() in this active session not executing? It works if I call directly from UnimForm.UniSession.AddJS(), but not over the SessionManager...? best regards
  2. Hi I tested it on iPad mini / iPad pro (under ios 9.3.5 / 12.1.4) also android (samsung): no problem! Are you shure, you have the right setup?
  3. @A.soltani Meaby this helps: socket.on('message', function(evt){ document.getElementById('log').innerHTML = evt.message; ajaxRequest(MainForm.window, "_message",["msgStr=" + evt.message]); }); and this?: function start_sse(param) { socket = new sgcWebSocket(param); ... I have updated the example, hope it helps you ;-) webSocket.zip
  4. Hi It is a part of the offical esegece websocket package. You will find it in: \sgcWebSockets\resources\
  5. Hi In attach a small example. As websocket server, use: <sgcWebSockets\Demos\ServerSentEvents> and disable this: procedure TfrmServer.pageMainHTMLTag(Sender: TObject; Tag: TTag; const TagString: string; TagParams: TStrings; var ReplaceText: string); begin // if TagString = 'port' then // ReplaceText := IntToStr(WSServer.Port) // else if TagString = 'host' then // ReplaceText := '127.0.0.1'; end; Add in UniServerModul.CustomFiles (file is not available in the example): files/sgcWebSockets.min.js Hope it helps webSocket.zip
  6. hph

    BadgeText color unimButton

    Hi Sherzod Thank you very much, it works perfectly!! best regards
  7. hph

    BadgeText color unimButton

    Hi Sherzod Very thank you, it works fine! But, how can I change the color (or other badge properties) in runtime? best regards
  8. Hi How can i change the badgetext background color in a unimButton?
  9. hph

    Mobile FullScreen

    Hi Meaby this can help you: https://www.netguru.com/codestories/few-tips-that-will-make-your-pwa-on-ios-feel-like-native https://developer.apple.com/library/archive/documentation/AppleApplications/Reference/SafariWebContent/ConfiguringWebApplications/ConfiguringWebApplications.html You can add the meta tags to UniServerModule.CustomMeta(), like this (works with ios): <!-- icons --> <link rel="apple-touch-icon" href="touch-icon-iphone.png"> <link rel="apple-touch-icon" sizes="20x20" href="files/images/ios/AppIcon.1.0/Icon-20x20@1x.png"> <link rel="apple-touch-icon" sizes="40x40" href="files/images/ios/AppIcon.1.0/Icon-20x20@2x.png"> <link rel="apple-touch-icon" sizes="60x60" href="files/images/ios/AppIcon.1.0/Icon-20x20@3x.png"> <link rel="apple-touch-icon" sizes="29x29" href="files/images/ios/AppIcon.1.0/Icon-29x29@1x.png"> <link rel="apple-touch-icon" sizes="58x58" href="files/images/ios/AppIcon.1.0/Icon-29x29@2x.png"> <link rel="apple-touch-icon" sizes="87x87" href="files/images/ios/AppIcon.1.0/Icon-29x29@3x.png"> <link rel="apple-touch-icon" sizes="80x80" href="files/images/ios/AppIcon.1.0/Icon-40x40@2x.png"> <link rel="apple-touch-icon" sizes="120x120" href="files/images/ios/AppIcon.1.0/Icon-40x40@3x.png"> <link rel="apple-touch-icon" sizes="120x120" href="files/images/ios/AppIcon.1.0/Icon-60x60@2x.png"> <link rel="apple-touch-icon" sizes="180x180" href="files/images/ios/AppIcon.1.0/Icon-60x60@3x.png"> <link rel="apple-touch-icon" sizes="76x76" href="files/images/ios/AppIcon.1.0/Icon-76x76@1x.png"> <link rel="apple-touch-icon" sizes="152x152" href="files/images/ios/AppIcon.1.0/Icon-76x76@2x.png"> <link rel="apple-touch-icon" sizes="334x334" href="files/images/ios/AppIcon.1.0/Icon-83.5@2x.png"> <!-- fullscreen webapp --> <meta name="apple-mobile-web-app-capable" content="yes"> <meta name="apple-mobile-web-app-title" content="myApp"> After call your webapp in safari via url and link it to your homescreen. You can then open your app via this icon and you will have a fullscreen webapp ;-)
  10. I'm interresting, do you have a example for this popup menu?
  11. Any news about this? I have the same problem! Thanks
  12. hph

    TUniNativeImageList AddIconsCls

    Hi GerhardV Many thanks for your detailed suggestion! It works bretty, but it's not what I was looking for. I need my own font-icon library, because I can easly create it with the icon8 library. It works very well for each component like UniSpeedbutton, UniLabel etc. (html text), but the only thing I'm missing is to use this custom css library with the TUniNativeImageList component! thanks and best regards
  13. Hi zemorango A question, how did you implement that menu-popup?:
  14. You can try this: CustomCSS: .custom-grid .x-grid-item-focused .x-grid-cell-inner:before { border: none !important; } ... and UniEvents: function beforeInit(sender, config) { config.cls = 'custom-grid'; }
×