Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Micro-Manager for Icy
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Bioimage Analysis
Micro-Manager for Icy
Commits
61b9d548
Commit
61b9d548
authored
3 years ago
by
Stéphane DALLONGEVILLE
Browse files
Options
Downloads
Patches
Plain Diff
Fixed MM JARs loading to not load duplicated libraries
parent
123939c2
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/main/java/plugins/tprovoost/Microscopy/MicroManager/tools/MMUtils.java
+21
-2
21 additions, 2 deletions
...gins/tprovoost/Microscopy/MicroManager/tools/MMUtils.java
with
21 additions
and
2 deletions
src/main/java/plugins/tprovoost/Microscopy/MicroManager/tools/MMUtils.java
+
21
−
2
View file @
61b9d548
...
@@ -152,7 +152,7 @@ public class MMUtils
...
@@ -152,7 +152,7 @@ public class MMUtils
try
try
{
{
loaded
=
loadJarFrom
(
new
File
(
uManagerRep
+
FileUtil
.
separator
+
"plugins"
+
FileUtil
.
separator
loaded
=
loadJar
s
From
(
new
File
(
uManagerRep
+
FileUtil
.
separator
+
"plugins"
+
FileUtil
.
separator
+
"Micro-Manager"
+
FileUtil
.
separator
));
+
"Micro-Manager"
+
FileUtil
.
separator
));
}
}
finally
finally
...
@@ -840,7 +840,7 @@ public class MMUtils
...
@@ -840,7 +840,7 @@ public class MMUtils
return
true
;
return
true
;
}
}
private
static
boolean
loadJarFrom
(
File
microManagerDirectoryPath
)
private
static
boolean
loadJar
s
From
(
File
microManagerDirectoryPath
)
{
{
File
[]
files
=
FileUtil
.
getFiles
(
microManagerDirectoryPath
,
new
FileFilter
()
File
[]
files
=
FileUtil
.
getFiles
(
microManagerDirectoryPath
,
new
FileFilter
()
{
{
...
@@ -863,7 +863,26 @@ public class MMUtils
...
@@ -863,7 +863,26 @@ public class MMUtils
final
String
ext
=
FileUtil
.
getFileExtension
(
path
,
false
).
toLowerCase
();
final
String
ext
=
FileUtil
.
getFileExtension
(
path
,
false
).
toLowerCase
();
if
(
ext
.
equals
(
"jar"
)
||
ext
.
equals
(
"class"
))
if
(
ext
.
equals
(
"jar"
)
||
ext
.
equals
(
"class"
))
{
// don't load libraries that area already included in Icy
if
(
path
.
contains
(
"clojure"
))
continue
;
if
(
path
.
contains
(
"rsyntaxtextarea"
))
continue
;
if
(
path
.
contains
(
"swingx"
))
continue
;
if
(
path
.
contains
(
"ome-xml"
))
continue
;
if
(
path
.
contains
(
"jfreechart"
))
continue
;
if
(
path
.
contains
(
"jcommon"
))
continue
;
if
(
path
.
contains
(
"formats-"
))
continue
;
// we can add it
((
PluginClassLoader
)
cl
).
add
(
path
);
((
PluginClassLoader
)
cl
).
add
(
path
);
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment