Changeset 3629 for devel-tools


Ignore:
Timestamp:
Mar 30, 2008, 9:48:20 PM (13 years ago)
Author:
yura
Message:
  • Step filters throuth Refal Runtime.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • devel-tools/trunk/eclipse/org.refal.rfpdt.ui/src/org/refal/rfpdt/ui/launching/RfpRefalMainTab.java

    r3627 r3629  
    2121import org.eclipse.swt.widgets.Group;
    2222import org.eclipse.swt.widgets.Text;
     23import org.refal.rfpdt.core.RfpCore;
     24import org.refal.rfpdt.ui.RfpUI;
    2325
    2426public class RfpRefalMainTab extends AbstractLaunchConfigurationTab {
     
    2628    private Text fModuleText;
    2729    private Button fStopInMainCheckButton;
     30    private Button fRuntimeFilterButton;
    2831
    2932    public void createControl (Composite parent) {
     
    3437        createProjectEditor(comp);
    3538        createModuleEditor(comp);
     39        createRuntimeFilterEditor(comp);
    3640        // GridData gd;
    3741        //             
     
    127131    }
    128132
     133    private void createRuntimeFilterEditor (Composite parent) {
     134        Font font = parent.getFont();
     135        fRuntimeFilterButton = new Button(parent, SWT.CHECK);
     136        fRuntimeFilterButton.setText("Step filters throuth Refal Runtime");
     137        fRuntimeFilterButton.setFont(font);
     138        fRuntimeFilterButton.addSelectionListener(new SelectionListener() {
     139            public void widgetDefaultSelected (SelectionEvent e) {
     140                updateLaunchConfigurationDialog();
     141            }
     142
     143            public void widgetSelected (SelectionEvent e) {
     144                updateLaunchConfigurationDialog();
     145            }
     146        });
     147        // fProjButton = createPushButton(group, LauncherMessages.AbstractJavaMainTab_1, null);
     148        // fProjButton.addSelectionListener(fListener);
     149    }
     150   
    129151    public void initializeFrom (ILaunchConfiguration config) {
    130152        String projectName = "";
    131153        String moduleName = "";
    132154        boolean stopInMain = false;
     155        boolean runtimeFilter = true;
    133156        try {
    134157            projectName = config.getAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, "");
    135158            moduleName = config.getAttribute(IJavaLaunchConfigurationConstants.ATTR_MAIN_TYPE_NAME, "");
    136159            stopInMain = config.getAttribute(IJavaLaunchConfigurationConstants.ATTR_STOP_IN_MAIN, false);
    137         } catch (CoreException ce) {
    138             // CorePlugin.log(ce);
     160            runtimeFilter = config.getAttribute(RfpCore.RUNTIME_FILTER, true);
     161        } catch (CoreException e) {
     162            RfpUI.log(e);
    139163        }
    140164        fProjectText.setText(projectName);
    141165        fModuleText.setText(moduleName);
    142166        fStopInMainCheckButton.setSelection(stopInMain);
     167        fRuntimeFilterButton.setSelection(runtimeFilter);
    143168    }
    144169
     
    150175        else
    151176            config.setAttribute(IJavaLaunchConfigurationConstants.ATTR_STOP_IN_MAIN, (String) null);
     177        if (fRuntimeFilterButton.getSelection())
     178            config.setAttribute(RfpCore.RUNTIME_FILTER, (String) null);
     179        else
     180            config.setAttribute(RfpCore.RUNTIME_FILTER, false);
    152181    }
    153182
Note: See TracChangeset for help on using the changeset viewer.