use of com.intellij.openapi.util.registry.RegistryValue in project intellij-community by JetBrains.
the class JavaFXHighlightingTest method testInjectedController.
public void testInjectedController() throws Exception {
myFixture.copyFileToProject("injected/MyController.java");
myFixture.copyFileToProject("injected/FooVBox.java");
final RegistryValue registryValue = Registry.get("javafx.fxml.controller.from.loader");
final boolean injectionAllowed = registryValue.asBoolean();
try {
registryValue.setValue(true);
doTestNavigation("injected.MyController", "label", "injected/" + getTestName(true) + ".fxml");
} finally {
registryValue.setValue(injectionAllowed);
}
}
use of com.intellij.openapi.util.registry.RegistryValue in project intellij-community by JetBrains.
the class ToggleDistractionFreeModeAction method alternateCurrentDistractionFreeModeSetting.
private static void alternateCurrentDistractionFreeModeSetting() {
RegistryValue value = Registry.get(key);
value.setValue(!value.asBoolean());
}
use of com.intellij.openapi.util.registry.RegistryValue in project intellij-community by JetBrains.
the class BytecodeAnalysisIntegrationTest method setUp.
@Override
protected void setUp() throws Exception {
super.setUp();
myMessageDigest = BytecodeAnalysisConverter.getMessageDigest();
RegistryValue registryValue = Registry.get(ProjectBytecodeAnalysis.NULLABLE_METHOD);
myNullableMethodRegistryValue = registryValue.asBoolean();
registryValue.setValue(true);
}
use of com.intellij.openapi.util.registry.RegistryValue in project intellij-community by JetBrains.
the class ClassFilesIndexFeaturesHolder method projectOpened.
@Override
public final void projectOpened() {
for (final ClassFilesIndexFeature feature : ClassFilesIndexFeature.values()) {
final RegistryValue registryValue = feature.getRegistryValue();
registryValue.addListener(new RegistryValueListener.Adapter() {
@Override
public void afterValueChanged(final RegistryValue rawValue) {
if (!rawValue.asBoolean() && myEnabledFeatures.containsKey(feature)) {
disposeFeature(feature);
}
}
}, myProject);
}
final CompilerManager compilerManager = CompilerManager.getInstance(myProject);
compilerManager.addBeforeTask(new CompileTask() {
@Override
public boolean execute(final CompileContext context) {
close();
return true;
}
});
}
use of com.intellij.openapi.util.registry.RegistryValue in project intellij-community by JetBrains.
the class HtmlUtil method setShortNotationOfBooleanAttributeIsPreferred.
@TestOnly
public static void setShortNotationOfBooleanAttributeIsPreferred(boolean value, Disposable parent) {
final boolean oldValue = isShortNotationOfBooleanAttributePreferred();
final RegistryValue registryValue = Registry.get("html.prefer.short.notation.of.boolean.attributes");
registryValue.setValue(value);
Disposer.register(parent, new Disposable() {
@Override
public void dispose() {
registryValue.setValue(oldValue);
}
});
}
Aggregations