本文整理汇总了Java中org.eclipse.ui.progress.IProgressConstants类的典型用法代码示例。如果您正苦于以下问题:Java IProgressConstants类的具体用法?Java IProgressConstants怎么用?Java IProgressConstants使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IProgressConstants类属于org.eclipse.ui.progress包,在下文中一共展示了IProgressConstants类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createInitialLayout
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
@Override
public void createInitialLayout(IPageLayout layout) {
String editorArea = layout.getEditorArea();
IFolderLayout left = layout.createFolder("left", IPageLayout.LEFT, (float) 0.25, editorArea); //$NON-NLS-1$
left.addView(IPageLayout.ID_PROJECT_EXPLORER);
left.addPlaceholder(IPageLayout.ID_RES_NAV);
IFolderLayout bottom = layout.createFolder("bottom", IPageLayout.BOTTOM, (float) 0.75, editorArea); //$NON-NLS-1$
bottom.addView("org.eclipse.tm.terminal.view.ui.TerminalsView");
bottom.addView(IPageLayout.ID_PROBLEM_VIEW);
bottom.addPlaceholder(TemplatesView.ID);
bottom.addPlaceholder(NewSearchUI.SEARCH_VIEW_ID);
bottom.addPlaceholder(IConsoleConstants.ID_CONSOLE_VIEW);
bottom.addPlaceholder(IPageLayout.ID_BOOKMARKS);
bottom.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
bottom.addPlaceholder(IPageLayout.ID_TASK_LIST);
bottom.addPlaceholder(IPageLayout.ID_PROP_SHEET);
layout.addView(IPageLayout.ID_OUTLINE, IPageLayout.RIGHT, (float) 0.75, editorArea);
}
示例2: doFinish
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
/**
* Called when the job is finished.
*/
protected void doFinish()
{
// setProperty(IProgressConstants.ICON_PROPERTY, image);
if (AbstractJob.isModal(this))
{
Display.getDefault().asyncExec(new Runnable() {
public void run()
{
getJobCompletedAction().run();
}
});
} else
{
setProperty(IProgressConstants.KEEP_PROPERTY, Boolean.TRUE);
setProperty(IProgressConstants.ACTION_PROPERTY, getJobCompletedAction());
}
}
示例3: createInitialLayout
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
@Override
public void createInitialLayout(IPageLayout layout) {
String editorArea = layout.getEditorArea();
IFolderLayout left = layout.createFolder("left", IPageLayout.LEFT, (float) 0.25, editorArea); //$NON-NLS-1$
left.addView(IPageLayout.ID_PROJECT_EXPLORER);
left.addPlaceholder(IPageLayout.ID_RES_NAV);
IFolderLayout bottom = layout.createFolder("bottom", IPageLayout.BOTTOM, (float) 0.75, editorArea); //$NON-NLS-1$
bottom.addView("org.eclipse.tm.terminal.view.ui.TerminalsView");
bottom.addView(IPageLayout.ID_PROBLEM_VIEW);
bottom.addPlaceholder(TemplatesView.ID);
bottom.addPlaceholder(NewSearchUI.SEARCH_VIEW_ID);
bottom.addPlaceholder(IConsoleConstants.ID_CONSOLE_VIEW);
bottom.addPlaceholder(IPageLayout.ID_BOOKMARKS);
bottom.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
bottom.addPlaceholder(IPageLayout.ID_TASK_LIST);
bottom.addPlaceholder(IPageLayout.ID_PROP_SHEET);
layout.addView(IPageLayout.ID_OUTLINE, IPageLayout.RIGHT, (float) 0.75, editorArea);
}
示例4: addFolders
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
protected void addFolders(IPageLayout layout) {
IFolderLayout leftFolder = layout.createFolder("left", IPageLayout.LEFT, (float) 0.2, //$NON-NLS-1$
layout.getEditorArea());
leftFolder.addView(DLTKUIPlugin.ID_SCRIPT_EXPLORER);
leftFolder.addView("org.eclipse.dltk.testing.ResultView"); //$NON-NLS-1$
leftFolder.addPlaceholder("org.eclipse.dltk.ui.TypeHierarchy"); //$NON-NLS-1$
leftFolder.addPlaceholder(IPageLayout.ID_BOOKMARKS);
IFolderLayout bottomFolder = layout.createFolder("bottom", IPageLayout.BOTTOM, (float) 0.75, //$NON-NLS-1$
layout.getEditorArea());
bottomFolder.addView(IPageLayout.ID_PROBLEM_VIEW);
bottomFolder.addView(IPageLayout.ID_TASK_LIST);
bottomFolder.addView(IConsoleConstants.ID_CONSOLE_VIEW);
bottomFolder.addPlaceholder("org.eclipse.dltk.callhierarchy.view"); //$NON-NLS-1$
bottomFolder.addPlaceholder(NewSearchUI.SEARCH_VIEW_ID);
bottomFolder.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
}
示例5: addDownloadJob
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
protected void addDownloadJob(DownloadJob downloadJob) {
if (downloadJob != null) {
// This is a non-user job, so make sure that it has no presence in the
// Progress View
downloadJob.setSystem(true);
downloadJob.addJobChangeListener(removeJobOnCompleteListener);
// If the job returns an ERROR status, make sure that it does not show
// a modal dialog with the ERROR information; we want a silent failure
downloadJob.setProperty(
IProgressConstants.NO_IMMEDIATE_ERROR_PROMPT_PROPERTY, true);
synchronized (downloadJobs) {
downloadJob.schedule();
downloadJobs.add(downloadJob);
}
}
}
示例6: run
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
@Override
protected IStatus run(IProgressMonitor monitor) {
IStatus jobStatus = Status.OK_STATUS;
try {
jobStatus = untar.run(monitor);
} catch (InvocationTargetException e) {
jobStatus = new Status(Status.ERROR, CorePlugin.PLUGIN_ID, "Invocation Target Exception", e);
}
setProperty(IProgressConstants.KEEP_PROPERTY, Boolean.TRUE);
setProperty(IProgressConstants.ACTION_PROPERTY, getViewStatusAction(jobStatus));
maybeFireCompletedAction(jobStatus);
monitor.done();
return jobStatus;
}
示例7: run
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
/**
* Run the unzip job using the provided monitor.
*/
@Override
protected IStatus run(IProgressMonitor monitor) {
IStatus jobStatus = Status.OK_STATUS;
try {
jobStatus = unzip.run(monitor);
} catch (InvocationTargetException e) {
jobStatus = new Status(Status.ERROR, CorePlugin.PLUGIN_ID, "Invocation Target Exception", e);
}
setProperty(IProgressConstants.KEEP_PROPERTY, Boolean.TRUE);
setProperty(IProgressConstants.ACTION_PROPERTY, getViewStatusAction(jobStatus));
maybeFireCompletedAction(jobStatus);
monitor.done();
return jobStatus;
}
示例8: CustomDynamicSpotterRunJob
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
/**
* Create a new job for the given project and job id.
*
* @param project
* The project the job is for
* @param jobId
* The job id of the new job
* @param timestamp
* The timestamp when the job was initiated
*/
public CustomDynamicSpotterRunJob(ConfigAlternative alternative, long jobId)
{
super("DynamicSpotter Diagnosis '" + alternative.getName() + "'");
this.project = alternative.getProject();
this.alternative = alternative;
this.jobId = jobId;
this.silentCancel = false;
this.timestamp = System.currentTimeMillis();
ImageDescriptor imageDescriptor = AbstractUIPlugin.imageDescriptorFromPlugin(Activator.PLUGIN_ID, ICON_PATH);
setProperty(IProgressConstants.ICON_PROPERTY, imageDescriptor);
setProperty(JOB_ID_KEY, String.valueOf(jobId));
setPriority(LONG);
setUser(true);
if (!JobsContainer.registerJobId(project, jobId, timestamp))
{
DialogUtils.openError(RunHandler.DIALOG_TITLE,
"There was an error when saving the job id. You may not access the results of the diagnosis run.");
}
}
示例9: defineLayout
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
/**
* @param layout
* @param editorArea
*/
public void defineLayout(IPageLayout layout) {
String editorArea = layout.getEditorArea();
IFolderLayout topLeft = layout.createFolder("topLeft", IPageLayout.LEFT, (float) 0.26, editorArea); //$NON-NLS-1$
topLeft.addView("org.python.pydev.navigator.view");
IFolderLayout outputfolder = layout.createFolder("bottom", IPageLayout.BOTTOM, (float) 0.75, editorArea); //$NON-NLS-1$
//outputfolder.addView(IPageLayout.ID_PROBLEM_VIEW);
outputfolder.addPlaceholder(NewSearchUI.SEARCH_VIEW_ID);
outputfolder.addPlaceholder(IConsoleConstants.ID_CONSOLE_VIEW);
outputfolder.addPlaceholder(IPageLayout.ID_BOOKMARKS);
outputfolder.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
//Add the outline only if we're not using the minimap.
if (!MinimapOverviewRulerPreferencesPage.getShowMinimapContents()) {
layout.addView(IPageLayout.ID_OUTLINE, IPageLayout.RIGHT, (float) 0.75, editorArea);
}
}
示例10: createInitialLayout
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
/**
* Creates the initial perspective layout.
*
* @param layout
*/
public void createInitialLayout(IPageLayout layout) {
String editorArea = layout.getEditorArea();
layout.setEditorAreaVisible(false);
layout.setFixed(false);
IFolderLayout main = layout.createFolder("main", IPageLayout.LEFT, 1.0f, editorArea);
IFolderLayout sidebar = layout.createFolder("right", IPageLayout.RIGHT, 0.6f, "main");
// Main area
main.addView(Dashboard.ID);
main.addView(StatisticsView.ID);
main.addPlaceholder(ChartView.ID);
main.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
// Sidebar
sidebar.addView(SidebarView.ID);
layout.getViewLayout(StatisticsView.ID).setCloseable(false);
layout.getViewLayout(SidebarView.ID).setCloseable(false);
}
示例11: addViews
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
private void addViews() {
IFolderLayout bottom =
factory.createFolder(
"bottomRight", //NON-NLS-1
IPageLayout.BOTTOM,
0.75f,
factory.getEditorArea());
bottom.addView(IPageLayout.ID_PROP_SHEET);
bottom.addView("org.gw4e.eclipse.views.PerformanceView");
bottom.addView(IPageLayout.ID_PROBLEM_VIEW);
bottom.addView(JavaUI.ID_JAVADOC_VIEW);
bottom.addView(JavaUI.ID_SOURCE_VIEW);
bottom.addPlaceholder(NewSearchUI.SEARCH_VIEW_ID);
bottom.addPlaceholder(IConsoleConstants.ID_CONSOLE_VIEW);
bottom.addPlaceholder(IPageLayout.ID_BOOKMARKS);
bottom.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
IFolderLayout topLeft =
factory.createFolder(
"topLeft", //NON-NLS-1
IPageLayout.LEFT,
0.15f,
factory.getEditorArea());
topLeft.addView(JavaUI.ID_PACKAGES);
topLeft.addPlaceholder(JavaUI.ID_TYPE_HIERARCHY);
topLeft.addPlaceholder(JavaPlugin.ID_RES_NAV);
topLeft.addPlaceholder(IPageLayout.ID_PROJECT_EXPLORER);
IFolderLayout outlineFolder = factory.createFolder("right", IPageLayout.RIGHT, (float) 0.85, factory.getEditorArea()); //$NON-NLS-1$
outlineFolder.addView(IPageLayout.ID_OUTLINE);
}
示例12: EclipseHttpJob
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
public EclipseHttpJob( long duration, boolean lock, /*boolean failure,*/ boolean indeterminate/*, boolean reschedule, long rescheduleWait*/) {
super("http4e loading..");
this.duration = duration;
// this.failure = failure;
this.unknown = indeterminate;
// this.reschedule = reschedule;
// this.rescheduleWait = rescheduleWait;
if (lock)
setRule(ResourcesPlugin.getWorkspace().getRoot());
setProperty(IProgressConstants.KEEP_PROPERTY, Boolean.valueOf("true"));
setProperty(IProgressConstants.KEEPONE_PROPERTY, Boolean.valueOf("true"));
schedule(10);
}
示例13: addViews
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
private void addViews() {
IFolderLayout bottom = layoutFactory.createFolder("bottomRight", // NON-NLS-1
IPageLayout.BOTTOM, 0.75f, layoutFactory.getEditorArea());
bottom.addView(PluginConst.RESULT_VIEW_ID);
bottom.addView(IPageLayout.ID_PROBLEM_VIEW);
bottom.addView(IProgressConstants.PROGRESS_VIEW_ID);
IFolderLayout topLeft = layoutFactory.createFolder("topLeft", // NON-NLS-1
IPageLayout.LEFT, 0.25f, layoutFactory.getEditorArea());
topLeft.addView(IConsoleConstants.ID_CONSOLE_VIEW);
topLeft.addView(IPageLayout.ID_PROJECT_EXPLORER);//ID_RES_NAV);
}
示例14: addShowViewShortcuts
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
protected void addShowViewShortcuts(IPageLayout layout) {
layout.addShowViewShortcut(IPageLayout.ID_OUTLINE);
layout.addShowViewShortcut(IPageLayout.ID_PROBLEM_VIEW);
layout.addShowViewShortcut(DLTKUIPlugin.ID_SCRIPT_EXPLORER);
layout.addShowViewShortcut("org.eclipse.dltk.testing.ResultView"); //$NON-NLS-1$
layout.addShowViewShortcut(IPageLayout.ID_TASK_LIST);
layout.addShowViewShortcut(IProgressConstants.PROGRESS_VIEW_ID);
layout.addShowViewShortcut(IConsoleConstants.ID_CONSOLE_VIEW);
layout.addShowViewShortcut("org.eclipse.dltk.ui.TypeHierarchy"); //$NON-NLS-1$
layout.addShowViewShortcut("org.eclipse.dltk.callhierarchy.view"); //$NON-NLS-1$
}
示例15: createVerticalLayout
import org.eclipse.ui.progress.IProgressConstants; //导入依赖的package包/类
private void createVerticalLayout(IPageLayout layout) {
String relativePartId= IPageLayout.ID_EDITOR_AREA;
int relativePos= IPageLayout.LEFT;
IPlaceholderFolderLayout placeHolderLeft= layout.createPlaceholderFolder("left", IPageLayout.LEFT, (float)0.25, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
placeHolderLeft.addPlaceholder(JavaUI.ID_TYPE_HIERARCHY);
placeHolderLeft.addPlaceholder(IPageLayout.ID_OUTLINE);
placeHolderLeft.addPlaceholder(JavaUI.ID_PACKAGES);
placeHolderLeft.addPlaceholder(JavaPlugin.ID_RES_NAV);
placeHolderLeft.addPlaceholder(IPageLayout.ID_PROJECT_EXPLORER);
if (shouldShowProjectsView()) {
layout.addView(JavaUI.ID_PROJECTS_VIEW, IPageLayout.LEFT, (float)0.25, IPageLayout.ID_EDITOR_AREA);
relativePartId= JavaUI.ID_PROJECTS_VIEW;
relativePos= IPageLayout.BOTTOM;
}
if (shouldShowPackagesView()) {
layout.addView(JavaUI.ID_PACKAGES_VIEW, relativePos, (float)0.25, relativePartId);
relativePartId= JavaUI.ID_PACKAGES_VIEW;
relativePos= IPageLayout.BOTTOM;
}
layout.addView(JavaUI.ID_TYPES_VIEW, relativePos, (float)0.33, relativePartId);
layout.addView(JavaUI.ID_MEMBERS_VIEW, IPageLayout.BOTTOM, (float)0.50, JavaUI.ID_TYPES_VIEW);
IPlaceholderFolderLayout placeHolderBottom= layout.createPlaceholderFolder("bottom", IPageLayout.BOTTOM, (float)0.75, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
placeHolderBottom.addPlaceholder(IPageLayout.ID_PROBLEM_VIEW);
placeHolderBottom.addPlaceholder(NewSearchUI.SEARCH_VIEW_ID);
placeHolderBottom.addPlaceholder(IConsoleConstants.ID_CONSOLE_VIEW);
placeHolderBottom.addPlaceholder(IPageLayout.ID_BOOKMARKS);
placeHolderBottom.addPlaceholder(JavaUI.ID_SOURCE_VIEW);
placeHolderBottom.addPlaceholder(JavaUI.ID_JAVADOC_VIEW);
placeHolderBottom.addPlaceholder(IProgressConstants.PROGRESS_VIEW_ID);
}
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:34,代码来源:JavaBrowsingPerspectiveFactory.java