chiark / gitweb /
Net: rework status line to cope with empty squares.
authorSimon Tatham <anakin@pobox.com>
Mon, 13 Mar 2017 19:58:22 +0000 (19:58 +0000)
committerSimon Tatham <anakin@pobox.com>
Mon, 13 Mar 2017 19:58:22 +0000 (19:58 +0000)
commiteedea4132043cc4c788ee89f1ccb0783893125c5
tree71d0849d6cdf8ead4b301a26d883272b57e22251
parent0bcb32c9132020ffe2985b542951b05c6ab58b2a
Net: rework status line to cope with empty squares.

Another oddity involving an empty square is that if it coincides with
the source square for highlights (either by original design of the
game id, or because the player Ctrl-moves the source square into an
empty grid cell during play), then everything stops being lit up as
active. That's fine - you can still play the game using other
indications of error, such as the loop detection highlight - but it
looks silly for the status line to say 'Active: 1/lots'. So in that
situation I suppress the 'active' counter completely; it comes back
when you move the source square to somewhere it's _possible_ to
highlight more than one square.

While I'm at it, I've also removed the active counter in the case
where the game is completely solved, because in that situation it's
more or less unnecessary anyway, and that way the normal course of
play on the default small grid size doesn't overflow the available
status line space.
net.c