Replace CurrentStaticContext() with Context().CurrentStatic()

This commit is contained in:
Stefan Haller 2024-08-08 10:28:34 +02:00
parent 7ed94c0410
commit 7f935c1ea8
9 changed files with 10 additions and 15 deletions

View file

@ -82,7 +82,7 @@ func (self *RenameSimilarityThresholdController) applyChange() error {
self.c.Toast(fmt.Sprintf(self.c.Tr.RenameSimilarityThresholdChanged, self.c.AppState.RenameSimilarityThreshold))
self.c.SaveAppStateAndLogError()
currentContext := self.c.CurrentStaticContext()
currentContext := self.c.Context().CurrentStatic()
switch currentContext.GetKey() {
// we make an exception for our files context, because it actually need to refresh its state afterwards.
case context.FILES_CONTEXT_KEY:
@ -95,6 +95,6 @@ func (self *RenameSimilarityThresholdController) applyChange() error {
func (self *RenameSimilarityThresholdController) isShowingRenames() bool {
return lo.Contains(
CONTEXT_KEYS_SHOWING_RENAMES,
self.c.CurrentStaticContext().GetKey(),
self.c.Context().CurrentStatic().GetKey(),
)
}