Skip to content

Commit

Permalink
Replace controlTypes reason constants with controlTypes.OutputReason.… (
Browse files Browse the repository at this point in the history
#24)

* Replace controlTypes reason constantS with controlTypes.OutputReason.REASON

Fixes issue #23

* Fix lint issues

* Fix workflow

* Improve workflow

* Fix path in workflow

* Use pull_request_target event

* Use pull_request_target

* Fix workflow

* Use pull_request and pull_request_target events for different situations

* Fix workflows

* Fix workflows again
  • Loading branch information
nvdaes authored Apr 18, 2021
1 parent 4774527 commit b66e908
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 14 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Check that we dont have extended ascii or utf boms in our files

on: [pull_request]
on: [pull_request, pull_request_target]

jobs:
extendedAsciiAndBom:
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
name: Lint diff

on:
pull_request:
branches:
- master
[pull_request, pull_request_target]

jobs:

Expand Down
15 changes: 7 additions & 8 deletions .github/workflows/testWithNVDA.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
name: Build and test NVDA add-on

on:
pull_request:
branches:
- master
[pull_request, pull_request_target]

jobs:

addon:
Expand Down Expand Up @@ -124,17 +123,17 @@ jobs:
pr-release:
name: Pull Request Release

needs: NVDA
needs: nvda
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Download add-on
- name: Download artifacts
uses: actions/download-artifact@v2
with:
name: nvda-addon
path: artifacts
- name: Calculate sha256
run: sha256sum *.nvda-addon > sha256.txt
run: sha256sum artifacts/nvda-addon/*.nvda-addon > sha256.txt
- name: Automatic release
uses: marvinpinto/action-automatic-releases@latest
with:
Expand All @@ -143,5 +142,5 @@ jobs:
prerelease: true
title: PR ${{ github.event.pull_request.number }}
files: |
*.nvda-addon
artifacts/**/*.*
sha256.txt
4 changes: 2 additions & 2 deletions addon/globalPlugins/placeMarkers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def doFindText(text, reverse=False, caseSensitive=False, willSayAllResume=False)
info.updateCaret()
speech.cancelSpeech()
info.move(textInfos.UNIT_LINE,1,endPoint="end")
speech.speakTextInfo(info,reason=controlTypes.REASON_CARET)
speech.speakTextInfo(info, reason=controlTypes.OutputReason.CARET)
else:
wx.CallAfter(
gui.messageBox,
Expand All @@ -130,7 +130,7 @@ def moveToBookmark(position):
obj._set_selection(info)
speech.cancelSpeech()
info.move(textInfos.UNIT_LINE,1,endPoint="end")
speech.speakTextInfo(info,reason=controlTypes.REASON_CARET)
speech.speakTextInfo(info, reason=controlTypes.OutputReason.CARET)

def standardFileName(fileName):
notAllowed = re.compile("\?|:|\*|\t|<|>|\"|\/|\\||") # Invalid characters
Expand Down

0 comments on commit b66e908

Please sign in to comment.