AND-401 Exam QuestionsBrowse all questions from this exam

AND-401 Exam - Question 44


Which of the following is NOT true about onMeasure() method of class View?

Show Answer
Correct Answer: D

The onMeasure() method of the View class does not take three parameters. It only takes two parameters: the width and the height of the view. The purpose of this method is to measure the view and its contents to determine the measured width and the measured height, and it is indeed invoked by the measure() method. When overriding onMeasure(), a developer must call setMeasuredDimension() to store the measured width and height.

Discussion

1 comment
Sign in to comment
MmadiOption: D
Dec 31, 2022

D. It takes three parameters: the height, width, and the depth of the view.