generated from JetBrains/intellij-platform-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: feat: Change cursor color on Caps Lock activation (#36)
* CapsLock시 색 변경 * feat: give priority to capslock - removed nonEnglishCapsLockColor - rename CheckService to InputChecker --------- Co-authored-by: Hyesong Kim <wisepine@kakao.com>
- Loading branch information
Showing
8 changed files
with
53 additions
and
24 deletions.
There are no files selected for viewing
3 changes: 1 addition & 2 deletions
3
src/main/kotlin/com/github/lauvsong/langcursor/IdeLifeCycleListener.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,11 @@ | ||
package com.github.lauvsong.langcursor | ||
|
||
import com.github.lauvsong.langcursor.services.LanguageCheckService | ||
import com.intellij.ide.AppLifecycleListener | ||
|
||
class IdeLifeCycleListener : AppLifecycleListener { | ||
|
||
override fun appClosing() { | ||
super.appClosing() | ||
LanguageCheckService.shutdown() | ||
InputChecker.shutdown() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
src/main/kotlin/com/github/lauvsong/langcursor/core/CapsLockCheckStrategy.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.github.lauvsong.langcursor.core | ||
|
||
import java.awt.Toolkit | ||
import java.awt.event.KeyEvent | ||
|
||
fun interface CapsLockCheckStrategy { | ||
fun isCapsLockOn() : Boolean | ||
|
||
} | ||
|
||
val defaultCapsLockCheckStrategy = CapsLockCheckStrategy { | ||
val capsLock = Toolkit.getDefaultToolkit().getLockingKeyState(KeyEvent.VK_CAPS_LOCK) | ||
capsLock | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters