@OnStart public void onStart(final Path path, final PlaceRequest request) { this.path = path; this.isReadOnly = request.getParameter("readOnly", null) == null ? false : true; multiPage.addWidget(view, CommonConstants.INSTANCE.EditTabTitle()); multiPage.addPage( new Page(viewSource, CommonConstants.INSTANCE.SourceTabTitle()) { @Override public void onFocus() { factModelService .call( new RemoteCallback<String>() { @Override public void callback(final String response) { viewSource.setContent(response); } }) .toSource(view.getContent()); } @Override public void onLostFocus() { viewSource.clear(); } }); multiPage.addWidget(importsWidget, CommonConstants.INSTANCE.ConfigTabTitle()); multiPage.addWidget(metadataWidget, CommonConstants.INSTANCE.MetadataTabTitle()); loadContent(); }
@Inject public ScenarioEditorViewImpl( final @New ImportsWidgetPresenter importsWidget, final @New MultiPageEditor multiPage, final @New MetadataWidget metadataWidget, final @New BulkRunTestScenarioEditor bulkRunTestScenarioEditor, Caller<MetadataService> metadataService, final Event<NotificationEvent> notification, final BusyIndicatorView busyIndicatorView) { this.importsWidget = importsWidget; this.multiPage = multiPage; this.metadataWidget = metadataWidget; this.metadataService = metadataService; this.notification = notification; this.busyIndicatorView = busyIndicatorView; this.bulkRunTestScenarioEditor = bulkRunTestScenarioEditor; multiPage.addWidget(layout, "Test Scenario"); layout.setWidth("100%"); multiPage.addWidget(importsWidget, CommonConstants.INSTANCE.ConfigTabTitle()); }