a bug of view.msgbox from 3.3.3.3

Sciter Forums Bug reports a bug of view.msgbox from 3.3.3.3

This topic contains 1 reply, has 2 voices, and was last updated by  Andrew 7 months ago.

  • Author
    Posts
  • #49031

    gxlmyacc
    Participant

    Hi, Andrew, see this code:

    <html>
     <head>
      <script type="text/tiscript">
        function prompt(text, defaultText = "", title = "确认 对话框", buttons = [{id:#ok, text:"确定"}, {id:#cancel, text:"取消"}]) {
          var result = null;
          view.msgbox {
            content: "<label>"+text+"</label><br/><input|text #input style='display:block;width:1*;' />", 
            title:   title, 
            buttons: buttons,
            onLoad:  
              function(root){ 
                if (defaultText) 
                  root.$(#input).value = defaultText; 
                },
            onClose: 
              function (root,buttonSym) { 
                if (buttonSym == #ok) 
                  result = root.$(#input).value;
                return true; 
              }  
          };   
          return result;
        }
       function self#test.onClick(){
         prompt("dd");
       }
         
      </script>
     </head>
     <body >
       <input|button #test value="test" />
     </body>
    </html>

    click test button, it should show a dialog which has a edit input control:
    https://p1.bpimg.com/567571/5fe57622f9c5d141.png
    It has been good until the 3.3.3.3 version:
    https://p1.bpimg.com/567571/4ea7c26381efc7a6.png

    • This topic was modified 7 months ago by  gxlmyacc.
    • This topic was modified 7 months ago by  gxlmyacc.
  • #49035

    Andrew
    Keymaster

    Thanks, fixed here.

You must be logged in to reply to this topic.