本文整理汇总了Java中com.intellij.history.integration.LocalHistoryImpl类的典型用法代码示例。如果您正苦于以下问题:Java LocalHistoryImpl类的具体用法?Java LocalHistoryImpl怎么用?Java LocalHistoryImpl使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
LocalHistoryImpl类属于com.intellij.history.integration包,在下文中一共展示了LocalHistoryImpl类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: FileUndoProvider
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
public FileUndoProvider(Project project) {
myProject = project;
if (myProject == null) return;
myLocalHistory = LocalHistoryImpl.getInstanceImpl().getFacade();
myGateway = LocalHistoryImpl.getInstanceImpl().getGateway();
if (myLocalHistory == null || myGateway == null) return; // local history was not initialized (e.g. in headless environment)
getFileManager().addVirtualFileListener(this, project);
myLocalHistory.addListener(new LocalHistoryFacade.Listener() {
@Override
public void changeAdded(Change c) {
if (!(c instanceof StructuralChange) || c instanceof ContentChange) return;
myLastChangeId = c.getId();
}
}, myProject);
}
示例2: init
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
protected void init() {
LocalHistoryFacade facade = LocalHistoryImpl.getInstanceImpl().getFacade();
myModel = createModel(facade);
setTitle(myModel.getTitle());
JComponent root = createComponent();
setComponent(root);
setPreferredFocusedComponent(showRevisionsList() ? myRevisionsList.getComponent() : myDiffView);
myUpdateQueue = new MergingUpdateQueue(getClass() + ".revisionsUpdate", 500, true, root, this, null, false);
myUpdateQueue.setRestartTimerOnAdd(true);
facade.addListener(new LocalHistoryFacade.Listener() {
public void changeSetFinished() {
scheduleRevisionsUpdate(null);
}
}, this);
scheduleRevisionsUpdate(null);
}
示例3: cleanupApplicationCaches
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
public static void cleanupApplicationCaches(Project project) {
if (project != null && !project.isDisposed()) {
UndoManagerImpl globalInstance = (UndoManagerImpl)UndoManager.getGlobalInstance();
if (globalInstance != null) {
globalInstance.dropHistoryInTests();
}
((UndoManagerImpl)UndoManager.getInstance(project)).dropHistoryInTests();
((PsiManagerEx)PsiManager.getInstance(project)).getFileManager().cleanupForNextTest();
}
LocalFileSystemImpl localFileSystem = (LocalFileSystemImpl)LocalFileSystem.getInstance();
if (localFileSystem != null) {
localFileSystem.cleanupForNextTest();
}
LocalHistoryImpl.getInstanceImpl().cleanupForNextTest();
PatchedWeakReference.clearAll();
}
示例4: FileUndoProvider
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
private FileUndoProvider(Project project) {
myProject = project;
if (myProject == null) return;
LocalHistoryImpl localHistory = LocalHistoryImpl.getInstanceImpl();
myLocalHistory = localHistory.getFacade();
myGateway = localHistory.getGateway();
if (myLocalHistory == null || myGateway == null) return; // local history was not initialized (e.g. in headless environment)
localHistory.addVFSListenerAfterLocalHistoryOne(this, project);
myLocalHistory.addListener(new LocalHistoryFacade.Listener() {
@Override
public void changeAdded(Change c) {
if (!(c instanceof StructuralChange) || c instanceof ContentChange) return;
myLastChangeId = c.getId();
}
}, myProject);
}
示例5: getVcs
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
protected LocalHistoryFacade getVcs() {
return LocalHistoryImpl.getInstanceImpl().getFacade();
}
示例6: getGateway
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
protected IdeaGateway getGateway() {
return LocalHistoryImpl.getInstanceImpl().getGateway();
}
示例7: getVcs
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
@Nullable
protected LocalHistoryFacade getVcs() {
return LocalHistoryImpl.getInstanceImpl().getFacade();
}
示例8: getGateway
import com.intellij.history.integration.LocalHistoryImpl; //导入依赖的package包/类
@Nullable
protected IdeaGateway getGateway() {
return LocalHistoryImpl.getInstanceImpl().getGateway();
}