Skip to content

Commit

Permalink
feat: support search in several dialogs (#1073)
Browse files Browse the repository at this point in the history
  • Loading branch information
tangcent authored Nov 19, 2023
1 parent 4af278b commit bf9383a
Show file tree
Hide file tree
Showing 15 changed files with 740 additions and 918 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,20 @@ class ApiCaller {
return
}

val apiCallUI = actionContext.instance(ApiCallUI::class)
apiCallUI.updateRequestList(requests)
apiCallUI.showUI()
val uiWeakReference = WeakReference(apiCallUI)
project.putUserData(API_CALL_UI, uiWeakReference)
actionContext.on(EventKey.ON_COMPLETED) {
project.putUserData(API_CALL_UI, null)
uiWeakReference.clear()
actionContext.runInSwingUI {

val apiCallUI = actionContext.instance(ApiCallUI::class)
apiCallUI.updateRequestList(requests)
apiCallUI.showUI()

actionContext.runAsync {
val uiWeakReference = WeakReference(apiCallUI)
project.putUserData(API_CALL_UI, uiWeakReference)
actionContext.on(EventKey.ON_COMPLETED) {
project.putUserData(API_CALL_UI, null)
uiWeakReference.clear()
}
}
}
} catch (e: Exception) {
logger.traceError("Apis exported failed", e)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,11 @@ open class SuvApiExporter {
return
}

val multipleApiExportDialog = actionContext.instance { SuvApiExportDialog() }
actionContext.runInSwingUI {

UIUtils.show(multipleApiExportDialog)
val multipleApiExportDialog = actionContext.instance { SuvApiExportDialog() }

actionContext.runInSwingUI {
UIUtils.show(multipleApiExportDialog)

multipleApiExportDialog.setOnChannelChanged { channel ->
if (channel == null) {
Expand Down

This file was deleted.

Loading

0 comments on commit bf9383a

Please sign in to comment.