Search in sources :

Example 1 with LeafNodeFigure

use of com.cubrid.cubridmanager.ui.replication.editor.figures.LeafNodeFigure in project cubrid-manager by CUBRID.

the class LeafNodePart method refreshVisuals.

/**
	 * @see com.cubrid.cubridmanager.ui.replication.editor.parts.NodePart#refreshVisuals()
	 */
protected void refreshVisuals() {
    super.refreshVisuals();
    LeafNode node = (LeafNode) getModel();
    LeafNodeFigure figure = (LeafNodeFigure) getFigure();
    figure.setText(node.getName());
    if (getModel() instanceof MasterNode) {
        figure.setIcon(CubridManagerUIPlugin.getImage("icons/replication/master.png"));
    }
    if (getModel() instanceof DistributorNode) {
        figure.setIcon(CubridManagerUIPlugin.getImage("icons/replication/distributor.gif"));
    }
    if (getModel() instanceof SlaveNode) {
        figure.setIcon(CubridManagerUIPlugin.getImage("icons/replication/slave.png"));
    }
}
Also used : MasterNode(com.cubrid.cubridmanager.ui.replication.editor.model.MasterNode) SlaveNode(com.cubrid.cubridmanager.ui.replication.editor.model.SlaveNode) LeafNode(com.cubrid.cubridmanager.ui.replication.editor.model.LeafNode) LeafNodeFigure(com.cubrid.cubridmanager.ui.replication.editor.figures.LeafNodeFigure) DistributorNode(com.cubrid.cubridmanager.ui.replication.editor.model.DistributorNode)

Aggregations

LeafNodeFigure (com.cubrid.cubridmanager.ui.replication.editor.figures.LeafNodeFigure)1 DistributorNode (com.cubrid.cubridmanager.ui.replication.editor.model.DistributorNode)1 LeafNode (com.cubrid.cubridmanager.ui.replication.editor.model.LeafNode)1 MasterNode (com.cubrid.cubridmanager.ui.replication.editor.model.MasterNode)1 SlaveNode (com.cubrid.cubridmanager.ui.replication.editor.model.SlaveNode)1