mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[vision] adjust PyCharmWhatsNewInVisionContentProvider to a new refactoring
GitOrigin-RevId: 3d1548b2f528fd1ada3bdcf355ec596bd9ded22f
This commit is contained in:
committed by
intellij-monorepo-bot
parent
08713082ba
commit
3767ec32bb
+9
-1
@@ -8,9 +8,17 @@ import com.intellij.util.PlatformUtils.isCommunityEdition
|
||||
|
||||
class PyCharmWhatsNewInVisionContentProvider : WhatsNewInVisionContentProvider() {
|
||||
|
||||
override fun getResourceNameByPath(path: String): String {
|
||||
return "whatsNew/$path"
|
||||
}
|
||||
|
||||
override fun getResource(resourceName: String): ContentSource {
|
||||
return ResourceContentSource(PyCharmWhatsNewInVisionContentProvider::class.java.classLoader, resourceName)
|
||||
}
|
||||
|
||||
override fun getResource(): ContentSource {
|
||||
// return a vision file for the current version
|
||||
val resourceName = if (isCommunityEdition()) "whatsNew/pycharmCE2024.2.json" else "whatsNew/pycharm2024.2.json"
|
||||
val resourceName = if (isCommunityEdition()) "whatsNew/pycharmCE2025.2.json" else "whatsNew/pycharm2025.2.json"
|
||||
val resourceContentSource = ResourceContentSource(PyCharmWhatsNewInVisionContentProvider::class.java.classLoader, resourceName)
|
||||
return resourceContentSource
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user