|
@@ -162,6 +162,7 @@ namespace Chromium {
|
|
|
{
|
|
|
auto openCommonPageThread = [this](SpReqAnsContext<ChromiumSrv_OpenCommonPage_Req, ChromiumSrv_OpenCommonPage_Ans>::Pointer ctx)
|
|
|
{
|
|
|
+ LOG_FUNCTION();
|
|
|
boost::unique_lock<boost::mutex> commonPageLock(m_commonPageLock);
|
|
|
std::string strTitle = ctx->Req.title.GetData();
|
|
|
std::string strUrl = ctx->Req.url.GetData();
|
|
@@ -175,6 +176,7 @@ namespace Chromium {
|
|
|
#else
|
|
|
auto srcPids = getUosBrowserPIDs(CModTools::get_mutable_instance().getUosBrowser());
|
|
|
auto ret = CModTools::get_mutable_instance().startCommonPage(strTitle, strUrl, width, height, point_x, point_y, strTop);
|
|
|
+
|
|
|
std::this_thread::sleep_for(std::chrono::seconds(2));
|
|
|
auto dstPids = getUosBrowserPIDs(CModTools::get_mutable_instance().getUosBrowser());
|
|
|
|
|
@@ -186,12 +188,15 @@ namespace Chromium {
|
|
|
std::vector<int> difference;
|
|
|
// 使用 std::set_difference 查找差值
|
|
|
std::set_difference(dstPids.begin(), dstPids.end(), srcPids.begin(), srcPids.end(), std::back_inserter(difference));
|
|
|
+ for (auto it : srcPids)
|
|
|
+ DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("srcPids %d", it);
|
|
|
+ for (auto it : dstPids)
|
|
|
+ DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("dstPids %d", it);
|
|
|
for (auto it : difference)
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("open commonPage %d", it);
|
|
|
m_commonPageArr[strTitle].push_back(it);
|
|
|
}
|
|
|
-
|
|
|
#endif
|
|
|
ctx->Answer(ret.first, ret.first);
|
|
|
};
|
|
@@ -202,6 +207,7 @@ namespace Chromium {
|
|
|
{
|
|
|
auto closePage = [this](SpReqAnsContext<ChromiumSrv_CloseCommonPage_Req, ChromiumSrv_CloseCommonPage_Ans>::Pointer ctx)
|
|
|
{
|
|
|
+ LOG_FUNCTION();
|
|
|
boost::unique_lock<boost::mutex> commonPageLock(m_commonPageLock);
|
|
|
std::string strName = ctx->Req.title.GetData();
|
|
|
#ifdef RVC_OS_WIN
|