URL:
  <http://gna.org/bugs/?21067>

                 Summary: Temporary hang with unresponsive GUI when scrolling
mapview with right-clicks
                 Project: Freeciv
            Submitted by: jtn
            Submitted on: Mon Aug 26 16:38:42 2013
                Category: client-gtk-2.0
                Severity: 2 - Minor
                Priority: 5 - Normal
                  Status: None
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
                 Release: 2.4.0-RC1
         Discussion Lock: Any
        Operating System: GNU/Linux
         Planned Release: 

    _______________________________________________________

Details:

With 2.4.0-RC1 built on Linux:
0 Start "freeciv-gtk2 -t amplio2"
0 Load attached savegame (dunno if it's important)
0 Change client tileset to "hex2t". On my machine the map in the resulting
window can scroll vertically but not horizontally.
0 Scroll to the bottom of the map by right-clicking in the bottom half of the
mapview window, until the bottom of the map is visible.
0 Right-click again in the bottom half of the mapview.

What happens in the last step is that the display freezes for several seconds
(unit focus indicator stops twirling), then finally the map scrolls vertically
by a tiny amount (plausibly a single pixel).

Changing the tileset seems necessary to provoke this. Resizing the window
removes the ability to trigger this.

This is a fairly obscure set of circumstances, but it seems reproducible, so
I'm recording the details in case it can show up in real use cases, or sheds
light on some other problem we have.

Instrumenting set_mapview_origin() (where the "slide" is implemented), some
observations:
* Normally on my system a scroll takes 5-8 frames spread evenly across a
little more than 200ms
* When it goes wrong, a slide consists of >800 frames, all but the last taking
less than a millisecond each, but the final frame taking 3-5 seconds (the
length of the hang)
* Somehow we end up with the scroll amount diff_x = 0 and diff_y = 1 (pixel),
where normally these are a minimum of the order of tile sizes (36/42)

It looks like set_mapview_origin() reacts badly to being asked to do very
small (1-pixel) scrolls where most steps do not change anything so do not take
much time. However, it's probably a fault elsewhere that leads to such a small
scroll being requested in the first place (we're already at the bottom of the
map, why does a further scroll request attempt to scroll by a single pixel?)



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Mon Aug 26 16:38:42 2013  Name: hex2t-clienthang.sav.bz2  Size: 6kB  
By: jtn
demonstration savegame 
<http://gna.org/bugs/download.php?file_id=18769>

    _______________________________________________________

Reply to this item at:

  <http://gna.org/bugs/?21067>

_______________________________________________
  Message sent via/by Gna!
  http://gna.org/


_______________________________________________
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev

Reply via email to