diff --git a/app/build.gradle b/app/build.gradle index 180178a..36c90ad 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -7,8 +7,8 @@ android { applicationId "org.secuso.aktivpause" minSdkVersion 21 targetSdkVersion 28 - versionCode 4 - versionName "0.4" + versionCode 5 + versionName "0.5" vectorDrawables.useSupportLibrary = true } lintOptions { diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 2754b12..5548c61 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -45,7 +45,7 @@ 0) { - List setList = new ArrayList<>(); - - while(setCursor.moveToNext()) { - setList.add(setCursor.getInt(setCursor.getColumnIndex(ExerciseSetColumns._ID))); - } - - setCursor.close(); - - for(Integer id : setList) { - dbHandler.clearExercisesFromSet(id); - dbHandler.deleteExerciseSet(id); - } - } - - long id5 = dbHandler.addDefaultExerciseSet(context.getString(R.string.set_default_5)); - long id4 = dbHandler.addDefaultExerciseSet(context.getString(R.string.set_default_4)); - long id3 = dbHandler.addDefaultExerciseSet(context.getString(R.string.set_default_3)); - long id2 = dbHandler.addDefaultExerciseSet(context.getString(R.string.set_default_2)); - long id1 = dbHandler.addDefaultExerciseSet(context.getString(R.string.set_default_1)); - - dbHandler.addExerciseToExerciseSet((int) id1, 1); - dbHandler.addExerciseToExerciseSet((int) id1, 2); - dbHandler.addExerciseToExerciseSet((int) id1, 3); - dbHandler.addExerciseToExerciseSet((int) id1, 4); - dbHandler.addExerciseToExerciseSet((int) id1, 5); - - dbHandler.addExerciseToExerciseSet((int) id2, 6); - dbHandler.addExerciseToExerciseSet((int) id2, 7); - dbHandler.addExerciseToExerciseSet((int) id2, 11); - dbHandler.addExerciseToExerciseSet((int) id2, 13); - dbHandler.addExerciseToExerciseSet((int) id2, 17); - - dbHandler.addExerciseToExerciseSet((int) id3, 16); - dbHandler.addExerciseToExerciseSet((int) id3, 20); - dbHandler.addExerciseToExerciseSet((int) id3, 25); - dbHandler.addExerciseToExerciseSet((int) id3, 26); - dbHandler.addExerciseToExerciseSet((int) id3, 34); - - dbHandler.addExerciseToExerciseSet((int) id4, 27); - dbHandler.addExerciseToExerciseSet((int) id4, 31); - dbHandler.addExerciseToExerciseSet((int) id4, 33); - dbHandler.addExerciseToExerciseSet((int) id4, 35); - dbHandler.addExerciseToExerciseSet((int) id4, 36); - - dbHandler.addExerciseToExerciseSet((int) id5, 27); - dbHandler.addExerciseToExerciseSet((int) id5, 28); - dbHandler.addExerciseToExerciseSet((int) id5, 29); - dbHandler.addExerciseToExerciseSet((int) id5, 36); - dbHandler.addExerciseToExerciseSet((int) id5, 39); - } - } diff --git a/app/src/main/java/org/secuso/aktivpause/database/SQLiteHelper.java b/app/src/main/java/org/secuso/aktivpause/database/SQLiteHelper.java index 1b3c698..d5e45e6 100644 --- a/app/src/main/java/org/secuso/aktivpause/database/SQLiteHelper.java +++ b/app/src/main/java/org/secuso/aktivpause/database/SQLiteHelper.java @@ -150,7 +150,7 @@ public synchronized Cursor getExerciseCursorForSet(int setId, String language) { "LEFT OUTER JOIN "+ExerciseLocalColumns.TABLE_NAME+" L\n" + "\tON E."+ExerciseColumns._ID+" = L."+ExerciseLocalColumns.EXERCISE_ID+"\n" + "WHERE ES."+ExerciseSetColumns._ID+" = ? AND L."+ExerciseLocalColumns.LANGUAGE+" = ?\n" + - "ORDER BY ESE."+ExerciseColumns._ID+" ASC"; + "ORDER BY ESE.exercise_order ASC"; return database.rawQuery(sql, new String[]{String.valueOf(setId), language}); } @@ -296,7 +296,6 @@ private String buildQuery(int sectionCheck) { } } - sqlQuery.append("ORDER BY E."); sqlQuery.append(ExerciseColumns._ID); sqlQuery.append(" ASC"); diff --git a/app/src/main/res/layout/dialog_exercise.xml b/app/src/main/res/layout/dialog_exercise.xml index 84b1531..747b5dd 100644 --- a/app/src/main/res/layout/dialog_exercise.xml +++ b/app/src/main/res/layout/dialog_exercise.xml @@ -11,11 +11,9 @@ android:id="@+id/exercise_image" android:layout_width="180dp" android:layout_height="180dp" - android:layout_marginEnd="8dp" android:layout_marginLeft="8dp" + android:layout_marginTop="8dp" android:layout_marginRight="8dp" - android:layout_marginStart="8dp" - android:layout_marginTop="7dp" app:layout_constraintHorizontal_bias="0.5" app:layout_constraintLeft_toLeftOf="parent" app:layout_constraintRight_toRightOf="parent" @@ -27,9 +25,9 @@ android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="8dp" - android:layout_marginTop="0dp" android:text="@string/execution" android:textStyle="bold" + android:visibility="invisible" app:layout_constraintLeft_toRightOf="parent" app:layout_constraintTop_toTopOf="@+id/section_card" /> @@ -37,14 +35,18 @@ android:id="@+id/name" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginTop="8dp" android:layout_marginStart="8dp" + android:layout_marginTop="8dp" + android:text="Name of exercise" android:textSize="16sp" android:textStyle="bold" - android:text="Name of exercise" - app:layout_constraintTop_toTopOf="parent" + android:visibility="visible" + app:layout_constrainedWidth="true" + app:layout_constraintEnd_toStartOf="@+id/section_card" + app:layout_constraintHorizontal_bias="0.0" app:layout_constraintStart_toStartOf="parent" - android:visibility="visible"/> + app:layout_constraintTop_toTopOf="parent" + tools:text="Name of a very long exercise that can maybe wrap around" /> + app:layout_constraintTop_toBottomOf="@+id/execution_title" /> + app:layout_constraintTop_toTopOf="@+id/name"> diff --git a/app/src/main/res/layout/nav_header.xml b/app/src/main/res/layout/nav_header.xml index e7efb16..b6b2296 100644 --- a/app/src/main/res/layout/nav_header.xml +++ b/app/src/main/res/layout/nav_header.xml @@ -28,7 +28,7 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingLeft="@dimen/activity_horizontal_margin" - android:text="@string/app_name" + android:text="@string/app_name_short" android:textColor="@color/colorPrimary" android:textSize="18sp" android:textAppearance="@style/TextAppearance.AppCompat.Body1" diff --git a/app/src/main/res/menu/nav_drawer.xml b/app/src/main/res/menu/nav_drawer.xml index 7f90ced..57ce8df 100644 --- a/app/src/main/res/menu/nav_drawer.xml +++ b/app/src/main/res/menu/nav_drawer.xml @@ -5,7 +5,7 @@ + android:title="@string/app_name_short" /> - Aktivepause + Aktivpause to Go + Aktivpause Willkommen - Willkommen bei der Privacy Friendly Aktive Pause App. Diese App erinnert Sie daran, regelmäßig während der Arbeit Pausen einzulegen. Zusätzlich können Sie sich Übungen aussuchen, mit denen Sie Ihre Pause aktiv gestalten können. + Willkommen bei der Privacy Friendly Aktivpause to Go App. Diese App erinnert Sie daran, regelmäßig während der Arbeit Pausen einzulegen. Zusätzlich können Sie sich Übungen aussuchen, mit denen Sie Ihre Pause aktiv gestalten können. Übungsset erstellen @@ -44,11 +45,10 @@ Schulter Rücken Gesicht - Körper + Ganzkörper Sonstiges Bitte geben Sie einen Namen an. - @string/app_name Neues Übungsset hinzufügen Einstellungen Geben Sie einen Namen ein… @@ -93,7 +93,7 @@ Über Autoren: - Grafiken und Bilder: + Grafiken und Beschreibungen: %s und Mitwirkende In Zusammenarbeit mit Mehr Information finden Sie hier: diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index bf54e9c..aabe511 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -1,10 +1,11 @@ - Aktivpause + Aktivpause to Go + Aktivpause Open navigation drawer Close navigation drawer - Welcome to Privacy Friendly Pausing Healthily! + Welcome to Aktivpause to Go! This app reminds you to regularly take breaks during your work. Additionally, you can choose from a set of exercises, that can help you to spend your break more active. Create Exercise Sets @@ -62,7 +63,6 @@ Exercise Sets Edit Exercise Set Add New Exercise Set - Pausing Healthily Exercise Set Name Are you sure you want to discard the changes? Tutorial @@ -85,14 +85,14 @@ About - Privacy Friendly Pausing Healthily + Privacy Friendly Aktivpause to Go Version Authors: Christopher Beckmann, Eduardo Fontao %s and contributors. In affiliation with More Information can be found on: - Github-Repo + Github-Repo SECUSO-Website This application belongs to the group of Privacy Friendly Apps developed by the Karlsruhe Institute of Technology (KIT). Sourcecode licensed under GPLv3. Images copyright KIT and Google Inc. @@ -135,8 +135,8 @@ No keep editing discard - Graphics & images: - Tatjana Albrandt + Graphics & Descriptions: + KIT Sport Club 2010 e.V. diff --git a/build.gradle b/build.gradle index 4efb2aa..3cd0732 100644 --- a/build.gradle +++ b/build.gradle @@ -10,7 +10,7 @@ buildscript { google() } dependencies { - classpath 'com.android.tools.build:gradle:3.5.0' + classpath 'com.android.tools.build:gradle:3.5.1' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files