diff --git a/resources/web/homepage2/js/left.js b/resources/web/homepage2/js/left.js index a5812b91b..72dd48f8a 100644 --- a/resources/web/homepage2/js/left.js +++ b/resources/web/homepage2/js/left.js @@ -24,6 +24,20 @@ function HandleStudio( pVal ) { SetUserOffline(); } + else if( strCmd=="network_plugin_installtip" ) + { + let nShow=pVal["show"]*1; + + if(nShow==1) + { + $("#NoPluginTip").show(); + $("#NoPluginTip").css("display","flex"); + } + else + { + $("#NoPluginTip").hide(); + } + } else if(strCmd=='homepage_leftmenu_clicked') { let NewMenu=pVal['menu']; @@ -52,7 +66,7 @@ function GotoMenu( strMenu ) { ShowMenuNewTag(strMenu,0); - if(NowMenu==strMenu) + if(NowMenu==strMenu && strMenu!='makerlab') return; NowMenu=strMenu; @@ -184,6 +198,14 @@ function SendMsg_CheckNewTag() SendWXMessage( JSON.stringify(tSend) ); } +function BeginDownloadNetworkPlugin() +{ + var tSend={}; + tSend['sequence_id']=Math.round(new Date() / 1000); + tSend['command']="begin_network_plugin_download"; + + SendWXMessage( JSON.stringify(tSend) ); +} //---------------Global----------------- window.postMessage = HandleStudio; diff --git a/src/slic3r/GUI/WebViewDialog.cpp b/src/slic3r/GUI/WebViewDialog.cpp index 71d36a6df..5f4b39024 100644 --- a/src/slic3r/GUI/WebViewDialog.cpp +++ b/src/slic3r/GUI/WebViewDialog.cpp @@ -661,7 +661,7 @@ void WebViewPanel::ShowNetpluginTip() wxString strJS = wxString::Format("window.postMessage(%s)", m_Res.dump(-1, ' ', false, json::error_handler_t::ignore)); - RunScript(strJS); + RunScriptLeft(strJS); } void WebViewPanel::get_design_staffpick(int offset, int limit, std::function callback)