Browse Source

fix conflict

master
abel.chen 7 years ago
parent
commit
572443eb7d
  1. 11
      designer-realize/src/main/java/com/fr/design/mainframe/socketio/DesignerSocketIO.java
  2. 7
      designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java

11
designer-realize/src/main/java/com/fr/design/mainframe/socketio/DesignerSocketIO.java

@ -2,9 +2,11 @@ package com.fr.design.mainframe.socketio;
import com.fr.config.RemoteEvent; import com.fr.config.RemoteEvent;
import com.fr.decision.webservice.utils.DecisionServiceConstants; import com.fr.decision.webservice.utils.DecisionServiceConstants;
import com.fr.design.mainframe.DesignerContext;
import com.fr.design.mainframe.loghandler.DesignerLogHandler; import com.fr.design.mainframe.loghandler.DesignerLogHandler;
import com.fr.env.operator.socket.SocketInfoOperator; import com.fr.env.operator.socket.SocketInfoOperator;
import com.fr.event.EventDispatcher; import com.fr.event.EventDispatcher;
import com.fr.general.Inter;
import com.fr.general.LogRecordTime; import com.fr.general.LogRecordTime;
import com.fr.general.LogUtils; import com.fr.general.LogUtils;
import com.fr.log.FineLoggerFactory; import com.fr.log.FineLoggerFactory;
@ -17,6 +19,8 @@ import io.socket.client.IO;
import io.socket.client.Socket; import io.socket.client.Socket;
import io.socket.emitter.Emitter; import io.socket.emitter.Emitter;
import javax.swing.JOptionPane;
import javax.swing.UIManager;
import java.io.ByteArrayInputStream; import java.io.ByteArrayInputStream;
import java.io.IOException; import java.io.IOException;
import java.net.URI; import java.net.URI;
@ -64,6 +68,13 @@ public class DesignerSocketIO {
EventDispatcher.fire(RemoteEvent.EDIT, param); EventDispatcher.fire(RemoteEvent.EDIT, param);
} }
}); });
socketIO.get().on(Socket.EVENT_DISCONNECT, new Emitter.Listener() {
@Override
public void call(Object... objects) {
JOptionPane.showMessageDialog(DesignerContext.getDesignerFrame(), Inter.getLocText(new String[]{"Fine-Designer_Basic_Remote_Disconnected"}),
null, 0, UIManager.getIcon("OptionPane.errorIcon"));
}
});
socketIO.get().connect(); socketIO.get().connect();
} catch (Exception e) { } catch (Exception e) {
FineLoggerFactory.getLogger().error(e.getMessage(), e); FineLoggerFactory.getLogger().error(e.getMessage(), e);

7
designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java

@ -51,8 +51,6 @@ import com.fr.design.mainframe.loghandler.DesignerLogAppender;
import com.fr.design.mainframe.loghandler.DesignerLogImpl; import com.fr.design.mainframe.loghandler.DesignerLogImpl;
import com.fr.design.mainframe.loghandler.LogMessageBar; import com.fr.design.mainframe.loghandler.LogMessageBar;
import com.fr.design.mainframe.socketio.DesignerSocketIO; import com.fr.design.mainframe.socketio.DesignerSocketIO;
import com.fr.env.operator.socket.FineSocketInfoOperator;
import com.fr.env.operator.socket.SocketInfoOperator;
import com.fr.design.module.DesignModuleFactory; import com.fr.design.module.DesignModuleFactory;
import com.fr.design.parameter.FormParameterReader; import com.fr.design.parameter.FormParameterReader;
import com.fr.design.parameter.ParameterPropertyPane; import com.fr.design.parameter.ParameterPropertyPane;
@ -100,8 +98,6 @@ import com.fr.stable.script.ValueConverter;
import com.fr.stable.xml.ObjectTokenizer; import com.fr.stable.xml.ObjectTokenizer;
import com.fr.stable.xml.ObjectXMLWriterFinder; import com.fr.stable.xml.ObjectXMLWriterFinder;
import com.fr.start.BBSGuestPaneProvider; import com.fr.start.BBSGuestPaneProvider;
import com.fr.workspace.base.WorkspaceKey;
import com.fr.workspace.pool.WorkPRCRegister;
import com.fr.xml.ReportXMLUtils; import com.fr.xml.ReportXMLUtils;
import java.awt.Image; import java.awt.Image;
@ -413,8 +409,5 @@ public class DesignerActivator extends Activator implements Prepare {
public void prepare() { public void prepare() {
addMutable(InterMutableKey.Path, "com/fr/design/i18n/main", "com/fr/design/i18n/chart"); addMutable(InterMutableKey.Path, "com/fr/design/i18n/main", "com/fr/design/i18n/chart");
addMutable(WorkspaceKey.RPC, WorkPRCRegister.wrap(SocketInfoOperator.class, new FineSocketInfoOperator()));
} }
} }
Loading…
Cancel
Save