Complete.Org: Mailing Lists: Archives: freeciv-dev: July 2002:
[Freeciv-Dev] Re: Active unit not centered after eXplore (PR#1679)
Home

[Freeciv-Dev] Re: Active unit not centered after eXplore (PR#1679)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Per I Mathisen <per@xxxxxxxxxxx>
Cc: freeciv-dev@xxxxxxxxxxx, bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: Active unit not centered after eXplore (PR#1679)
From: Raimar Falke <rf13@xxxxxxxxxxxxxxxxx>
Date: Tue, 9 Jul 2002 10:12:09 +0200

On Mon, Jul 08, 2002 at 05:17:11PM -0700, Per I Mathisen wrote:
> Index: client/control.h
> ===================================================================
> RCS file: /home/freeciv/CVS/freeciv/client/control.h,v
> retrieving revision 1.28
> diff -u -r1.28 control.h
> --- client/control.h  2002/03/17 09:11:51     1.28
> +++ client/control.h  2002/07/09 00:13:01
> @@ -87,7 +87,7 @@
>  void set_unit_focus(struct unit *punit);
>  void set_unit_focus_no_center(struct unit *punit);
>  void set_unit_focus_and_select(struct unit *punit);
> -void update_unit_focus(void);
> +void update_unit_focus(struct unit *punit);
>  struct unit *find_visible_unit(struct tile *ptile);
>  void set_units_in_combat(struct unit *pattacker, struct unit *pdefender);
>  void blink_active_unit(void);
> Index: client/civclient.c
> ===================================================================
> RCS file: /home/freeciv/CVS/freeciv/client/civclient.c,v
> retrieving revision 1.138
> diff -u -r1.138 civclient.c
> --- client/civclient.c        2002/06/27 01:11:37     1.138
> +++ client/civclient.c        2002/07/09 00:13:01
> @@ -576,7 +576,7 @@
>        update_research(game.player_ptr);
>        role_unit_precalcs();
>        boot_help_texts();     /* reboot */
> -      update_unit_focus();
> +      update_unit_focus(NULL);
>      }
>      else if(client_state==CLIENT_PRE_GAME_STATE) {
>        popdown_all_city_dialogs();
> Index: client/control.c
> ===================================================================
> RCS file: /home/freeciv/CVS/freeciv/client/control.c,v
> retrieving revision 1.81
> diff -u -r1.81 control.c
> --- client/control.c  2002/06/06 07:26:04     1.81
> +++ client/control.c  2002/07/09 00:13:02
> @@ -156,9 +156,10 @@
>  If there is no unit currently in focus, or if the current unit in
>  focus should not be in focus, then get a new focus unit.
>  We let GOTO-ing units stay in focus, so that if they have moves left
> -at the end of the goto, then they are still in focus.

> +at the end of the goto, then they are still in focus. punit is previous
> +unit, and should most often be NULL.

"previous unit"? The previous focused unit is punit_focus.

        Raimar

-- 
 email: rf13@xxxxxxxxxxxxxxxxx
 "Programming today is a race between software engineers striving to
  build bigger and better idiot-proof programs, and the Universe trying
  to produce bigger and better idiots. So far, the Universe is winning."
    -- Rich Cook


[Prev in Thread] Current Thread [Next in Thread]