Browse Source

Merge pull request #511 in DESIGN/design from ~ALEX.SUNG/design:release/10.0 to release/10.0

REPORT-11523 @Sung:mac下alphafine打开网页超链有问题

* commit 'c117c537f3411469b7501985b27f3374a8b8e856':
  REPORT-11523 @Sung:mac下alphafine打开网页超链有问题
final/10.0
Alex.Sung 6 years ago
parent
commit
20b2bc9750
  1. 4
      designer-realize/src/main/java/com/fr/design/mainframe/alphafine/cell/model/RobotModel.java

4
designer-realize/src/main/java/com/fr/design/mainframe/alphafine/cell/model/RobotModel.java

@ -7,6 +7,7 @@ import com.fr.json.JSONException;
import com.fr.json.JSONObject; import com.fr.json.JSONObject;
import com.fr.log.FineLoggerFactory; import com.fr.log.FineLoggerFactory;
import com.fr.stable.AssistUtils; import com.fr.stable.AssistUtils;
import com.fr.stable.EncodeConstants;
import com.fr.stable.StringUtils; import com.fr.stable.StringUtils;
import org.apache.commons.codec.digest.DigestUtils; import org.apache.commons.codec.digest.DigestUtils;
@ -14,6 +15,7 @@ import java.awt.Desktop;
import java.io.IOException; import java.io.IOException;
import java.net.URI; import java.net.URI;
import java.net.URISyntaxException; import java.net.URISyntaxException;
import java.net.URLEncoder;
/** /**
* Created by alex.sung on 2018/8/3. * Created by alex.sung on 2018/8/3.
@ -85,7 +87,7 @@ public class RobotModel extends AlphaCellModel {
@Override @Override
public void doAction() { public void doAction() {
try { try {
Desktop.getDesktop().browse(new URI(AlphaFineConstants.ALPHA_PREVIEW + super.getName())); Desktop.getDesktop().browse(new URI(AlphaFineConstants.ALPHA_PREVIEW + URLEncoder.encode(super.getName(), EncodeConstants.ENCODING_UTF_8)));
} catch (IOException e) { } catch (IOException e) {
FineLoggerFactory.getLogger().error(e.getMessage()); FineLoggerFactory.getLogger().error(e.getMessage());
} catch (URISyntaxException e) { } catch (URISyntaxException e) {

Loading…
Cancel
Save