Commit c4034efe authored by Gregory.Shrago's avatar Gregory.Shrago
Browse files

PlatformUtils.isDatabaseIDE renamed to isDataGrip

parent 444908e4
Showing with 11 additions and 8 deletions
+11 -8
......@@ -109,7 +109,7 @@ public class PlatformUtils {
return is(WEB_PREFIX);
}
public static boolean isDatabaseIDE() {
public static boolean isDataGrip() {
return is(DBE_PREFIX);
}
......
......@@ -55,7 +55,7 @@ public class FindSettingsImpl extends FindSettings implements PersistentStateCom
else if (PlatformUtils.isPhpStorm()) {
recentFileMasks.add("*.php");
}
else if (PlatformUtils.isDatabaseIDE()) {
else if (PlatformUtils.isDataGrip()) {
recentFileMasks.add("*.sql");
}
}
......
......@@ -62,7 +62,7 @@ public class ScratchProjectViewPane extends ProjectViewPane {
public static final String ID = "Scratches";
public static boolean isScratchesMergedIntoProjectTab() {
return (Registry.is("ide.scratch.in.project.view") || PlatformUtils.isDatabaseIDE()) &&
return (Registry.is("ide.scratch.in.project.view") || PlatformUtils.isDataGrip()) &&
!ApplicationManager.getApplication().isUnitTestMode();
}
......
......@@ -48,7 +48,7 @@ public class GeneralSettings implements PersistentStateComponent<GeneralSettings
private boolean myUseDefaultBrowser = true;
private boolean mySearchInBackground;
private boolean myConfirmExit = true;
private boolean myShowWelcomeScreen = !PlatformUtils.isDatabaseIDE();
private boolean myShowWelcomeScreen = !PlatformUtils.isDataGrip();
private int myConfirmOpenNewProject = OPEN_PROJECT_ASK;
private ProcessCloseConfirmation myProcessCloseConfirmation = ProcessCloseConfirmation.ASK;
private String myDefaultProjectDirectory = "";
......
......@@ -125,7 +125,7 @@ public class GeneralSettingsConfigurable extends CompositeConfigurable<Searchabl
if (myComponent == null) {
myComponent = new MyComponent();
}
myComponent.myShowWelcomeScreen.setVisible(PlatformUtils.isDatabaseIDE());
myComponent.myShowWelcomeScreen.setVisible(PlatformUtils.isDataGrip());
myComponent.myChkAutoSaveIfInactive.addChangeListener(
e -> myComponent.myTfInactiveTimeout.setEditable(myComponent.myChkAutoSaveIfInactive.isSelected()));
......
......@@ -27,7 +27,10 @@ import org.jetbrains.annotations.Nullable;
import org.jetbrains.io.BuiltInServer;
import org.jetbrains.io.MessageDecoder;
import java.io.*;
import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.File;
import java.io.IOException;
import java.lang.management.ManagementFactory;
import java.net.ConnectException;
import java.net.InetAddress;
......@@ -142,7 +145,7 @@ public final class SocketLock {
myToken = UUID.randomUUID().toString();
String[] lockedPaths = {myConfigPath, mySystemPath};
int workerCount = PlatformUtils.isIdeaCommunity() || PlatformUtils.isDatabaseIDE() || PlatformUtils.isCidr() ? 1 : 2;
int workerCount = PlatformUtils.isIdeaCommunity() || PlatformUtils.isDataGrip() || PlatformUtils.isCidr() ? 1 : 2;
NotNullProducer<ChannelHandler> handler = () -> new MyChannelInboundHandler(lockedPaths, myActivateListener, myToken);
myServer = BuiltInServer.startNioOrOio(workerCount, 6942, 50, false, handler);
......
......@@ -303,7 +303,7 @@ public class FileTypeManagerImpl extends FileTypeManagerEx implements Persistent
registerFileTypeWithoutNotification(pair.fileType, pair.matchers, true);
}
if (PlatformUtils.isDatabaseIDE() || PlatformUtils.isCidr()) {
if (PlatformUtils.isDataGrip() || PlatformUtils.isCidr()) {
// build scripts are correct, but it is required to run from sources
return;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment