Skip to content

Loading…

Todo keyword parser fix #179

Merged
merged 1 commit into from

2 participants

@hdweiss
Collaborator

Fixes issue #176.

@matburt matburt was assigned
@matburt matburt merged commit c900e6f into dbfix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 4, 2012
  1. @hdweiss

    Fix for issue #176.

    hdweiss committed
Showing with 3 additions and 4 deletions.
  1. +1 −1 lint.xml
  2. +2 −3 src/com/matburt/mobileorg/Parsing/OrgFileParser.java
View
2 lint.xml
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<lint>
- <issue id="MissingTranslation">
+ <issue id="MissingTranslation" severity="warning">
<ignore path="res/values-de" />
</issue>
</lint>
View
5 src/com/matburt/mobileorg/Parsing/OrgFileParser.java
@@ -404,11 +404,10 @@ private boolean isValidTodo(String todo) {
return allOrgFiles;
}
-
-
+
public static ArrayList<HashMap<String, Boolean>> getTodosFromIndex(String filecontents) {
Pattern getTodos = Pattern
- .compile("#\\+TODO:\\s+([\\s\\w-]*)(\\| ([\\s\\w-]*))*");
+ .compile("#\\+TODO:\\s+([^\\|]*)(\\| ([^\\n]*))*");
Matcher m = getTodos.matcher(filecontents);
ArrayList<HashMap<String, Boolean>> todoList = new ArrayList<HashMap<String, Boolean>>();
while (m.find()) {
Something went wrong with that request. Please try again.