I've lost track of who this behavior is about, so this is a generic statement. I heard a gifted educator speak about this type of behavior. She said that what sometimes (!) happens is that kids get so used to "checking out" or "avoiding" or "entertaining themselves" or whatever in school settings that they actually tune out too often and miss important things. Gifted kids usually pick up on these gaps pretty quickly but some of them never even know they missed something. Her point was that educators need to make sure that kids are actively involved most of the time (no kid is going to concentrate 100% all the time), especially gifted kids because it is so easy for them to tune out. Then, the gifted kids end up falling through the cracks because "well, if he's gifted, how come he doesn't know xyz?" or "he doesn't know xyz so we must do remedial work".

Ultimately, it is the teacher's job to engage kids. Does it happen with gifted kids? Unfortunately, not that often. The educator I heard emphasized hard that gifted kids need to go deeper AND faster. Didn't happen for us.