mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
default impl of addConfiguration(rc, isShared)
This commit is contained in:
@@ -1,18 +1,4 @@
|
||||
/*
|
||||
* Copyright 2000-2017 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.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package com.intellij.execution
|
||||
|
||||
import com.intellij.execution.configurations.ConfigurationFactory
|
||||
@@ -172,7 +158,10 @@ abstract class RunManager {
|
||||
* @param isShared true if the configuration is marked as shared (stored in the versioned part of the project files), false if it's local
|
||||
* * (stored in the workspace file).
|
||||
*/
|
||||
abstract fun addConfiguration(settings: RunnerAndConfigurationSettings, isShared: Boolean)
|
||||
fun addConfiguration(settings: RunnerAndConfigurationSettings, isShared: Boolean) {
|
||||
settings.isShared = isShared
|
||||
addConfiguration(settings)
|
||||
}
|
||||
|
||||
/**
|
||||
* Marks the specified run configuration as recently used (the temporary run configurations are deleted in LRU order).
|
||||
@@ -220,7 +209,7 @@ abstract class RunManager {
|
||||
abstract fun setTemporaryConfiguration(tempConfiguration: RunnerAndConfigurationSettings?)
|
||||
}
|
||||
|
||||
private val UNNAMED = "Unnamed"
|
||||
private const val UNNAMED = "Unnamed"
|
||||
|
||||
val IS_RUN_MANAGER_INITIALIZED = Key.create<Boolean>("RunManagerInitialized")
|
||||
private val LOG = Logger.getInstance(RunManager::class.java)
|
||||
@@ -1,24 +1,11 @@
|
||||
/*
|
||||
* Copyright 2000-2015 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.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
|
||||
package com.intellij.execution;
|
||||
|
||||
import com.intellij.ide.util.PropertiesComponent;
|
||||
import com.intellij.openapi.util.text.StringUtil;
|
||||
import org.jetbrains.annotations.NonNls;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public class RunManagerConfig {
|
||||
public static final String MAKE = ExecutionBundle.message("before.run.property.make");
|
||||
@@ -32,7 +19,7 @@ public class RunManagerConfig {
|
||||
@NonNls private static final String RESTART_REQUIRES_CONFIRMATION = "restartRequiresConfirmation";
|
||||
@NonNls private static final String STOP_INCOMPATIBLE_REQUIRES_CONFIRMATION = "stopIncompatibleRequiresConfirmation";
|
||||
|
||||
public RunManagerConfig(PropertiesComponent propertiesComponent) {
|
||||
public RunManagerConfig(@NotNull PropertiesComponent propertiesComponent) {
|
||||
myPropertiesComponent = propertiesComponent;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,4 @@
|
||||
/*
|
||||
* Copyright 2000-2017 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.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package com.intellij.mock
|
||||
|
||||
import com.intellij.execution.BeforeRunTask
|
||||
@@ -26,15 +12,9 @@ import com.intellij.execution.configurations.RunProfile
|
||||
import com.intellij.openapi.util.Key
|
||||
import javax.swing.Icon
|
||||
|
||||
/**
|
||||
* @author gregsh
|
||||
*/
|
||||
class MockRunManager : RunManagerEx() {
|
||||
override fun getConfigurationType(typeName: String) = TODO("not implemented")
|
||||
|
||||
override fun addConfiguration(settings: RunnerAndConfigurationSettings, isShared: Boolean) {
|
||||
}
|
||||
|
||||
override fun hasSettings(settings: RunnerAndConfigurationSettings) = false
|
||||
|
||||
override fun getConfigurationsList(type: ConfigurationType) = emptyList<RunConfiguration>()
|
||||
|
||||
Reference in New Issue
Block a user