Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Refer to the code fragment below: Widget build ( BuildContext context ) { return ScaffoldC body: FocusC onkeyEvent: ( node , event ) { if

Refer to the code fragment below:
Widget build(BuildContext context){
return ScaffoldC
body: FocusC
onkeyEvent: (node, event){
if (event. logicalKey == LogicalKeyboardKey.capsLock){
setState(C){
text ='Hi';
}
});
else {
setState((){
text = 'Bye';
});
}
},
return KeyEventResult.ignored;
child: FormC
//...
)
;
}
When is 'Hi' assigned to _text?
When the user focuses on a form field and the caps lock key is currently on.
When the user presses any key on the keyboard and the caps lock key is currently on.
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design For Mere Mortals

Authors: Michael J Hernandez

4th Edition

978-0136788041

Students also viewed these Databases questions

Question

When there was controversy, was it clear who had the final say?

Answered: 1 week ago