• Allan Sandfeld Jensen's avatar
    Avoid using string constructor of QJSValue for byte-array · 0c3542eb
    Allan Sandfeld Jensen authored
    
    We were returning the PDF byte-data as a javascript unicode string using
    the deprecated ascii cast constructor.
    
    This patch changes the behavior to match that of runJavaScript callbacks
    and uses a script value over QVariant.
    
    [ChangeLog][QtWebEngine] The callback version of WebEngineView::printToPdf
    is now called with a proper bytearray result instead of PDF byte data
    in a javascript string.
    
    Change-Id: I71565623465c54052568bb5ff34665baaa93e187
    Reviewed-by: default avatarMichal Klocek <michal.klocek@qt.io>
    0c3542eb