Ticket #90 (closed defect: released)

Opened 16 months ago

Last modified 5 months ago

Stop new units showing up twice

Reported by: ibboard Owned by:
Priority: major Milestone: WarFoundry 0.1
Component: WarFoundry-GUIs Version:
Keywords: Cc:
Blocking: Blocked By:

Description

Both the GTK# and WinForms GUIs currently duplicate any new unit that is added. This is only a visual duplication - they show up twice in the tree but only charged for once - but it should be resolved. It is probably caused by a change to the events fired when creating units.

Change History

Changed 16 months ago by ibboard

Appears to be caused because Army.AddUnit calls UnitAdded as its last instruction with a list of failed requirements, but the method also calls ArmyCategory.AddUnit, which calls OnUnitAdded, which triggers up to the Army to make sure that anyone listening to just the army is notified.

Changed 15 months ago by ibboard

  • owner ibboard deleted

Remove owner so that the team can more easily see bugs. Using default owners seems good at first but is bad practice when a team can be working on any part of the project.

Changed 14 months ago by ibboard

(In r146) Re #90: Stop new units showing up twice

  • Hand all of unit adding/removing down to category
  • Refactor out OnFailedRequirement method in Army
  • Make Army listen to and propogate FailedRequirement events from Units
  • Add OnUnitAdded/Removed method to ArmyCategory that takes list of failures
  • Remove direct reference to Army from Unit and go via ArmyCategory instead

Changed 14 months ago by ibboard

(In r147) Re #90: Stop new units showing up twice

  • Pass ArmyCategory to CreateAndAddUnitCommand

Changed 14 months ago by ibboard

(In r148) Re #90: Stop new units showing up twice

  • Pass ArmyCategory to CreateAndAddUnitCommand

Changed 14 months ago by ibboard

  • status changed from new to closed
  • resolution set to fixed

Now fixed in API and GUI (as long as user isn't listening to source and propagated version!)

Changed 11 months ago by ibboard

  • released set to 1

Mark released changes as released

Changed 11 months ago by ibboard

  • released changed from 1 to yes

Mark released fixes as released using radio values

Changed 5 months ago by ibboard

  • resolution changed from fixed to released

Mark fix as released under a previous version

Note: See TracTickets for help on using tickets.