Skip to content

Commit

Permalink
Use absolute resource paths for gear icon
Browse files Browse the repository at this point in the history
  • Loading branch information
kephale authored and skalarproduktraum committed Apr 2, 2024
1 parent 549fb2a commit 05cee71
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/main/kotlin/graphics/scenery/volumes/ColormapPanel.kt
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ class ColormapPanel(val target:Volume?): JPanel() {
})

val colormapMenuButton = JToggleButton("").also { button ->
button.icon = ImageIcon(ImageIcon(ImageIO.read(this::class.java.getResource("../ui/gear.png"))).image.getScaledInstance(16, 16,
button.icon = ImageIcon(ImageIcon(ImageIO.read(this::class.java.getResource("/graphics/scenery/ui/gear.png"))).image.getScaledInstance(16, 16,
java.awt.Image.SCALE_SMOOTH
))
button.toolTipText = "Load a new transfer function and display range"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ class TransferFunctionEditor(
})

val tfMenuButton = JToggleButton("").also { button ->
button.icon = ImageIcon(ImageIcon(ImageIO.read(this::class.java.getResource("../ui/gear.png"))).image.getScaledInstance(16, 16, SCALE_SMOOTH))
button.icon = ImageIcon(ImageIcon(ImageIO.read(this::class.java.getResource("/graphics/scenery/ui/gear.png"))).image.getScaledInstance(16, 16, SCALE_SMOOTH))
button.toolTipText = "Load a new transfer function and display range"
button.addActionListener {
if(button.isSelected) {
Expand Down

0 comments on commit 05cee71

Please sign in to comment.