Esempio n. 1
0
    protected string GetCmdStrResult(string cmd)
    {
        JSValue result = bTex.ExecuteJavaScriptWithResult(cmd);

        if (result != null && result.Type != JSValueType.Null)
        {
            return(result.ToString());
        }
        return("");
    }
Esempio n. 2
0
    public static void MinimizeGoogleDocMenus(CollabBrowserTexture bTex)
    {
        string  cmd  = "var elem = document.getElementById(\"viewModeButton\"); if( elem != null ){var attr = elem.getAttribute(\"data-tooltip\"); if(attr != null && attr.indexOf(\"Hide\") != -1){elem.getBoundingClientRect();}}";
        JSValue rect = bTex.ExecuteJavaScriptWithResult(cmd);

        if (rect != null && rect.Type != JSValueType.Null)
        {
            bTex.ClickOnTopCenterOfObject(rect.GetObject());
        }
    }