diff --git a/app/src/main/assets/pl-changelog.html b/app/src/main/assets/pl-changelog.html
index e87bb90e..25e2064b 100644
--- a/app/src/main/assets/pl-changelog.html
+++ b/app/src/main/assets/pl-changelog.html
@@ -31,6 +31,13 @@
+Wersja 3.0.1, 2019-09-19
+
+ - Librus: Poprawa błędu synchronizacji.
+ - Poprawki UI związane z paskiem nawigacji.
+ - Mobidziennik: Pobieranie ocen w niektórych przedmiotach.
+
+
Wersja 3.0, 2019-09-13
- Nowy wygląd i sposób nawigacji w całej aplikacji.
diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/MainActivity.kt b/app/src/main/java/pl/szczodrzynski/edziennik/MainActivity.kt
index 1316a91a..5d7bbd7c 100644
--- a/app/src/main/java/pl/szczodrzynski/edziennik/MainActivity.kt
+++ b/app/src/main/java/pl/szczodrzynski/edziennik/MainActivity.kt
@@ -229,8 +229,8 @@ class MainActivity : AppCompatActivity() {
drawer.init(this@MainActivity)
SystemBarsUtil(this@MainActivity).run {
- paddingByKeyboard = b.navView
- appFullscreen = true
+ //paddingByKeyboard = b.navView
+ appFullscreen = false
statusBarColor = getColorFromAttr(context, android.R.attr.colorBackground)
statusBarDarker = false
statusBarFallbackLight = COLOR_HALF_TRANSPARENT
@@ -239,6 +239,8 @@ class MainActivity : AppCompatActivity() {
b.navView.configSystemBarsUtil(this)
+ // TODO fix navlib navbar detection, orientation change issues, status bar color setting if not fullscreen
+
commit()
}
diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/api/Librus.java b/app/src/main/java/pl/szczodrzynski/edziennik/api/Librus.java
index c3d01bb3..592131ad 100644
--- a/app/src/main/java/pl/szczodrzynski/edziennik/api/Librus.java
+++ b/app/src/main/java/pl/szczodrzynski/edziennik/api/Librus.java
@@ -1600,6 +1600,10 @@ public class Librus implements EdziennikInterface {
r("finish", "Classrooms");
return;
}
+ if (data.get("Classrooms") == null) {
+ r("finish", "Classrooms");
+ return;
+ }
JsonArray jClassrooms = data.get("Classrooms").getAsJsonArray();
//d("Got Classrooms: "+jClassrooms.toString());
classrooms.clear();
diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/api/Mobidziennik.java b/app/src/main/java/pl/szczodrzynski/edziennik/api/Mobidziennik.java
index 71c200b8..7df269d6 100644
--- a/app/src/main/java/pl/szczodrzynski/edziennik/api/Mobidziennik.java
+++ b/app/src/main/java/pl/szczodrzynski/edziennik/api/Mobidziennik.java
@@ -794,7 +794,7 @@ public class Mobidziennik implements EdziennikInterface {
switch (e.tagName()) {
case "div": {
//d(TAG, "Outer HTML "+e.outerHtml());
- Matcher matcher = Pattern.compile("\\n*\\s*(.+?)\\n*(?:<.*?)??", Pattern.DOTALL).matcher(e.outerHtml());
+ Matcher matcher = Pattern.compile("\\n*\\s*(.+?)\\s*\\n*(?:<.*?)??", Pattern.DOTALL).matcher(e.outerHtml());
if (matcher.find()) {
subjectName = matcher.group(1);
}
@@ -1456,8 +1456,8 @@ public class Mobidziennik implements EdziennikInterface {
}
String[] user = userStr.split("\\|", Integer.MAX_VALUE);
- teachersMap.put(strToInt(user[0]), user[5]+" "+user[4]);
- teacherList.add(new Teacher(profileId, strToInt(user[0]), user[4], user[5]));
+ teachersMap.put(strToInt(user[0]), user[5].trim()+" "+user[4].trim());
+ teacherList.add(new Teacher(profileId, strToInt(user[0]), user[4].trim(), user[5].trim()));
}
}
@@ -1958,7 +1958,7 @@ public class Mobidziennik implements EdziennikInterface {
for(int i = 0; i < teachersMap.size(); i++) {
int key = teachersMap.keyAt(i);
String str = teachersMap.valueAt(i);
- if ((lesson[7] + " " + lesson[6]).equalsIgnoreCase(str)) {
+ if ((lesson[7].trim() + " " + lesson[6].trim()).equalsIgnoreCase(str)) {
lessonObject.teacherId = key;
}
}
@@ -2001,7 +2001,7 @@ public class Mobidziennik implements EdziennikInterface {
for(int i = 0; i < teachersMap.size(); i++) {
int key = teachersMap.keyAt(i);
String str = teachersMap.valueAt(i);
- if ((lesson[7] + " " + lesson[6]).equalsIgnoreCase(str)) {
+ if ((lesson[7].trim() + " " + lesson[6].trim()).equalsIgnoreCase(str)) {
lessonChange.teacherId = key;
}
}
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index 116c7a40..cdd0abb1 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -95,6 +95,8 @@
- ?android:textColorSecondary
- ?colorSurface
- @color/dividerColor
+
+ - ?android:windowBackground
diff --git a/build.gradle b/build.gradle
index 3fb254a7..3ef0a842 100644
--- a/build.gradle
+++ b/build.gradle
@@ -5,8 +5,8 @@ buildscript {
kotlin_version = '1.3.50'
release = [
- versionName: "3.0",
- versionCode: 3000099
+ versionName: "3.0.1-rc.1",
+ versionCode: 3000110
]
setup = [