Skip to content

Commit

Permalink
Merge pull request #162 from humhub/159-sdk-version-update
Browse files Browse the repository at this point in the history
159 sdk version update
  • Loading branch information
luke- authored Feb 20, 2024
2 parents 5b4a894 + 2283306 commit dd6b86b
Show file tree
Hide file tree
Showing 8 changed files with 111 additions and 72 deletions.
3 changes: 3 additions & 0 deletions .fvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"flutter": "3.19.0"
}
4 changes: 2 additions & 2 deletions .github/workflows/version-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
java-version: '17'
- uses: subosito/flutter-action@v2
with:
flutter-version: '3.7.1'
flutter-version: '3.19.0'
channel: 'stable'
- uses: chkfung/[email protected]
with:
Expand Down Expand Up @@ -166,7 +166,7 @@ jobs:
- name: Install Flutter
uses: subosito/flutter-action@v1
with:
flutter-version: '3.7.1'
flutter-version: '3.19.0'
channel: 'stable'

- name: Install pub dependencies
Expand Down
92 changes: 47 additions & 45 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,45 +1,47 @@
# Miscellaneous
*.class
*.log
*.pyc
*.swp
.DS_Store
.atom/
.buildlog/
.history
.svn/
migrate_working_dir/

# IntelliJ related
*.iml
*.ipr
*.iws
.idea/
.fvm

# The .vscode folder contains launch configuration and tasks you configure in
# VS Code which you may wish to be included in version control, so this line
# is commented out by default.
#.vscode/

# Flutter/Dart/Pub related
**/doc/api/
**/ios/Flutter/.last_build_id
.dart_tool/
.flutter-plugins
.flutter-plugins-dependencies
.packages
.pub-cache/
.pub/
/build/

# Symbolication related
app.*.symbols

# Obfuscation related
app.*.map.json

# Android Studio will place build artifacts here
/android/app/debug
/android/app/profile
/android/app/release
# Miscellaneous
*.class
*.log
*.pyc
*.swp
.DS_Store
.atom/
.buildlog/
.history
.svn/
migrate_working_dir/

# IntelliJ related
*.iml
*.ipr
*.iws
.idea/

# The .vscode folder contains launch configuration and tasks you configure in
# VS Code which you may wish to be included in version control, so this line
# is commented out by default.
#.vscode/

# Flutter/Dart/Pub related
**/doc/api/
**/ios/Flutter/.last_build_id
.dart_tool/
.flutter-plugins
.flutter-plugins-dependencies
.packages
.pub-cache/
.pub/
/build/

# Symbolication related
app.*.symbols

# Obfuscation related
app.*.map.json

# Android Studio will place build artifacts here
/android/app/debug
/android/app/profile
/android/app/release

# FVM Version Cache
.fvm/
20 changes: 14 additions & 6 deletions lib/components/bottom_navigation_bar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,13 @@ class BottomNavigationState extends State<BottomNavigation> with TickerProviderS
int selectedIndex = 0;
@override
Widget build(BuildContext context) {
return WillPopScope(
onWillPop: () async {
if (selectedIndex == 0) {
return true;
}
return PopScope(
canPop: selectedIndex == 0,
onPopInvoked: (didPop) {
setState(() {
selectedIndex--;
widget.onPageChange(selectedIndex);
});
return false;
},
child: Container(
height: 50,
Expand Down Expand Up @@ -144,4 +141,15 @@ class BottomNavigationState extends State<BottomNavigation> with TickerProviderS
});
}
}

bool get canPop {
if (selectedIndex == 0) {
return true;
}
setState(() {
selectedIndex--;
widget.onPageChange(selectedIndex);
});
return false;
}
}
2 changes: 1 addition & 1 deletion lib/models/hum_hub.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class HumHub {
});

