Skip to content

Commit

Permalink
chore: remove --force-renderer-accessibility
Browse files Browse the repository at this point in the history
This parameter will slightly affect the performance of the browser when loading pages with a large number of elements. Therefore, it is not enabled by default. If users need to use this feature, they may add the parameter manually.
  • Loading branch information
Bush2021 committed May 5, 2024
1 parent 8baa434 commit c41f647
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
6 changes: 5 additions & 1 deletion src/iaccessible.h
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,11 @@ bool IsDocNewTab() {
NodePtr document =
FindElementWithRole(pacc_main_window, ROLE_SYSTEM_DOCUMENT);
if (document) {
// document 的 accValue 需要添加启动参数 --force-renderer-accessibility 来获取
// The accValue of document needs to be obtained by adding the startup
// parameter --force-renderer-accessibility. However, this parameter will
// slightly affect the performance of the browser when loading pages with
// a large number of elements. Therefore, it is not enabled by default.
// If users need to use this feature, they may add the parameter manually.
GetAccessibleValue(document, [&flag](BSTR bstr) {
std::wstring_view bstr_view(bstr);
flag = bstr_view.find(L"://newtab") != std::wstring_view::npos ||
Expand Down
6 changes: 0 additions & 6 deletions src/portable.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,6 @@ std::wstring GetCommand(LPWSTR param) {
args.push_back(L"--disk-cache-dir=" + diskcache);
}

{
if (IsNewTabDisable()) {
args.push_back(L"--force-renderer-accessibility");
}
}

// 获取命令行,然后追加参数
// 截取拆分每个--开头的参数,然后多次 args.push_back
// 重复上述过程,直到字串中不再存在 -- 号
Expand Down

0 comments on commit c41f647

Please sign in to comment.