mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PlatformDataKeys -> CommonDataKeys
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2013 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -159,7 +159,7 @@ public class PaletteGroupHeader extends JCheckBox implements DataProvider {
|
||||
@Nullable public Object getData(String dataId) {
|
||||
Object data = myPaletteWindow.getData(dataId);
|
||||
if (data != null) return data;
|
||||
Project project = PlatformDataKeys.PROJECT.getData(myPaletteWindow);
|
||||
Project project = CommonDataKeys.PROJECT.getData(myPaletteWindow);
|
||||
return myGroup.getData(project, dataId);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2013 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -15,17 +15,15 @@
|
||||
*/
|
||||
package com.intellij.ide.hierarchy.call;
|
||||
|
||||
import com.intellij.ide.hierarchy.HierarchyProvider;
|
||||
import com.intellij.ide.hierarchy.HierarchyBrowser;
|
||||
import com.intellij.ide.hierarchy.CallHierarchyBrowserBase;
|
||||
import com.intellij.ide.hierarchy.HierarchyBrowser;
|
||||
import com.intellij.ide.hierarchy.HierarchyProvider;
|
||||
import com.intellij.openapi.actionSystem.CommonDataKeys;
|
||||
import com.intellij.openapi.actionSystem.DataContext;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.psi.PsiElement;
|
||||
import com.intellij.psi.PsiMethod;
|
||||
import com.intellij.psi.util.PsiTreeUtil;
|
||||
import com.intellij.openapi.actionSystem.DataContext;
|
||||
import com.intellij.openapi.actionSystem.PlatformDataKeys;
|
||||
import com.intellij.openapi.actionSystem.LangDataKeys;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
/**
|
||||
@@ -34,7 +32,7 @@ import org.jetbrains.annotations.NotNull;
|
||||
public class JavaCallHierarchyProvider implements HierarchyProvider {
|
||||
@Override
|
||||
public PsiElement getTarget(@NotNull final DataContext dataContext) {
|
||||
final Project project = PlatformDataKeys.PROJECT.getData(dataContext);
|
||||
final Project project = CommonDataKeys.PROJECT.getData(dataContext);
|
||||
if (project == null) return null;
|
||||
|
||||
final PsiElement element = CommonDataKeys.PSI_ELEMENT.getData(dataContext);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2009 JetBrains s.r.o.
|
||||
* Copyright 2000-2013 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -18,7 +18,6 @@ package com.intellij.ide.macro;
|
||||
import com.intellij.ide.IdeBundle;
|
||||
import com.intellij.openapi.actionSystem.CommonDataKeys;
|
||||
import com.intellij.openapi.actionSystem.DataContext;
|
||||
import com.intellij.openapi.actionSystem.PlatformDataKeys;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.roots.ProjectRootManager;
|
||||
import com.intellij.openapi.vfs.VirtualFile;
|
||||
@@ -36,7 +35,7 @@ public final class ClasspathEntryMacro extends Macro {
|
||||
}
|
||||
|
||||
public String expand(final DataContext dataContext) {
|
||||
final Project project = PlatformDataKeys.PROJECT.getData(dataContext);
|
||||
final Project project = CommonDataKeys.PROJECT.getData(dataContext);
|
||||
if (project == null) return null;
|
||||
final VirtualFile file = CommonDataKeys.VIRTUAL_FILE.getData(dataContext);
|
||||
if (file == null) return null;
|
||||
|
||||
Reference in New Issue
Block a user