package com.organization4242.delmgorb.View;

import com.organization4242.delmgorb.Model.PlotModel;
import net.ericaro.surfaceplotter.JSurfacePanel;

import javax.swing.*;
import java.awt.*;

/**
 * Created by ilya-murzinov on 22.02.14.
 */
public class PlotView extends JPanel {
    private PlotModel model;

    public PlotView(PlotModel model) {
        this.model = model;
        initComponents();
    }

    private void initComponents() {
        JSurfacePanel surfacePanel = new JSurfacePanel(model.getModel());
        setLayout(new BorderLayout());
        model.getModel().plot().execute();
        surfacePanel.setTitleText("title");
        surfacePanel.setBackground(Color.white);
        surfacePanel.setConfigurationVisible(true);
        add(surfacePanel, BorderLayout.CENTER);
    }
}

@@ -280,29 +280,32 @@
     
-private PlotModel mod
+JSurfacePanel surfacePan
 el;%0A
@@ -348,36 +348,8 @@
 ) %7B%0A
-        this.model = model;%0A
     
@@ -375,16 +375,105 @@
 );%0A    %7D
+%0A    %0A    public void setTitleText(text) %7B%0A        surfacePanel.setTitleText(text);%0A    %7D
 %0A%0A    pr
@@ -506,38 +506,24 @@
 ) %7B%0A        
-JSurfacePanel 
 surfacePanel
@@ -648,52 +648,8 @@
 ();%0A
-        surfacePanel.setTitleText(%22title%22);%0A
     

Update PlotView.java