Commit Graph

22 Commits

Author SHA1 Message Date
jean-pierre charras 706b42e6f2 SCH_COMMIT: when clearing all item flags, do not clear all item flags.
If a item is selected, its SELECTED, STARTPOINT and ENDPOINT flags cannot be cleared,
and must be still selected after changes to allow more move, rotate... commands.
Fix to previous commit 741c6f2d
2023-10-05 16:46:20 +02:00
jean-pierre charras 741c6f2d55 SCH_COMMIT: when clearing all item flags, do not clear SELECTED item flags.
If a item is selected, its SELECTED flag cannot be cleared without managing
selections stored in tools, and must be still selected after changes.
Fixes #15671
https://gitlab.com/kicad/code/kicad/-/issues/15671
2023-09-24 11:07:04 +02:00
Seth Hillbrand df90409a94 No flags should persist through the commit 2023-09-16 19:42:54 -07:00
Seth Hillbrand c2fd2f42eb Update TestDanglingEnds to O(n) speed
The elements don't care which they connect to, so don't search for
points on the page, just collect them all and then test them all

Adjusts f3dd5b73
2023-08-31 15:31:48 +00:00
Jeff Young b5dc9ddbe0 Don't store address of temp object.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15517
2023-08-27 19:12:36 +01:00
Jeff Young a09a5cb641 More undo cleanup.
The symbol editor has few enough items that it will still be performant
if we always send a selected-item-modifed event.  (As it turns out we
were doing that anyway as the check for child-modified flags didn't
also check for selected.)
2023-07-16 14:43:29 +01:00
Jeff Young f8f29b55cb Don't promote to sheet parent when the item itself is a sheet.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15167
2023-07-11 14:52:05 +01:00
Jeff Young 25445d9fe0 Make sure all items managed by their parent get correct handling in SCH_COMMIT.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15129
2023-07-08 20:40:30 +01:00
Jeff Young 922f7128a9 Move item updating and view refresh to SCH_COMMIT::Push().
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15132
2023-07-07 15:40:01 +01:00
Jeff Young 4cbf512461 Support synchronous move in symbol editor.
Also removes duplicate-during-move.  It's not really compatibile with
a passed-in SCH_COMMIT, and it was never clear it was worth the code.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14274
2023-07-02 10:37:50 +01:00
Jeff Young 3a301e50ae Clear all edit flags when pushing SCH_COMMIT. 2023-06-25 16:01:35 +01:00
Jeff Young 300a60e88e Eradicate a bunch of calls to dyn_cast. 2023-06-25 11:10:05 +01:00
Jeff Young 1c1849ec1a Clear IS_MOVING (as well as IS_NEW) in SCH_COMMIT::Push().
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15051
2023-06-24 17:15:43 +01:00
Jeff Young a901247cbd Rebuilding connectivity must be done after changes are committed.
It also needs to be done after undo and redo.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15028
2023-06-23 22:10:17 +01:00
Jeff Young 237cc7eee1 Move TestDanglingEnds() to SCH_COMMIT.
Also fixes a bug where Convert Symbol wasn't undoable.

Also cleans up some SetModified() call no longer needed with SCH_COMMIT.

Also fixes bug where revert of a modification didn't update the screen's
RTree.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15030
2023-06-23 19:59:46 +01:00
Jeff Young aa6d9ad69a Clear IS_NEW flags on commit.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15037
2023-06-23 15:30:09 +01:00
Jeff Young e9046076a6 Fine-tune SCH_COMMIT handling of child objects.
While a SCH_SHEET does indeed have a SCH_SHEET parent, it's not one of
the children that gets added as a CHT_MODIFY of its parent.

Also fixes a bug where the newly drawn sheet gets removed from the
preview before running the dialog.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14976
2023-06-18 16:52:11 +01:00
Seth Hillbrand 62f24aca1e Fix Connectivity Asserts in new COMMIT structure
The connection graph should only be updated within the commit structure
because this is the only time the connectivity should be changed.  We
want any connectivity changes to be included in the commit as well, so
this should be stored prior to the undo/redo list mods
2023-06-12 13:35:06 -07:00
Jeff Young 180c820678 More changes for SCH_COMMIT independence from frames.
Also fixes some bugs in Symbol Editor SCH_COMMIT::Revert().
2023-06-10 20:53:44 +01:00
Jeff Young 5aa51bc967 Allow SCH_COMMIT to operate without a frame.
We'll want this at some point (presumably) for plugins.
2023-06-10 18:35:59 +01:00
Jeff Young 53be16f409 Stop confusing Covertiy. 2023-06-10 13:36:17 +01:00
Jeff Young 8f1b9119bf Upgrade some symbol editor stuff to SCHEMATIC_COMMIT.
Also renames SCHEMATIC_COMMIT to SCH_COMMIT since it's not schematic-specifc.
2023-06-09 22:41:47 +01:00
Renamed from eeschema/schematic_commit.cpp (Browse further)