Map<String, dynamic> toJson() => {
'manifest': manifest != null ? manifest!.toJson() : null,
'manifest': manifest?.toJson(),
'isHideDialog': isHideOpener,
'randomHash': randomHash,
'appVersion': appVersion,
Expand Down
2 changes: 2 additions & 0 deletions lib/pages/web_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import 'package:permission_handler/permission_handler.dart';
import 'package:humhub/util/router.dart' as m;
import 'package:url_launcher/url_launcher.dart';


class WebViewGlobalController {
static InAppWebViewController? _value;

Expand Down Expand Up @@ -77,6 +78,7 @@ class WebViewAppState extends ConsumerState<WebViewApp> {
_concludeAuth(request);
},
);
// ignore: deprecated_member_use
return WillPopScope(
onWillPop: () => WebViewGlobalController.value!.exitApp(context, ref),
child: Scaffold(
Expand Down
58 changes: 41 additions & 17 deletions pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,30 @@ packages:
url: "https://pub.dev"
source: hosted
version: "0.6.5"
leak_tracker:
dependency: transitive
description:
name: leak_tracker
sha256: "78eb209deea09858f5269f5a5b02be4049535f568c07b275096836f01ea323fa"
url: "https://pub.dev"
source: hosted
version: "10.0.0"
leak_tracker_flutter_testing:
dependency: transitive
description:
name: leak_tracker_flutter_testing
sha256: b46c5e37c19120a8a01918cfaf293547f47269f7cb4b0058f21531c2465d6ef0
url: "https://pub.dev"
source: hosted
version: "2.0.1"
leak_tracker_testing:
dependency: transitive
description:
name: leak_tracker_testing
sha256: a597f72a664dbd293f3bfc51f9ba69816f84dcd403cdac7066cb3f6003f3ab47
url: "https://pub.dev"
source: hosted
version: "2.0.1"
lints:
dependency: transitive
description:
Expand Down Expand Up @@ -460,26 +484,26 @@ packages:
dependency: transitive
description:
name: matcher
sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e"
sha256: d2323aa2060500f906aa31a895b4030b6da3ebdcc5619d14ce1aada65cd161cb
url: "https://pub.dev"
source: hosted
version: "0.12.16"
version: "0.12.16+1"
material_color_utilities:
dependency: transitive
description:
name: material_color_utilities
sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41"
sha256: "0e0a020085b65b6083975e499759762399b4475f766c21668c4ecca34ea74e5a"
url: "https://pub.dev"
source: hosted
version: "0.5.0"
version: "0.8.0"
meta:
dependency: transitive
description:
name: meta
sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3"
sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04
url: "https://pub.dev"
source: hosted
version: "1.9.1"
version: "1.11.0"
mockito:
dependency: "direct main"
description:
Expand Down Expand Up @@ -524,10 +548,10 @@ packages:
dependency: transitive
description:
name: path
sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917"
sha256: "087ce49c3f0dc39180befefc60fdb4acd8f8620e5682fe2476afd0b3688bb4af"
url: "https://pub.dev"
source: hosted
version: "1.8.3"
version: "1.9.0"
path_provider_linux:
dependency: transitive
description:
Expand Down Expand Up @@ -901,22 +925,22 @@ packages:
url: "https://pub.dev"
source: hosted
version: "2.1.4"
watcher:
vm_service:
dependency: transitive
description:
name: watcher
sha256: "6a7f46926b01ce81bfc339da6a7f20afbe7733eff9846f6d6a5466aa4c6667c0"
name: vm_service
sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957
url: "https://pub.dev"
source: hosted
version: "1.0.2"
web:
version: "13.0.0"
watcher:
dependency: transitive
description:
name: web
sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10
name: watcher
sha256: "6a7f46926b01ce81bfc339da6a7f20afbe7733eff9846f6d6a5466aa4c6667c0"
url: "https://pub.dev"
source: hosted
version: "0.1.4-beta"
version: "1.0.2"
webview_flutter:
dependency: "direct main"
description:
Expand Down Expand Up @@ -982,5 +1006,5 @@ packages:
source: hosted
version: "3.1.2"
sdks:
dart: ">=3.1.0 <4.0.0"
dart: ">=3.2.0-0 <3.4.0"
flutter: ">=3.7.0"
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
version: 1.0.0+1

environment:
sdk: '>=2.18.6 <3.0.0'
sdk: '>=3.0.0 <3.4.0'

# Dependencies specify other packages that your package needs in order to work.
# To automatically upgrade your package dependencies to the latest versions
Expand Down

0 comments on commit dd6b86b

Please sign in to comment.