<html>
    <head>
      <base href="https://bugzilla.gnome.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - wayland: Switching between fullscreen and unfullscreen too fast may result in a fullscreen->unfullscreen feedback loop"
   href="https://bugzilla.gnome.org/show_bug.cgi?id=762468#c21">Comment # 21</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - wayland: Switching between fullscreen and unfullscreen too fast may result in a fullscreen->unfullscreen feedback loop"
   href="https://bugzilla.gnome.org/show_bug.cgi?id=762468">bug 762468</a>
              from <span class="vcard"><a href="page.cgi?id=describeuser.html&login=jadahl%40gmail.com" title="Jonas Ådahl <jadahl@gmail.com>"> <span class="fn">Jonas Ådahl</span></a>
</span></b>
        <pre>(In reply to Matthias Clasen from <a href="show_bug.cgi?id=762468#c20">comment #20</a>)
<span class="quote">> what you see in the stacktraces is that we get a window state event which
> changes the fullscreen state, then terminal-window updates its toggle action
> to match, which in turn triggers the callback to call
> gtk_window_[un]fullscreen. Seems fine so far, since we are just calling the
> function for the state we already changed to, but something ought to notice
> this and fizzle out, probably on the mutter side.</span >

What could mutter do? When it receives the make-fullscreen request, it
immediately responds with "ok, go fullscreen then". Then when it receives the
unmake-fullscreen request, it immediately responds with "ok, go unfullscreen
then".

I have a patch which "compresses" GDK_WINDOW_STATE events by dropping any
previous event to the same window while updating the "changed_mask". That seems
to fix the issue to me (though it triggers another bug, which I suspect is in
mutter, causing the window to not display any more, and then display with the
wrong size).

Another possible solution I intended to try is to only allow dispatching one
wayland event at once before dispatching the internal GDK event queue, but this
would have a lot larger impact on things.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>