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

Attempt at implementing the addition requested in issue #99. #103

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all 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
4 changes: 2 additions & 2 deletions android/app/build.gradle
Expand Up @@ -41,7 +41,7 @@ apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"

android {
compileSdkVersion 29
compileSdkVersion 31

sourceSets {
main.java.srcDirs += 'src/main/kotlin'
Expand All @@ -55,7 +55,7 @@ android {
defaultConfig {
applicationId 'me.wolszon.fastshopping'
minSdkVersion 16
targetSdkVersion 29
targetSdkVersion 31
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
Expand Down
4 changes: 2 additions & 2 deletions android/build.gradle
@@ -1,12 +1,12 @@
buildscript {
ext.kotlin_version = '1.3.50'
ext.kotlin_version = '1.7.10'
repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:4.1.1'
classpath 'com.android.tools.build:gradle:4.1.0'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"

classpath 'com.google.gms:google-services:4.3.3'
Expand Down
16 changes: 14 additions & 2 deletions lib/features/items/widgets/app_bar.dart
Expand Up @@ -53,14 +53,26 @@ class ItemsAppBar extends StatelessWidget implements PreferredSizeWidget {
key: const ValueKey('menu'),
onSelected: (item) => _onMenuItemSelected(context, item),
itemBuilder: (context) => [
if (shoppingListsMode == ShoppingListsMode.multiple)
if (shoppingListsMode == ShoppingListsMode.multiple) ...[
_PopupMenuItem(
value: _MenuItem.archiveList,
enabled: onArchiveList != null,
icon: const Icon(Icons.archive),
label: Text(S.of(context)!.menu_archive_list),
),
_PopupMenuItem(
value: _MenuItem.undoneAll,
enabled: onUndoneAll != null,
icon: const Icon(Icons.remove_done),
label: Text(S.of(context)!.menu_undone_all_done),
),
_PopupMenuItem(
value: _MenuItem.removeAllDone,
enabled: onRemoveAllDone != null,
icon: const Icon(Icons.delete),
label: Text(S.of(context)!.menu_remove_all_done),
)
else ...[
] else ...[
_PopupMenuItem(
value: _MenuItem.undoneAll,
enabled: onUndoneAll != null,
Expand Down