Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ private static boolean addClassesUsages(
for (PsiClass aClass : classes) {
if (progress != null) {
String name = AccessRule.read(aClass::getName);
progress.setTextValue(FindLocalize.findSearchingForReferencesToClassProgress(name));
progress.setText(FindLocalize.findSearchingForReferencesToClassProgress(name));
}
ProgressManager.checkCanceled();
boolean success = ReferencesSearch.search(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,8 @@ public void update(AnActionEvent event) {
return;
}

presentation.setEnabled(true);
presentation.setVisible(true);
presentation.setTextValue(JavaCompilerLocalize.actionRunAptText());
presentation.setEnabledAndVisible(true);
presentation.setText(JavaCompilerLocalize.actionRunAptText());

FileSetCompileScope scope = ReadAction.compute(() -> getCompilableFiles(project, event.getData(VirtualFile.KEY_OF_ARRAY)));
if (moduleContext == null && scope == null) {
Expand All @@ -119,7 +118,7 @@ public void update(AnActionEvent event) {
}

if (moduleContext != null) {
presentation.setTextValue(JavaCompilerLocalize.actionRunAptModuleText(trimName(moduleContext.getName())));
presentation.setText(JavaCompilerLocalize.actionRunAptModuleText(trimName(moduleContext.getName())));
}
else {
PsiJavaPackage aPackage = null;
Expand All @@ -139,7 +138,7 @@ public void update(AnActionEvent event) {

if (aPackage != null) {
String name = aPackage.getQualifiedName();
presentation.setTextValue(
presentation.setText(
StringUtil.isNotEmpty(name)
? JavaCompilerLocalize.actionRunApt0Text(trimName(name))
: JavaCompilerLocalize.actionRunAptDefaultText()
Expand All @@ -149,7 +148,7 @@ else if (files.size() == 1) {
VirtualFile file = files.iterator().next();
FileType fileType = file.getFileType();
if (CompilerManager.getInstance(project).isCompilableFileType(fileType)) {
presentation.setTextValue(JavaCompilerLocalize.actionRunApt0Text(trimName(file.getName())));
presentation.setText(JavaCompilerLocalize.actionRunApt0Text(trimName(file.getName())));
}
else {
presentation.setEnabled(false);
Expand All @@ -158,7 +157,7 @@ else if (files.size() == 1) {
}
}
else {
presentation.setTextValue(JavaCompilerLocalize.actionRunAptSelectedFilesText());
presentation.setText(JavaCompilerLocalize.actionRunAptSelectedFilesText());
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1036,7 +1036,7 @@ private void updateStatistics()
final LocalizeValue msg = moduleName != null
? CompilerLocalize.statisticsFilesClassesModule(myStatistics.getFilesCount(), myStatistics.getClassesCount(), moduleName)
: CompilerLocalize.statisticsFilesClasses(myStatistics.getFilesCount(), myStatistics.getClassesCount());
myCompileContext.getProgressIndicator().setText2Value(msg);
myCompileContext.getProgressIndicator().setText2(msg);
//myCompileContext.getProgressIndicator().setFraction(1.0* myProcessedFilesCount /myTotalFilesToCompile);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public EditFrameSourceAction() {
@RequiredUIAccess
public void update(AnActionEvent e) {
super.update(e);
e.getPresentation().setTextValue(
e.getPresentation().setText(
ActionManager.getInstance().getAction(IdeActions.ACTION_EDIT_SOURCE).getTemplatePresentation().getTextValue()
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public void threadAction() {
else {
presentation.setEnabled(false);
}
e.getPresentation().setTextValue(
e.getPresentation().setText(
ActionManager.getInstance().getAction(IdeActions.ACTION_EDIT_SOURCE).getTemplatePresentation().getTextValue()
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public void update(AnActionEvent e) {
}
}
Presentation presentation = e.getPresentation();
presentation.setTextValue(JavaDebuggerLocalize.actionInterruptThreadText());
presentation.setText(JavaDebuggerLocalize.actionInterruptThreadText());
presentation.setVisible(visible);
presentation.setEnabled(enabled);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ else if (threadDescriptor.isFrozen()) {
}
}
Presentation presentation = e.getPresentation();
presentation.setTextValue(text);
presentation.setText(text);
presentation.setVisible(visible);
presentation.setEnabled(enabled);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -459,11 +459,11 @@ public void update(AnActionEvent e) {
DebugProcessImpl process = getCurrentDebugProcess(e.getData(Project.KEY));
if (process == null || process.canGetMethodReturnValue()) {
presentation.setEnabled(true);
presentation.setTextValue(myText);
presentation.setText(myText);
}
else {
presentation.setEnabled(false);
presentation.setTextValue(myTextUnavailable);
presentation.setText(myTextUnavailable);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ protected void analyze(Project project, AnalysisScope scope) {
@Override
public void run(ProgressIndicator indicator) {
indicator.setIndeterminate(true);
indicator.setTextValue(AnalysisScopeLocalize.checkingClassFiles());
indicator.setText(AnalysisScopeLocalize.checkingClassFiles());

CompilerManager compilerManager = CompilerManager.getInstance((Project)getProject());
boolean upToDate = compilerManager.isUpToDate(compilerManager.createProjectCompileScope());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public class BaseGenerateAction extends CodeInsightAction implements GenerateAct

public BaseGenerateAction(CodeInsightActionHandler handler, LocalizeValue text) {
myHandler = handler;
getTemplatePresentation().setTextValue(text);
getTemplatePresentation().setText(text);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public void visitFile(PsiFile file) {
if (virtualFile != null) {
progressIndicator.setText2(ProjectUtil.calcRelativeToProjectPath(virtualFile, project));
}
progressIndicator.setTextValue(AnalysisScopeLocalize.scanningScopeProgressTitle());
progressIndicator.setText(AnalysisScopeLocalize.scanningScopeProgressTitle());
}
if (!(file instanceof PsiJavaFile)) {
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@
public class GenerateToStringAction extends BaseGenerateAction {
public GenerateToStringAction() {
super(new GenerateToStringActionHandlerImpl(), JavaLocalize.actionGenerateToStringText());
getTemplatePresentation().setDescriptionValue(JavaLocalize.actionGenerateToStringDescription());
getTemplatePresentation().setDescription(JavaLocalize.actionGenerateToStringDescription());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public ImplementMethodAction() {
protected final void update(Presentation presentation, int toImplement, int toOverride) {
if (toImplement > 0) {
presentation.setEnabledAndVisible(true);
presentation.setTextValue(toImplement == 1 ? IdeLocalize.actionImplementMethod() : IdeLocalize.actionImplementMethods());
presentation.setText(toImplement == 1 ? IdeLocalize.actionImplementMethod() : IdeLocalize.actionImplementMethods());
}
else {
presentation.setEnabledAndVisible(false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ protected final void update(Presentation presentation, int toImplement, int toOv
boolean enabled = toOverride > 0;
presentation.setEnabledAndVisible(enabled);
if (enabled) {
presentation.setTextValue(toOverride == 1 ? IdeLocalize.actionOverrideMethod() : IdeLocalize.actionOverrideMethods());
presentation.setText(toOverride == 1 ? IdeLocalize.actionOverrideMethod() : IdeLocalize.actionOverrideMethods());
}
}
}
Loading