Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve working with message lists and calendars in Outlook #7949

Merged
merged 17 commits into from Apr 30, 2018
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 10 additions & 1 deletion source/appModules/outlook.py
@@ -1,6 +1,6 @@
#appModules/outlook.py
#A part of NonVisual Desktop Access (NVDA)
#Copyright (C) 2006-2014 NVDA Contributors <http://www.nvaccess.org/>
#Copyright (C) 2006-2018 NV Access Limited, Yogesh Kumar, Manish Agrawal, Joseph Lee, Davy Kager, Babbage B.V.
#This file is covered by the GNU General Public License.
#See the file COPYING for more details.

Expand Down Expand Up @@ -435,6 +435,15 @@ def _get_name(self):
flagIcon=0
flagIconLabel=oleFlagIconLabels.get(flagIcon)
if flagIconLabel: textList.append(flagIconLabel)
# Replied or forwarded state for this message is available from the object's value.
# We must parse this value correctly, as it contains redundant information.
# The several states are localized and separated by a space.
# Example output: 'Message Replied Read'
valueParts = self._get_value().split(" ")
# The first valuePart is the type of the selection, e.g. Message, Contact.
# The last valuePart indicates whether the message is read or unread.
if len(valueParts)>=3:
textList.extend(valueParts[1:-1])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we be sure that the first part (message, contact etc) is never more than one word in all languages?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question, which also applies to read/unread I belief.

Though JAWS uses these translated strings, I"m pretty sure they do some string matching on it, as the read state is ignored when Both Outlook and JAWS are set to Dutch, but the state is preserved when Outlook is Dutch and JAWS is English. So that's definitely not a clean solution.

I belief both Message and Unread are part of the NVDA translation, so it should be doable to check whether these words contain spaces in other languages without intervention of every single translator.

try:
attachmentCount=selection.attachments.count
except COMError:
Expand Down