Skip to content

Commit

Permalink
Merge branch 'develop' into improvement/camera_permission
Browse files Browse the repository at this point in the history
  • Loading branch information
federicoiosue authored Mar 10, 2024
2 parents da4bd03 + 018c585 commit 7e0e224
Show file tree
Hide file tree
Showing 478 changed files with 579 additions and 519 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ Notice that in this case I specified a single flavor to run tests on. This could
## License


Copyright 2013-2022 Federico Iosue
Copyright 2013-2024 Federico Iosue

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion assets/files.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/logo-foreground.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/logo-monochrome.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/play.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/popup.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/translations/arrays.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright (C) 2013-2023 Federico Iosue ([email protected])
~ Copyright (C) 2013-2024 Federico Iosue ([email protected])
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion assets/translations/strings.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>

<!--
~ Copyright (C) 2013-2023 Federico Iosue ([email protected])
~ Copyright (C) 2013-2024 Federico Iosue ([email protected])
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2020 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand All @@ -23,7 +23,7 @@ buildscript {
maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath 'com.android.tools.build:gradle:8.1.1'
classpath 'com.android.tools.build:gradle:8.3.0'
classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:3.2.0"
classpath 'com.adarshr:gradle-test-logger-plugin:2.1.0'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.8.10"
Expand Down
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (C) 2013-2023 Federico Iosue ([email protected])
# Copyright (C) 2013-2024 Federico Iosue ([email protected])
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
Expand All @@ -14,8 +14,8 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
VERSION_NAME=6.3.1
VERSION_CODE=331
VERSION_NAME=6.3.2
VERSION_CODE=332
PACKAGE=it.feio.android.omninotes
MIN_SDK=21
TARGET_SDK=33
Expand Down
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (C) 2013-2023 Federico Iosue ([email protected])
# Copyright (C) 2013-2024 Federico Iosue ([email protected])
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
Expand All @@ -19,4 +19,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
2 changes: 1 addition & 1 deletion gradlew
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash

#
# Copyright (C) 2013-2022 Federico Iosue ([email protected])
# Copyright (C) 2013-2024 Federico Iosue ([email protected])
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion omniNotes/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2020 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion omniNotes/lint.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (C) 2013-2023 Federico Iosue ([email protected])
~ Copyright (C) 2013-2024 Federico Iosue ([email protected])
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2020 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2020 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion omniNotes/src/alpha/res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?><!--
~ Copyright (C) 2013-2023 Federico Iosue ([email protected])
~ Copyright (C) 2013-2024 Federico Iosue ([email protected])
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
Expand Down
2 changes: 1 addition & 1 deletion omniNotes/src/alpha/res/xml/shortcuts.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?><!--
~ Copyright (C) 2013-2023 Federico Iosue ([email protected])
~ Copyright (C) 2013-2024 Federico Iosue ([email protected])
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -47,6 +47,27 @@ public void testGetNotesByTag() {
assertEquals(1, dbHelper.getNotesByTag("#tagged").size());
}

@Test
public void testGetNotesByTag_excludeLocked() {
var titleTag = "#titleTag";
var contentTag = "#tag";

var note1 = new Note();
note1.setTitle("simple note with " + titleTag);
note1.setContent("content with " + contentTag);
dbHelper.updateNote(note1, true);
var note2 = new Note();
note2.setTitle("protected note with " + titleTag);
note2.setContent("content with same tag " + contentTag);
note2.setLocked(true);
dbHelper.updateNote(note2, true);

var result = dbHelper.getNotesByTag(contentTag);
assertEquals(1, result.size());
assertEquals(note1.getTitle(), result.get(0).getTitle());
assertEquals(2, dbHelper.getNotesByTag(titleTag).size());
}

@Test
public void getNotesByPatternEscaped() {
Note note1 = new Note();
Expand All @@ -65,4 +86,40 @@ public void getNotesByPatternEscaped() {
assertEquals(1, dbHelper.getNotesByPattern("%").size());
}

@Test
public void getNotesByPattern_excludeLocked() {
var note1 = new Note();
note1.setTitle("title one");
note1.setContent("This note is clear");
dbHelper.updateNote(note1, true);
var note2 = new Note();
note2.setTitle("title two");
note2.setContent("This note is protected");
note2.setLocked(true);
dbHelper.updateNote(note2, true);

var result = dbHelper.getNotesByPattern("This note is ");

assertEquals(1, result.size());
assertEquals(note1.getTitle(), result.get(0).getTitle());
}

@Test
public void getTags() {
var note1 = new Note();
note1.setTitle("title1");
note1.setContent("#tag1");
dbHelper.updateNote(note1, true);
var note2 = new Note();
note2.setTitle("title2#");
note2.setContent("#tag2");
note2.setLocked(true);
dbHelper.updateNote(note2, true);

var tags = dbHelper.getTags();

assertEquals(1, tags.size());
assertEquals(note1.getContent(), tags.get(0).getText());
}

}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
///*
// * Copyright (C) 2013-2020 Federico Iosue ([email protected])
// * Copyright (C) 2013-2024 Federico Iosue ([email protected])
// *
// * This program is free software: you can redistribute it and/or modify
// * it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2013-2023 Federico Iosue ([email protected])
* Copyright (C) 2013-2024 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down
Loading

0 comments on commit 7e0e224

Please sign in to comment.