Skip to content
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
49f57ba
feat: Add scrollBarEnabled function
Nov 27, 2024
1f1ad6f
chore: Modify pubspec for test setup
Nov 27, 2024
4217429
test: Add dart test code
Nov 27, 2024
45abbc1
reset wkwebview
bparrishMines Apr 8, 2025
afd7fc1
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines Apr 8, 2025
d214e1a
undo pubspec changes
bparrishMines Apr 8, 2025
13421ca
proper dependency overrides
bparrishMines Apr 8, 2025
05ab710
update platform interface
bparrishMines Apr 8, 2025
c8387fe
dart side of impl
bparrishMines Apr 8, 2025
8475a1e
java side impl
bparrishMines Apr 8, 2025
7499acd
ios impl
bparrishMines Apr 8, 2025
45f7a89
app facing updated
bparrishMines Apr 8, 2025
5778e9f
formatting
bparrishMines Apr 8, 2025
61de0eb
suppress
bparrishMines Apr 8, 2025
72f9fea
add destroy
bparrishMines Apr 8, 2025
e6d0a5f
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines Apr 18, 2025
ac414de
update generated code
bparrishMines Apr 21, 2025
1bdd7c6
regen mocks
bparrishMines Apr 21, 2025
0f1461e
add destory method
bparrishMines Apr 21, 2025
a6b6286
formatting
bparrishMines Apr 21, 2025
274f10b
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines Apr 21, 2025
b35c5fb
format and add support query
bparrishMines Apr 21, 2025
d9de673
query test platform interface
bparrishMines Apr 21, 2025
cd1b2d7
reeturn value based on platform for wkwebview
bparrishMines Apr 21, 2025
1d52c56
accidental character
bparrishMines Apr 21, 2025
01fb364
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines Apr 21, 2025
61ab32a
docs that i prefer
bparrishMines Apr 21, 2025
a35c481
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines May 13, 2025
a523cae
formatting
bparrishMines May 13, 2025
cb123a5
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines May 14, 2025
b667829
fix pubspecs and changelog
bparrishMines May 14, 2025
518111c
fix pubspecs
bparrishMines May 14, 2025
c88c097
actual fix
bparrishMines May 14, 2025
0ecd78f
and one more file
bparrishMines May 14, 2025
2be1755
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines May 15, 2025
181138b
change to future bool
bparrishMines May 15, 2025
43ba081
Merge branch 'main' of github.com:flutter/packages into webview_scrol…
bparrishMines May 15, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,9 @@ flutter:
- assets/sample_video.mp4
- assets/www/index.html
- assets/www/styles/style.css
# FOR TESTING AND INITIAL REVIEW ONLY. DO NOT MERGE.
# See https://github.com/flutter/flutter/blob/master/docs/ecosystem/contributing/README.md#changing-federated-plugins
dependency_overrides:
webview_flutter_android: {path: ../../../../packages/webview_flutter/webview_flutter_android}
webview_flutter_platform_interface: {path: ../../../../packages/webview_flutter/webview_flutter_platform_interface}
webview_flutter_wkwebview: {path: ../../../../packages/webview_flutter/webview_flutter_wkwebview}
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,16 @@ class WebViewController {
) {
return platform.setOnScrollPositionChange(onScrollPositionChange);
}

/// Whether the vertical scrollbar should be drawn or not.
Future<void> setVerticalScrollBarEnabled(bool enabled) {
return platform.setVerticalScrollBarEnabled(enabled);
}

/// Whether the horizontal scrollbar should be drawn or not.
Future<void> setHorizontalScrollBarEnabled(bool enabled) {
return platform.setHorizontalScrollBarEnabled(enabled);
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also plumb through a Future<bool> supportsSetScrollBarsEnabled() method to the platform interface layer that clients can use to detect whether this is safe to call per https://github.com/flutter/flutter/blob/master/docs/ecosystem/contributing/README.md#api-support-queries ? This won't make sense on all platforms, so we should expect that clients will need a support query indefinitely.

Copy link
Contributor Author

@bparrishMines bparrishMines Apr 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm also assuming you meant for this to return bool and not Future<bool> too?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops, I missed this, and didn't catch it in the platform interface review. It should have been Future<bool> in case there were a platform that could only determine this at runtime (e.g., based on the OS version).

Not a big deal though as that's an unlikely case to ever hit.

}

/// Permissions request when web content requests access to protected resources.
Expand Down
6 changes: 6 additions & 0 deletions packages/webview_flutter/webview_flutter/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,9 @@ topics:
- html
- webview
- webview-flutter
# FOR TESTING AND INITIAL REVIEW ONLY. DO NOT MERGE.
# See https://github.com/flutter/flutter/blob/master/docs/ecosystem/contributing/README.md#changing-federated-plugins
dependency_overrides:
webview_flutter_android: {path: ../../../packages/webview_flutter/webview_flutter_android}
webview_flutter_platform_interface: {path: ../../../packages/webview_flutter/webview_flutter_platform_interface}
webview_flutter_wkwebview: {path: ../../../packages/webview_flutter/webview_flutter_wkwebview}
Loading