List of usage examples for org.eclipse.jface.dialogs IMessageProvider NONE
int NONE
To view the source code for org.eclipse.jface.dialogs IMessageProvider NONE.
Click Source Link
From source file:com.mentor.nucleus.bp.debug.ui.launch.VerifiableElementComposite.java
License:Open Source License
public void updateControls() { setMessage(null, IMessageProvider.NONE); TreeItem[] items = tableTreeViewer.getTree().getItems(); if (items.length == 0) { setMessage("Error! No projects (or opened projects) exist in the workspace.", IMessageProvider.ERROR); } else if (!isElementSelected()) { setMessage("Select at least one model to verify.", IMessageProvider.ERROR); }/*from ww w .j av a 2 s. c om*/ notifyUpdateListeners(); }
From source file:com.mg.jet.birt.report.data.oda.ejbql.ui.HibernatePageHelper.java
License:Open Source License
void initCustomControl(Properties profileProps) { setPageComplete(true);/*from www . ja va 2 s. c o m*/ setMessage(DEFAULT_MESSAGE, IMessageProvider.NONE); if (profileProps == null || profileProps.isEmpty()/* || m_configLocation == null */) return; // nothing to initialize String configPath = profileProps.getProperty("HIBCONFIG"); if (configPath == null) configPath = EMPTY_STRING; m_configLocation.setText(configPath); String mapPath = profileProps.getProperty("MAPDIR"); if (mapPath == null) mapPath = EMPTY_STRING; m_mapLocation.setText(mapPath); String jndiNameStr = profileProps.getProperty("JNDI_NAME"); if (jndiNameStr == null) jndiNameStr = EMPTY_STRING; jndiName.setText(jndiNameStr); verifyConfigLocation(); }
From source file:com.mg.jet.birt.report.data.oda.ejbql.ui.HibernatePageHelper.java
License:Open Source License
private int verifyConfigLocation() { int result = 0; if (m_configLocation.getText().trim().length() > 0) { File f = new File(m_configLocation.getText().trim()); if (f.exists()) { setMessage(DEFAULT_MESSAGE, IMessageProvider.NONE); setPageComplete(true);// www .j a v a 2 s . c o m } else { setMessage(Messages.getString("wizard.dataSourcePage.cfgFileError"), IMessageProvider.ERROR); //$NON-NLS-1$ setPageComplete(false); result = ERROR_FOLDER; } } else { setMessage(Messages.getString("wizard.dataSourcePage.cfgIsEmpty"), IMessageProvider.ERROR); //$NON-NLS-1$ setPageComplete(true); result = ERROR_EMPTY_PATH; } return result; }
From source file:com.mg.merp.wb.report.birt.data.oda.badi.ui.wizards.ColumnMappingPage.java
License:Open Source License
/** * check whether the column is duplicated *//*from ww w .java2s. c o m*/ private boolean isUniqueName(String columnName, ColumnMappingElement actualElement) { boolean success = true; if (columnMap != null) { if (columnMap.get(columnName) != actualElement && columnMap.get(columnName) != null) { setDetailsMessage(OdaUiPlugin.getDefault().getFormattedString("error.columnMapping.sameColumnName", new Object[] { columnName }), IMessageProvider.ERROR); success = false; } else { setDetailsMessage(DEFAULT_PAGE_NAME, IMessageProvider.NONE); } } else { setDetailsMessage(DEFAULT_PAGE_NAME, IMessageProvider.NONE); columnMap = new HashMap<String, ColumnMappingElement>(); columnMappingList = new ArrayList<ColumnMappingElement>(); } return success; }
From source file:com.mg.merp.wb.report.birt.data.oda.badi.ui.wizards.ColumnMappingPage.java
License:Open Source License
public void pageActivated() { setDetailsMessage(DEFAULT_PAGE_NAME, IMessageProvider.NONE); this.baiCode = (String) dataSetHandle.getProperty(Constants.BAI_CODE); String infoString = (String) dataSetHandle.getQueryText(); initConnection();//from w ww.ja v a2s . c om merpConn.setRelationInformation(infoString); RelationInformation info = null; if (infoString != null && infoString.trim().length() > 0) try { //pups info = new RelationInformation(infoString); } catch (OdaException e) { throw new RuntimeException(e); } this.columnMap = new HashMap<String, ColumnMappingElement>(); this.columnMappingList = columnMappingTable.refresh(info, this.columnMap); refreshColumnMappingViewer(); setPageProperties(); }
From source file:com.microsoft.tfs.client.common.ui.controls.teamexplorer.TeamExplorerControl.java
License:Open Source License
public void showPageForItem(TeamExplorerNavigationItemConfig item) { final TeamExplorerPageConfig page = configuration.getPage(item.getTargetPageID()); if (page == null) { return;/*ww w . j a v a 2s.co m*/ } final String viewID = item.getViewID(); // viewID not null means this page can be undocked if (viewID != null && TeamExplorerHelpers.isViewUndocked(viewID)) { TeamExplorerHelpers.showView(viewID); return; } // Don't do toolkit.adapt(searchControl), as it messes up the // transparent background we want the control to use form.setHeadClient(searchControl); // Enable/disable the search control enableSearchControl(); clearToolbar(); // Save the current state of current page and sections before disposed. saveCurrentState(); // Dispose of the currently displayed page and it's state. disposeCurrentPage(); // Create the container composite for the entire page/sections content. final Composite fillComposite = toolkit.createComposite(pageComposite); // Form-style border painting not enabled (0 pixel margins OK) because // no applicable controls in this composite SWTUtil.gridLayout(fillComposite); // Layout the initial UI. Only show home or pending changes page when // offline. if (item == configuration.getHomeNavigationItem() || (!context.isConnected() && !TeamExplorerPendingChangesPage.ID.equals(page.getID()) && !TeamExplorerSettingsPage.ID.equals(page.getID()))) { // Allocate the HOME page. final TeamExplorerHomePage homePage = new TeamExplorerHomePage(configuration, navigator); homePage.getPageContent(toolkit, fillComposite, SWT.NONE, context); form.setText(Messages.getString("TeamExplorerControl.Home")); //$NON-NLS-1$ form.setMessage(getProjectAndTeamText(), IMessageProvider.NONE); item = configuration.getHomeNavigationItem(); } else { // Layout the initial state of the page and section content. The // initial state may contain place holder UI for a page header or // sections that are to be loaded in the background. A place holder // UI is replaced when its associated background processing ends and // the real UI can be generated. if (page.getID().equals(TeamExplorerPendingChangesPage.ID)) { TFSCommonUIClientPlugin.getDefault().getPendingChangesViewModel().initialize(); } createPageContent(fillComposite, page, configuration.getPageSections(page.getID())); form.setText(page.getTitle()); form.setMessage(getProjectAndTeamText(), IMessageProvider.NONE); if (viewID != null) { addUndockButton(form.getHead()); } } hookLeftClick(); // Make the newly laid out UI visible. pageCompositeStackLayout.topControl = fillComposite; handleBodyResize(); // Update the check mark on the title's context menu. currentNavItem = item; ConnectHelpers.showHideViews(context.getSourceControlCapability()); }
From source file:com.microsoft.tfs.client.common.ui.controls.teamexplorer.TeamExplorerDockableControl.java
License:Open Source License
private void createView() { if (pageComposite != null && !pageComposite.isDisposed()) { return;/*w ww. java 2s . c o m*/ } pageComposite = toolkit.createComposite(subForm.getBody()); GridDataBuilder.newInstance().fill().grab().applyTo(pageComposite); SWTUtil.gridLayout(pageComposite); final TeamExplorerPageConfig page = configuration.getPage(viewID); createPageContent(pageComposite, page, configuration.getPageSections(page.getID())); form.setText(page.getTitle()); form.setMessage(getProjectAndTeamText(), IMessageProvider.NONE); }
From source file:com.mindquarry.desktop.preferences.dialog.FilteredPreferenceDialog.java
License:Open Source License
public void updateMessage() { String message = null;/* w ww.ja va 2s . c om*/ String errorMessage = null; if (currentPage != null) { message = currentPage.getMessage(); errorMessage = currentPage.getErrorMessage(); } int messageType = IMessageProvider.NONE; if (message != null && currentPage instanceof IMessageProvider) { messageType = ((IMessageProvider) currentPage).getMessageType(); } if (errorMessage == null) { if (showingError) { // we were previously showing an error showingError = false; } } else { message = errorMessage; messageType = IMessageProvider.ERROR; if (!showingError) { // we were not previously showing an error showingError = true; } } messageArea.updateText(message, messageType); }
From source file:com.mmkarton.mx7.reportgenerator.wizards.BIRTSQLWizardPage.java
License:Open Source License
private void initializeControl() { String DEFAULT_MESSAGE = "Query"; setMessage(DEFAULT_MESSAGE, IMessageProvider.NONE); viewer.getTextWidget().setFocus(); }
From source file:com.mobilesorcery.sdk.fontsupport.internal.wizard.GenerateMOFWizard.java
License:Open Source License
public void validate() { String message = null;/*w w w. j av a2s . c o m*/ int severity = IMessageProvider.NONE; File outputFile = getOutputFile(); if (outputFile.exists()) { message = Messages.GenerateMOFWizard_9; severity = IMessageProvider.WARNING; } mofConfigPage.setMessage(message, severity); }