Skip to content

Commit

Permalink
chore: exclude *
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon-He95 committed Dec 16, 2023
1 parent 573d1ad commit 0dd0488
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,18 @@ import { window } from 'vscode'
export function activate(context: ExtensionContext) {
let timer: any = null
let isChanging = false
const STOP_REG = /[\s"\>\<\/{},':;\.\(\)@=+[\]\!`\?\$\|\&\#]/
const STOP_REG = /[\s"\>\<\/{},':;\.\(\)@=+[\]\!`\?\$\|\&\#\*]/
let preKind: number | null | undefined = null
let preActive: any = null
let preSelection: any = null
const second = getConfiguration('autoclick').get('second') as number
const updateSecond = getConfiguration('autoclick').get('updateSecond') as number

context.subscriptions.push(addEventListener('selection-change', (e) => {
console.log('selection-change')
if (timer)
clearTimeout(timer)

const selections = e.selections
if (selections.length !== 1) {
preActive = null
Expand Down Expand Up @@ -52,6 +53,7 @@ export function activate(context: ExtensionContext) {

return
}

const selection = selections[0]
if (!preActive)
preActive = selection.active
Expand Down

0 comments on commit 0dd0488

Please sign in to comment.