mirror of
https://github.com/haorendashu/nowser.git
synced 2025-12-17 09:54:19 +01:00
webview bugfix
This commit is contained in:
@@ -64,33 +64,33 @@ class _WebViewComponent extends State<WebViewComponent>
|
|||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
|
|
||||||
// contextMenu = ContextMenu(
|
contextMenu = ContextMenu(
|
||||||
// menuItems: [
|
menuItems: [
|
||||||
// ContextMenuItem(
|
ContextMenuItem(
|
||||||
// id: 1,
|
id: 1,
|
||||||
// title: "Special",
|
title: "Special",
|
||||||
// action: () async {
|
action: () async {
|
||||||
// print("Menu item Special clicked!");
|
print("Menu item Special clicked!");
|
||||||
// print(await webViewController?.getSelectedText());
|
print(await webViewController?.getSelectedText());
|
||||||
// await webViewController?.clearFocus();
|
await webViewController?.clearFocus();
|
||||||
// })
|
})
|
||||||
// ],
|
],
|
||||||
// settings: ContextMenuSettings(hideDefaultSystemContextMenuItems: false),
|
settings: ContextMenuSettings(hideDefaultSystemContextMenuItems: false),
|
||||||
// onCreateContextMenu: (hitTestResult) async {
|
onCreateContextMenu: (hitTestResult) async {
|
||||||
// print("onCreateContextMenu");
|
print("onCreateContextMenu");
|
||||||
// print(hitTestResult.extra);
|
print(hitTestResult.extra);
|
||||||
// print(await webViewController?.getSelectedText());
|
print(await webViewController?.getSelectedText());
|
||||||
// },
|
},
|
||||||
// onHideContextMenu: () {
|
onHideContextMenu: () {
|
||||||
// print("onHideContextMenu");
|
print("onHideContextMenu");
|
||||||
// },
|
},
|
||||||
// onContextMenuActionItemClicked: (contextMenuItemClicked) async {
|
onContextMenuActionItemClicked: (contextMenuItemClicked) async {
|
||||||
// var id = contextMenuItemClicked.id;
|
var id = contextMenuItemClicked.id;
|
||||||
// print("onContextMenuActionItemClicked: " +
|
print("onContextMenuActionItemClicked: " +
|
||||||
// id.toString() +
|
id.toString() +
|
||||||
// " " +
|
" " +
|
||||||
// contextMenuItemClicked.title);
|
contextMenuItemClicked.title);
|
||||||
// });
|
});
|
||||||
|
|
||||||
pullToRefreshController = kIsWeb ||
|
pullToRefreshController = kIsWeb ||
|
||||||
![TargetPlatform.iOS, TargetPlatform.android]
|
![TargetPlatform.iOS, TargetPlatform.android]
|
||||||
|
|||||||
Reference in New Issue
Block a user