fluttercommunity / fluttercommunity/flutter_webview_plugin

Drawer Hack

Open
#113 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
1.5k
Forks
938
PR merge metrics
No merged PRs in 30d

Description

can we assign the hidden attribute to the state and create a function to toggle between hidden = true and hidden = false , to hide the webview rect when the drawer is opened
and we use the leading in Appbar to control that

State and function to toggle visibility
`
bool _visibility = false;
_handleDrawer(){
_scaffoldKey.currentState.openDrawer();
setState(() {
_visibility = true;
});
}
`

` appBar: new AppBar(
centerTitle: true,
leading: new IconButton(icon: new Icon(
Icons.menu
),onPressed:_handleDrawer,),
title: new Text('Plugin example app'),
),
`
so when the drawer is opened the state of the webview hidden is true , and when drawer is closed hidden is false

I am a beginner and i cant make the toggle function to work

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.