Browse Source

Pull request #12134: REPORT-96424 高级js编辑器超链国际化处理

Merge in DESIGN/design from ~OBO/design1:release/11.0 to release/11.0

* commit 'f1f5b54b5a75f37036b7d192a1efda7f34cd30cf':
  REPORT-96424 高级js编辑器超链国际化处理
  REPORT-96424 高级js编辑器超链国际化处理
release/11.0
Obo-王学仁 1 year ago
parent
commit
e594b9f4c0
  1. 12
      designer-base/src/main/java/com/fr/design/javascript/JSContentWithDescriptionPane.java

12
designer-base/src/main/java/com/fr/design/javascript/JSContentWithDescriptionPane.java

@ -20,6 +20,7 @@ import com.fr.design.javascript.jsapi.JSAPITreeHelper;
import com.fr.design.javascript.jsapi.JSAPIUserObject;
import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.general.ComparatorUtils;
import com.fr.general.GeneralContext;
import com.fr.general.http.HttpToolbox;
import com.fr.json.JSONArray;
import com.fr.json.JSONException;
@ -70,6 +71,7 @@ import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.Locale;
import java.util.concurrent.ExecutionException;
public class JSContentWithDescriptionPane extends JSContentPane implements KeyListener {
@ -393,9 +395,13 @@ public class JSContentWithDescriptionPane extends JSContentPane implements KeyLi
private void updateHelpDocuments(Object value, List<HelpDocument> helpDocuments) {
String url = LocaleLinkProvider.getInstance().getLink(PROPS_LINK_KEY, PROPS_LINK_KEY_DEFAULT) + value.toString();
try {
String result = HttpToolbox.get(url);
JSONObject jsonObject = new JSONObject(result);
JSONArray jsonArray = jsonObject.optJSONArray("list");
JSONArray jsonArray = null;
//目前简中繁中之外的语言高级编辑器功能及文档不完善,右侧展示的文档链接列表暂时为空白
if(GeneralContext.isChineseEnv()) {
String result = HttpToolbox.get(url);
JSONObject jsonObject = new JSONObject(result);
jsonArray = jsonObject.optJSONArray("list");
}
if (jsonArray != null) {
for (int i = 0; i < jsonArray.length(); i++) {
JSONObject resultJSONObject = jsonArray.optJSONObject(i);

Loading…
Cancel
Save