diff --git a/plugins/markdown/core/backend/resources/intellij.markdown.backend.xml b/plugins/markdown/core/backend/resources/intellij.markdown.backend.xml index 7ba473b1c93c..253fc5a9aea0 100644 --- a/plugins/markdown/core/backend/resources/intellij.markdown.backend.xml +++ b/plugins/markdown/core/backend/resources/intellij.markdown.backend.xml @@ -1,12 +1,12 @@ - + + implementation="com.intellij.markdown.backend.providers.MarkdownLinkOpenerApiProvider"/> + implementation="com.intellij.markdown.backend.providers.VirtualFileAccessorProvider"/> \ No newline at end of file diff --git a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/providers/MarkdownLinkOpenerApiProvider.kt b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/providers/MarkdownLinkOpenerApiProvider.kt similarity index 74% rename from plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/providers/MarkdownLinkOpenerApiProvider.kt rename to plugins/markdown/core/backend/src/com/intellij/markdown/backend/providers/MarkdownLinkOpenerApiProvider.kt index c43086a8f3b9..1b18e8392f5b 100644 --- a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/providers/MarkdownLinkOpenerApiProvider.kt +++ b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/providers/MarkdownLinkOpenerApiProvider.kt @@ -1,8 +1,8 @@ -package org.intellij.plugins.markdown.backend.providers +package com.intellij.markdown.backend.providers import com.intellij.platform.rpc.backend.RemoteApiProvider import fleet.rpc.remoteApiDescriptor -import org.intellij.plugins.markdown.backend.services.MarkdownLinkOpenerRemoteApiImpl +import com.intellij.markdown.backend.services.MarkdownLinkOpenerRemoteApiImpl import org.intellij.plugins.markdown.service.MarkdownLinkOpenerRemoteApi private class MarkdownLinkOpenerApiProvider : RemoteApiProvider { diff --git a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/providers/VirtualFileAccessorProvider.kt b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/providers/VirtualFileAccessorProvider.kt similarity index 74% rename from plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/providers/VirtualFileAccessorProvider.kt rename to plugins/markdown/core/backend/src/com/intellij/markdown/backend/providers/VirtualFileAccessorProvider.kt index 9c5696de3612..1ff2fea853c7 100644 --- a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/providers/VirtualFileAccessorProvider.kt +++ b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/providers/VirtualFileAccessorProvider.kt @@ -1,8 +1,8 @@ -package org.intellij.plugins.markdown.backend.providers +package com.intellij.markdown.backend.providers import com.intellij.platform.rpc.backend.RemoteApiProvider import fleet.rpc.remoteApiDescriptor -import org.intellij.plugins.markdown.backend.services.VirtualFileAccessorImpl +import com.intellij.markdown.backend.services.VirtualFileAccessorImpl import org.intellij.plugins.markdown.service.VirtualFileAccessor private class VirtualFileAccessorProvider : RemoteApiProvider { diff --git a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/services/MarkdownLinkOpenerRemoteApiImpl.kt b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/services/MarkdownLinkOpenerRemoteApiImpl.kt similarity index 98% rename from plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/services/MarkdownLinkOpenerRemoteApiImpl.kt rename to plugins/markdown/core/backend/src/com/intellij/markdown/backend/services/MarkdownLinkOpenerRemoteApiImpl.kt index f2cf1136e25e..37d49d2d898c 100644 --- a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/services/MarkdownLinkOpenerRemoteApiImpl.kt +++ b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/services/MarkdownLinkOpenerRemoteApiImpl.kt @@ -1,6 +1,6 @@ // Copyright 2000-2025 JetBrains s.r.o. and contributors. // Use of this source code is governed by the Apache 2.0 license. -package org.intellij.plugins.markdown.backend.services +package com.intellij.markdown.backend.services import com.intellij.ide.BrowserUtil import com.intellij.ide.vfs.VirtualFileId diff --git a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/services/VirtualFileAccessorImpl.kt b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/services/VirtualFileAccessorImpl.kt similarity index 96% rename from plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/services/VirtualFileAccessorImpl.kt rename to plugins/markdown/core/backend/src/com/intellij/markdown/backend/services/VirtualFileAccessorImpl.kt index f95dfac3eec4..985c03a34f8d 100644 --- a/plugins/markdown/core/backend/src/org/intellij/plugins/markdown/backend/services/VirtualFileAccessorImpl.kt +++ b/plugins/markdown/core/backend/src/com/intellij/markdown/backend/services/VirtualFileAccessorImpl.kt @@ -1,4 +1,4 @@ -package org.intellij.plugins.markdown.backend.services +package com.intellij.markdown.backend.services import com.intellij.ide.vfs.VirtualFileId import com.intellij.ide.vfs.rpcId diff --git a/plugins/markdown/core/frontend/resources/intellij.markdown.frontend.xml b/plugins/markdown/core/frontend/resources/intellij.markdown.frontend.xml index 262205a3c9f8..db64c2943054 100644 --- a/plugins/markdown/core/frontend/resources/intellij.markdown.frontend.xml +++ b/plugins/markdown/core/frontend/resources/intellij.markdown.frontend.xml @@ -1,10 +1,10 @@ - + + serviceImplementation="com.intellij.markdown.frontend.preview.accessor.impl.MarkdownLinkOpenerImpl"/> diff --git a/plugins/markdown/core/frontend/src/org/intellij/plugins/markdown/frontend/preview/accessor/impl/MarkdownLinkOpenerImpl.kt b/plugins/markdown/core/frontend/src/com/intellij/markdown/frontend/preview/accessor/impl/MarkdownLinkOpenerImpl.kt similarity index 94% rename from plugins/markdown/core/frontend/src/org/intellij/plugins/markdown/frontend/preview/accessor/impl/MarkdownLinkOpenerImpl.kt rename to plugins/markdown/core/frontend/src/com/intellij/markdown/frontend/preview/accessor/impl/MarkdownLinkOpenerImpl.kt index d3ee6288da07..f09563b0c3d6 100644 --- a/plugins/markdown/core/frontend/src/org/intellij/plugins/markdown/frontend/preview/accessor/impl/MarkdownLinkOpenerImpl.kt +++ b/plugins/markdown/core/frontend/src/com/intellij/markdown/frontend/preview/accessor/impl/MarkdownLinkOpenerImpl.kt @@ -1,4 +1,4 @@ -package org.intellij.plugins.markdown.frontend.preview.accessor.impl +package com.intellij.markdown.frontend.preview.accessor.impl import com.intellij.ide.BrowserUtil import com.intellij.ide.actions.OpenFileAction @@ -24,7 +24,6 @@ import com.intellij.openapi.wm.WindowManager import com.intellij.platform.project.findProject import com.intellij.ui.awt.RelativePoint import com.intellij.util.concurrency.annotations.RequiresEdt -import com.intellij.util.io.isLocalHost import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.launch @@ -55,7 +54,7 @@ internal class MarkdownLinkOpenerImpl(val coroutineScope: CoroutineScope) : Mark override fun openLink(currentProject: Project?, link: String, containingFile: VirtualFile?) { coroutineScope.launch { - val data = MarkdownLinkOpenerRemoteApi.getInstance().fetchLinkNavigationData(link, containingFile?.rpcId()) + val data = MarkdownLinkOpenerRemoteApi.Companion.getInstance().fetchLinkNavigationData(link, containingFile?.rpcId()) val uri = createUri(data.uri) ?: return@launch if (uri.scheme != "file") { openExternalLink(currentProject, uri) @@ -67,7 +66,7 @@ internal class MarkdownLinkOpenerImpl(val coroutineScope: CoroutineScope) : Mark if (anchor == null) { withContext(Dispatchers.EDT) { runReadAction { - OpenFileAction.openFile(fileToOpen, project) + OpenFileAction.Companion.openFile(fileToOpen, project) } } return@launch @@ -78,7 +77,7 @@ internal class MarkdownLinkOpenerImpl(val coroutineScope: CoroutineScope) : Mark private suspend fun processHeaders(anchor: String, project: Project, headers: List?){ if (headers == null) { - DumbService.getInstance(project).showDumbModeNotificationForFunctionality( + DumbService.Companion.getInstance(project).showDumbModeNotificationForFunctionality( message = MarkdownBundle.message("markdown.dumb.mode.navigation.is.not.available.notification.text"), functionality = DumbModeBlockedFunctionality.ActionWithoutId ) @@ -130,7 +129,7 @@ internal class MarkdownLinkOpenerImpl(val coroutineScope: CoroutineScope) : Mark @RequiresEdt private fun showDialog(project: Project?, uri: URI): Boolean { - val dialog = MessageDialogBuilder.yesNo( + val dialog = MessageDialogBuilder.Companion.yesNo( title = MarkdownBundle.message("markdown.browse.external.link.open.confirmation.dialog.title"), message = MarkdownBundle.message("markdown.browse.external.link.open.confirmation.dialog.text", uri) ).doNotAsk(createDoNotAskOption(project, uri)) @@ -190,14 +189,14 @@ internal class MarkdownLinkOpenerImpl(val coroutineScope: CoroutineScope) : Mark val anchor = uri.fragment if (anchor == null){ coroutineScope.launch(Dispatchers.EDT) { - OpenFileAction.openFile(targetFile, project) + OpenFileAction.Companion.openFile(targetFile, project) } return true } val headers = MarkdownLinkOpenerUtil.collectHeaders(project, anchor, targetFile) if (headers == null) { coroutineScope.launch { - DumbService.getInstance(project).showDumbModeNotificationForFunctionality( + DumbService.Companion.getInstance(project).showDumbModeNotificationForFunctionality( message = MarkdownBundle.message("markdown.dumb.mode.navigation.is.not.available.notification.text"), functionality = DumbModeBlockedFunctionality.ActionWithoutId ) @@ -244,7 +243,7 @@ internal class MarkdownLinkOpenerImpl(val coroutineScope: CoroutineScope) : Mark return hostName == null || hostName.startsWith("127.") || hostName.endsWith(":1") || - isLocalHost(hostName, false, false) + com.intellij.util.io.isLocalHost(hostName, false, false) } private fun obtainHeadersPopupPosition(project: Project?): RelativePoint? { diff --git a/plugins/markdown/core/plugin-content.yaml b/plugins/markdown/core/plugin-content.yaml index 72e05440f7b8..c58d0bb06441 100644 --- a/plugins/markdown/core/plugin-content.yaml +++ b/plugins/markdown/core/plugin-content.yaml @@ -11,5 +11,9 @@ - name: intellij.markdown.model - name: intellij.markdown.spellchecker - name: intellij.markdown.compose.preview - - name: intellij.markdown.frontend - - name: intellij.markdown.backend \ No newline at end of file +- name: lib/modules/intellij.markdown.backend.jar + contentModules: + - name: intellij.markdown.backend +- name: lib/modules/intellij.markdown.frontend.jar + contentModules: + - name: intellij.markdown.frontend \ No newline at end of file