-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #280 from scenerygraphics/ui-updates
UI updates: * usage of flatlaf if run as standalone (https://www.formdev.com/flatlaf/) * nicer inspector panel, which is collapsible to the sidebar * nicer REPL panel, which is also collapsible to the sidebar Also adds a new command to load Cremi datasets and segmentations, which is the first Kotlin-powered command 🥳
- Loading branch information
Showing
211 changed files
with
40,306 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
* Copyright 2000-2009 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. | ||
*/ | ||
package com.intellij.openapi; | ||
|
||
/** | ||
* This class marks classes, which require some work done for cleaning up. | ||
* As a general policy you shouldn't call the {@link #dispose} method directly, | ||
* but register your object to be chained with a parent disposable via {@link com.intellij.openapi.util.Disposer#register(Disposable, Disposable)}. | ||
* If you're 100% sure that you should control disposion of your object manually, | ||
* do not call the {@link #dispose} method either. Use {@link com.intellij.openapi.util.Disposer#dispose(Disposable)} instead, since | ||
* there might be any object registered in chain. | ||
*/ | ||
public interface Disposable { | ||
void dispose(); | ||
|
||
interface Parent extends Disposable { | ||
void beforeTreeDispose(); | ||
} | ||
|
||
} |
22 changes: 22 additions & 0 deletions
22
src/main/java/com/intellij/openapi/diagnostic/ApplicationInfoProvider.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* | ||
* Copyright 2000-2009 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. | ||
*/ | ||
package com.intellij.openapi.diagnostic; | ||
|
||
public interface ApplicationInfoProvider { | ||
|
||
String getInfo(); | ||
|
||
} |
22 changes: 22 additions & 0 deletions
22
src/main/java/com/intellij/openapi/diagnostic/ControlFlowException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* | ||
* 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. | ||
*/ | ||
package com.intellij.openapi.diagnostic; | ||
|
||
/** | ||
* A marker interface for exceptions that should never be logged. | ||
*/ | ||
@SuppressWarnings("NonExceptionNameEndsWithException") | ||
public interface ControlFlowException { } |
84 changes: 84 additions & 0 deletions
84
src/main/java/com/intellij/openapi/diagnostic/DefaultLogger.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
/* | ||
* 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. | ||
*/ | ||
package com.intellij.openapi.diagnostic; | ||
|
||
import com.intellij.openapi.util.text.StringUtil; | ||
import com.intellij.util.ExceptionUtil; | ||
import org.apache.log4j.Level; | ||
import org.jetbrains.annotations.NonNls; | ||
import org.jetbrains.annotations.NotNull; | ||
import org.jetbrains.annotations.Nullable; | ||
|
||
public class DefaultLogger extends Logger { | ||
@SuppressWarnings("UnusedParameters") | ||
public DefaultLogger(String category) { } | ||
|
||
@Override | ||
public boolean isDebugEnabled() { | ||
return false; | ||
} | ||
|
||
@Override | ||
public void debug(String message) { } | ||
|
||
@Override | ||
public void debug(Throwable t) { } | ||
|
||
@Override | ||
public void debug(@NonNls String message, Throwable t) { } | ||
|
||
@Override | ||
public void info(String message) { } | ||
|
||
@Override | ||
public void info(String message, Throwable t) { } | ||
|
||
@Override | ||
@SuppressWarnings("UseOfSystemOutOrSystemErr") | ||
public void warn(@NonNls String message, @Nullable Throwable t) { | ||
t = checkException(t); | ||
System.err.println("WARN: " + message); | ||
if (t != null) t.printStackTrace(System.err); | ||
} | ||
|
||
@Override | ||
@SuppressWarnings("UseOfSystemOutOrSystemErr") | ||
public void error(String message, @Nullable Throwable t, @NotNull String... details) { | ||
t = checkException(t); | ||
message += attachmentsToString(t); | ||
System.err.println("ERROR: " + message); | ||
if (t != null) t.printStackTrace(System.err); | ||
if (details.length > 0) { | ||
System.out.println("details: "); | ||
for (String detail : details) { | ||
System.out.println(detail); | ||
} | ||
} | ||
|
||
AssertionError error = new AssertionError(message); | ||
error.initCause(t); | ||
throw error; | ||
} | ||
|
||
@Override | ||
public void setLevel(Level level) { } | ||
|
||
public static String attachmentsToString(@Nullable Throwable t) { | ||
//noinspection ThrowableResultOfMethodCallIgnored | ||
Throwable rootCause = t == null ? null : ExceptionUtil.getRootCause(t); | ||
return ""; | ||
} | ||
} |
Oops, something went wrong.