Skip to content

Commit

Permalink
Make new filters go on top and fix layout issues
Browse files Browse the repository at this point in the history
  • Loading branch information
waleedyaseen committed Oct 2, 2024
1 parent 2e79c00 commit 4155f38
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ public class FiltersSidePanel(
val tabbedGroup = FlatTabbedPane()
tabbedGroup.addTab("Incoming", incomingPanel.wrapWithBorderlessScrollPane())
tabbedGroup.addTab("Outgoing", outgoingPanel.wrapWithBorderlessScrollPane())
tabbedGroup.addTab("Regex", regexPanel.wrapWithBorderlessScrollPane(verticalPolicy = ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED))
tabbedGroup.addTab("Regex", regexPanel.wrapWithBorderlessScrollPane())

tabbedGroup.addMouseListener(
object : MouseAdapter() {
Expand Down Expand Up @@ -221,7 +221,7 @@ public class FiltersSidePanel(
regexPanel.removeAll()

val regexFiltersContainer = JPanel()
regexFiltersContainer.layout = MigLayout("ins 5, hidemode 3", "[grow, fill]", "[]")
regexFiltersContainer.layout = MigLayout("ins 5", "[grow, fill]", "[]")
regexFiltersContainer.border = BorderFactory.createEmptyBorder(0, 0, 0, 0)
regexPanel.add(regexFiltersContainer, BorderLayout.CENTER)

Expand Down Expand Up @@ -258,7 +258,7 @@ public class FiltersSidePanel(
private fun JPanel.addRegexFilterPanel(filter: RegexFilter) {
val filterStore = proxyService.filterSetStore.getActive()
val regexFilterPanel = RegexFilterPanel(filterStore, filter)
add(regexFilterPanel, "wrap")
add(regexFilterPanel, "wrap", 0)
regexPanel.revalidate()
}

Expand Down

0 comments on commit 4155f38

Please sign in to comment.