Package es.iiia.sgi.views

Examples of es.iiia.sgi.views.RuleView


      ShapeGrammarModel.ACTIVE_SHAPE_GRAMMAR = null;
     
      // TODO: reload views
      ShapeView shapes = (ShapeView) workbenchWindow.getActivePage()
          .findView(ShapeView.ID);
      RuleView rules = (RuleView) workbenchWindow.getActivePage()
          .findView(RuleView.ID);     

      shapes.setContent(null);
      rules.setContent(null);
     
      // recreate menu
      IEvaluationService service = (IEvaluationService) PlatformUI
          .getWorkbench().getService(IEvaluationService.class);
      service.requestEvaluation("es.iiia.sgi.propertytesters.isFileOpen");
View Full Code Here


    // find corresponding views to which we'll hook the listeners
    IWorkbenchWindow workbenchWindow = HandlerUtil
        .getActiveWorkbenchWindow(event);

    // first the shape view
    RuleView rules = (RuleView) workbenchWindow.getActivePage().findView(
        RuleView.ID);

    try {
      // Add rule
      RuleModel model = ((RuleContentProvider) rules.getContentProvider())
          .addRule(type);

      if (model != null) {
        // Create input
        ShapeGrammarInput input = new ShapeGrammarInput(model);
View Full Code Here

    ShapeGrammarInput input = new ShapeGrammarInput(model);

    // get views
    ShapeView shapes = (ShapeView) workbenchWindow.getActivePage()
        .findView(ShapeView.ID);
    RuleView rules = (RuleView) workbenchWindow.getActivePage().findView(
        RuleView.ID);

    // set view content
    shapes.setContent(input);
    rules.setContent(input);

    // recreate menu
    IEvaluationService service = (IEvaluationService) PlatformUI
        .getWorkbench().getService(IEvaluationService.class);
    service.requestEvaluation("es.iiia.sgi.propertytesters.isFileOpen");
View Full Code Here

      ShapeGrammarInput input = new ShapeGrammarInput(newModel);

      // reload views
      ShapeView shapes = (ShapeView) workbenchWindow.getActivePage()
          .findView(ShapeView.ID);
      RuleView rules = (RuleView) workbenchWindow.getActivePage()
          .findView(RuleView.ID);

      // set view content
      shapes.setContent(input);
      rules.setContent(input);

      // open rendering editor
      this.openRenderingEditor(workbenchWindow, input);

      // rereques evaluation
View Full Code Here

  public Object execute(ExecutionEvent event) throws ExecutionException {
    // Get the view
    IWorkbenchWindow window = HandlerUtil.getActiveWorkbenchWindow(event);
    IWorkbenchPage page = window.getActivePage();
   
    RuleView view = (RuleView) page.findView(RuleView.ID);
    // Get the selection
    ISelection selection = view.getSite().getSelectionProvider()
        .getSelection();
    if (selection != null && selection instanceof IStructuredSelection) {
      Object obj = ((IStructuredSelection) selection).getFirstElement();
      // If we had a selection lets open the editor
      if (obj != null) {
View Full Code Here

TOP

Related Classes of es.iiia.sgi.views.RuleView

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.