Skip to content

Commit

Permalink
Default to intial view (#72)
Browse files Browse the repository at this point in the history
* When clearing the search string, default to intial view

* Ignore .kotlin dir

* Change notes and version
  • Loading branch information
MituuZ authored Jul 28, 2024
1 parent aada2eb commit 0a0c5fe
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 10 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.gradle
.kotlin
build/
!gradle/wrapper/gradle-wrapper.jar
!**/src/main/**/build/
Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ plugins {
}

group = "com.mituuz"
version = "0.25.1"
version = "0.26.0"

repositories {
mavenCentral()
Expand Down
3 changes: 3 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Changelog
## Version 0.26.0
- Default to initial view when clearing the search string

## Version 0.25.1
- Fix task cancellation, making lower debounce time feel much better
- Lower default debounce time
Expand Down
10 changes: 7 additions & 3 deletions src/main/kotlin/com/mituuz/fuzzier/Fuzzier.kt
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,13 @@ open class Fuzzier : FuzzyAction() {

override fun updateListContents(project: Project, searchString: String) {
if (StringUtils.isBlank(searchString)) {
ApplicationManager.getApplication().invokeLater {
component.fileList.model = DefaultListModel()
defaultDoc?.let { (component as FuzzyFinderComponent).previewPane.updateFile(it) }
if (fuzzierSettingsService.state.recentFilesMode != NONE) {
createInitialView(project)
} else {
ApplicationManager.getApplication().invokeLater {
component.fileList.model = DefaultListModel()
defaultDoc?.let { (component as FuzzyFinderComponent).previewPane.updateFile(it) }
}
}
return
}
Expand Down
8 changes: 2 additions & 6 deletions src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,8 @@
</extensions>

<change-notes><![CDATA[
<h2>Version 0.25.1</h2>
- Fix task cancellation, making lower debounce time feel much better<br>
- Lower default debounce time<br>
<h2>Version 0.25.0</h2>
- Clear up settings grouping<br>
- Add option to highlight filename matches in the file list<br>
<h2>Version 0.26.0</h2>
- Default to initial view when clearing the search string<br>
]]>
</change-notes>

Expand Down

0 comments on commit 0a0c5fe

Please sign in to comment.